Fixes a crash bug when trying to break a block because the damage texture couldn't be generated. (#69)
Fixes another crash bug where during UVLModelLoader loading, it tried to apply tint but couldn't, because no block was available. Also fixes a bug where the quad tint wasn't propagated and tinting didn't work.
This commit is contained in:
@@ -216,7 +216,7 @@ public class CachingRotatingBakedModel implements IBakedModel
|
|||||||
|
|
||||||
public void setQuadTint( int tint )
|
public void setQuadTint( int tint )
|
||||||
{
|
{
|
||||||
|
parent.setQuadTint( tint );
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -228,13 +228,13 @@ public class CachingRotatingBakedModel implements IBakedModel
|
|||||||
@Override
|
@Override
|
||||||
public void setApplyDiffuseLighting( boolean diffuse )
|
public void setApplyDiffuseLighting( boolean diffuse )
|
||||||
{
|
{
|
||||||
|
parent.setApplyDiffuseLighting( diffuse );
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void setTexture( TextureAtlasSprite texture )
|
public void setTexture( TextureAtlasSprite texture )
|
||||||
{
|
{
|
||||||
|
parent.setTexture( texture );
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -315,9 +315,15 @@ public enum UVLModelLoader implements ICustomModelLoader
|
|||||||
lightmap[1] = brightness.getLeft();
|
lightmap[1] = brightness.getLeft();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void setQuadTint( int tint )
|
||||||
|
{
|
||||||
|
// Tint requires a block state which we don't have at this point
|
||||||
|
}
|
||||||
};
|
};
|
||||||
trans.setParent( builder );
|
trans.setParent( builder );
|
||||||
quad.pipe( trans );
|
quad.pipe( trans );
|
||||||
|
builder.setQuadTint( quad.getTintIndex() );
|
||||||
builder.setQuadOrientation( quad.getFace() );
|
builder.setQuadOrientation( quad.getFace() );
|
||||||
return builder.build();
|
return builder.build();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user