fix fallback textures
This commit is contained in:
parent
eb5c03dda3
commit
e85166666f
14 changed files with 53 additions and 36 deletions
|
@ -1011,4 +1011,8 @@ public class Block {
|
|||
public final int getEncouragement() {
|
||||
return this.encouragement;
|
||||
}
|
||||
|
||||
public String getFallbackTexture() {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -152,6 +152,10 @@ public class BlockFloorPortal extends Block
|
|||
}
|
||||
|
||||
public void getAnimatedTextures(Map<String, Object> map) {
|
||||
map.put("blocks/floor_portal", 5);
|
||||
map.put("floor_portal", 5);
|
||||
}
|
||||
|
||||
public String getFallbackTexture() {
|
||||
return "obsidian";
|
||||
}
|
||||
}
|
||||
|
|
|
@ -293,7 +293,7 @@ public class BlockPortal extends Block
|
|||
}
|
||||
|
||||
public void getAnimatedTextures(Map<String, Object> map) {
|
||||
map.put("blocks/portal", 1);
|
||||
map.put("portal", 1);
|
||||
}
|
||||
|
||||
// public BlockPattern.PatternHelper func_181089_f(World p_181089_1_, BlockPos p_181089_2_)
|
||||
|
|
|
@ -315,6 +315,12 @@ public class BlockDynamicLiquid extends BlockLiquid
|
|||
}
|
||||
|
||||
public void getAnimatedTextures(Map<String, Object> map) {
|
||||
map.put("blocks/" + BlockRegistry.getNameFromBlock(this.staticBlock) + "_flow", this.animation);
|
||||
map.put(BlockRegistry.getNameFromBlock(this.staticBlock) + "_flow", this.animation);
|
||||
}
|
||||
|
||||
public String getFallbackTexture() {
|
||||
if(this.cachedTexture == null)
|
||||
this.cachedTexture = BlockRegistry.getNameFromBlock(this.staticBlock) + "_still";
|
||||
return this.cachedTexture;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -37,6 +37,8 @@ public abstract class BlockLiquid extends Block
|
|||
protected final boolean opaque;
|
||||
protected final int flowRate;
|
||||
protected final Object animation;
|
||||
|
||||
protected String cachedTexture;
|
||||
|
||||
public BlockLiquid(Material materialIn, boolean tick, boolean opaque, int rate, Object animation)
|
||||
{
|
||||
|
|
|
@ -114,6 +114,12 @@ public class BlockStaticLiquid extends BlockLiquid
|
|||
}
|
||||
|
||||
public void getAnimatedTextures(Map<String, Object> map) {
|
||||
map.put("blocks/" + BlockRegistry.getNameFromBlock(this) + "_still", this.animation);
|
||||
map.put(BlockRegistry.getNameFromBlock(this) + "_still", this.animation);
|
||||
}
|
||||
|
||||
public String getFallbackTexture() {
|
||||
if(this.cachedTexture == null)
|
||||
this.cachedTexture = BlockRegistry.getNameFromBlock(this) + "_still";
|
||||
return this.cachedTexture;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1144,8 +1144,8 @@ public class BlockFire extends Block
|
|||
}
|
||||
|
||||
public void getAnimatedTextures(Map<String, Object> map) {
|
||||
map.put("blocks/fire_layer_0", TextureAnimation.FIRE1);
|
||||
map.put("blocks/fire_layer_1", TextureAnimation.FIRE2);
|
||||
map.put("fire_layer_0", TextureAnimation.FIRE1);
|
||||
map.put("fire_layer_1", TextureAnimation.FIRE2);
|
||||
}
|
||||
|
||||
public boolean canExtinguish() {
|
||||
|
|
|
@ -30,7 +30,7 @@ public class BlockTintedFire extends BlockFire {
|
|||
}
|
||||
|
||||
public void getAnimatedTextures(Map<String, Object> map) {
|
||||
map.put("blocks/flame_layer_0", TextureAnimation.FLAME1);
|
||||
map.put("blocks/flame_layer_1", TextureAnimation.FLAME2);
|
||||
map.put("flame_layer_0", TextureAnimation.FLAME1);
|
||||
map.put("flame_layer_1", TextureAnimation.FLAME2);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -634,4 +634,8 @@ public class BlockChest extends BlockContainer implements Rotatable
|
|||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
public String getFallbackTexture() {
|
||||
return "oak_planks";
|
||||
}
|
||||
}
|
||||
|
|
|
@ -21,6 +21,6 @@ public class BlockTianReactor extends BlockMachine {
|
|||
}
|
||||
|
||||
public void getAnimatedTextures(Map<String, Object> map) {
|
||||
map.put("blocks/tian_reactor_front", 5);
|
||||
map.put("tian_reactor_front", 5);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -144,4 +144,8 @@ public class BlockBanner extends BlockContainer implements Rotatable
|
|||
public Transforms getTransform() {
|
||||
return Transforms.BANNER;
|
||||
}
|
||||
|
||||
public String getFallbackTexture() {
|
||||
return "oak_planks";
|
||||
}
|
||||
}
|
||||
|
|
|
@ -131,4 +131,8 @@ public class BlockSign extends BlockContainer
|
|||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
public String getFallbackTexture() {
|
||||
return "oak_planks";
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue