mirror of
https://github.com/GTNewHorizons/Botania.git
synced 2026-11-22 13:09:42 +00:00
placeholder model for spreader so it shows in JEI. make monocle use blockstates like it should
This commit is contained in:
1 parent
4bf8fd3b98
commit
e5ee04113f
3 files changed
+80
-75
No files matched your search
@@ -460,6 +460,7 @@ public final class ModelHandler {
|
||||
registerVariantsDefaulted(ModBlocks.platform, PlatformVariant.class, "variant");
|
||||
registerVariantsDefaulted(ModBlocks.prismarine, PrismarineVariant.class, "variant");
|
||||
registerVariantsDefaulted(ModBlocks.spreader, SpreaderVariant.class, "variant");
|
||||
// todo 1.8 this is temporary until animation API is done, currnetly item model textures will not match true spreader texture
|
||||
registerVariantsDefaulted(ModFluffBlocks.stone, FutureStoneVariant.class, "variant");
|
||||
registerVariantsDefaulted(ModBlocks.storage, StorageVariant.class, "variant");
|
||||
}
|
||||
|
||||
@@ -11,6 +11,10 @@
|
||||
package vazkii.botania.common.item.equipment.bauble;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.BlockRedstoneComparator;
|
||||
import net.minecraft.block.BlockRedstoneRepeater;
|
||||
import net.minecraft.block.BlockRedstoneWire;
|
||||
import net.minecraft.block.state.IBlockState;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.ScaledResolution;
|
||||
import net.minecraft.client.renderer.GlStateManager;
|
||||
@@ -63,8 +67,8 @@ public class ItemMonocle extends ItemBauble implements IBurstViewerBauble, ICosm
|
||||
MovingObjectPosition pos = mc.objectMouseOver;
|
||||
if(pos == null || pos.getBlockPos() == null)
|
||||
return;
|
||||
Block block = player.worldObj.getBlockState(pos.getBlockPos()).getBlock();
|
||||
int meta = block.getMetaFromState(player.worldObj.getBlockState(pos.getBlockPos())); // todo 1.8 use states
|
||||
IBlockState state = player.worldObj.getBlockState(pos.getBlockPos());
|
||||
Block block = state.getBlock();
|
||||
player.worldObj.getTileEntity(pos.getBlockPos());
|
||||
|
||||
ItemStack dispStack = null;
|
||||
@@ -72,13 +76,13 @@ public class ItemMonocle extends ItemBauble implements IBurstViewerBauble, ICosm
|
||||
|
||||
if(block == Blocks.redstone_wire) {
|
||||
dispStack = new ItemStack(Items.redstone);
|
||||
text = EnumChatFormatting.RED + "" + meta;
|
||||
text = EnumChatFormatting.RED + "" + state.getValue(BlockRedstoneWire.POWER);
|
||||
} else if(block == Blocks.unpowered_repeater || block == Blocks.powered_repeater) {
|
||||
dispStack = new ItemStack(Items.repeater);
|
||||
text = "" + (((meta & 12) >> 2) + 1);
|
||||
text = "" + state.getValue(BlockRedstoneRepeater.DELAY);
|
||||
} else if(block == Blocks.unpowered_comparator || block == Blocks.powered_comparator) {
|
||||
dispStack = new ItemStack(Items.comparator);
|
||||
text = (meta & 4) == 4 ? "-" : "+";
|
||||
text = state.getValue(BlockRedstoneComparator.MODE) == BlockRedstoneComparator.Mode.SUBTRACT ? "-" : "+";
|
||||
}
|
||||
|
||||
if(dispStack == null)
|
||||
|
||||
@@ -4,133 +4,133 @@
|
||||
},
|
||||
"elements": [
|
||||
{
|
||||
"__comment": "cubeSide4",
|
||||
"name": "cubeSide4",
|
||||
"from": [14, 1, 2],
|
||||
"to": [15, 14, 15],
|
||||
"faces": {
|
||||
"down": {"uv": [0.5, 0, 0.75, 3.25], "texture": "#all"},
|
||||
"up": {"uv": [0.25, 0, 0.5, 3.25], "texture": "#all"},
|
||||
"north": {"uv": [3.75, 3.25, 7, 6.5], "texture": "#all"},
|
||||
"south": {"uv": [0.25, 3.25, 3.5, 6.5], "texture": "#all"},
|
||||
"west": {"uv": [0, 3.25, 0.25, 6.5], "texture": "#all"},
|
||||
"east": {"uv": [3.5, 3.25, 3.75, 6.5], "texture": "#all"}
|
||||
"down": {"uv": [0.5, 0, 0.75, 3.25], "texture": "#side"},
|
||||
"up": {"uv": [0.25, 0, 0.5, 3.25], "texture": "#side"},
|
||||
"north": {"uv": [3.75, 3.25, 7, 6.5], "texture": "#side"},
|
||||
"south": {"uv": [0.25, 3.25, 3.5, 6.5], "texture": "#side"},
|
||||
"west": {"uv": [0, 3.25, 0.25, 6.5], "texture": "#side"},
|
||||
"east": {"uv": [3.5, 3.25, 3.75, 6.5], "texture": "#side"}
|
||||
}
|
||||
},
|
||||
{
|
||||
"__comment": "cubeInside",
|
||||
"name": "cubeInside",
|
||||
"from": [5, 4, 5],
|
||||
"to": [11, 10, 11],
|
||||
"faces": {
|
||||
"down": {"uv": [10.5, 4.25, 12, 5.75], "texture": "#all"},
|
||||
"up": {"uv": [9, 4.25, 10.5, 5.75], "texture": "#all"},
|
||||
"north": {"uv": [12, 5.75, 13.5, 7.25], "texture": "#all"},
|
||||
"south": {"uv": [9, 5.75, 10.5, 7.25], "texture": "#all"},
|
||||
"west": {"uv": [7.5, 5.75, 9, 7.25], "texture": "#all"},
|
||||
"east": {"uv": [10.5, 5.75, 12, 7.25], "texture": "#all"}
|
||||
"down": {"uv": [10.5, 4.25, 12, 5.75], "texture": "#inside"},
|
||||
"up": {"uv": [9, 4.25, 10.5, 5.75], "texture": "#inside"},
|
||||
"north": {"uv": [12, 5.75, 13.5, 7.25], "texture": "#inside"},
|
||||
"south": {"uv": [9, 5.75, 10.5, 7.25], "texture": "#inside"},
|
||||
"west": {"uv": [7.5, 5.75, 9, 7.25], "texture": "#inside"},
|
||||
"east": {"uv": [10.5, 5.75, 12, 7.25], "texture": "#inside"}
|
||||
}
|
||||
},
|
||||
{
|
||||
"__comment": "cubeHole2",
|
||||
"name": "cubeHole2",
|
||||
"from": [2, 1, 14],
|
||||
"to": [6, 13, 15],
|
||||
"faces": {
|
||||
"down": {"uv": [2, 0, 3, 0.25], "texture": "#all"},
|
||||
"up": {"uv": [1, 0, 2, 0.25], "texture": "#all"},
|
||||
"north": {"uv": [2.25, 0.25, 2.5, 3.25], "texture": "#all"},
|
||||
"south": {"uv": [1, 0.25, 1.25, 3.25], "texture": "#all"},
|
||||
"west": {"uv": [0, 0.25, 1, 3.25], "texture": "#all"},
|
||||
"east": {"uv": [1.25, 0.25, 2.25, 3.25], "texture": "#all"}
|
||||
"down": {"uv": [2, 0, 3, 0.25], "texture": "#top"},
|
||||
"up": {"uv": [1, 0, 2, 0.25], "texture": "#top"},
|
||||
"north": {"uv": [2.25, 0.25, 2.5, 3.25], "texture": "#top"},
|
||||
"south": {"uv": [1, 0.25, 1.25, 3.25], "texture": "#top"},
|
||||
"west": {"uv": [0, 0.25, 1, 3.25], "texture": "#top"},
|
||||
"east": {"uv": [1.25, 0.25, 2.25, 3.25], "texture": "#top"}
|
||||
}
|
||||
},
|
||||
{
|
||||
"__comment": "cubeSide5",
|
||||
"name": "cubeSide5",
|
||||
"from": [2, 13, 2],
|
||||
"to": [14, 14, 15],
|
||||
"faces": {
|
||||
"down": {"uv": [6, 0, 9, 3.25], "texture": "#all"},
|
||||
"up": {"uv": [3, 0, 6, 3.25], "texture": "#all"},
|
||||
"north": {"uv": [9.25, 3.25, 12.5, 3.5], "texture": "#all"},
|
||||
"south": {"uv": [3, 3.25, 6.25, 3.5], "texture": "#all"},
|
||||
"west": {"uv": [0, 3.25, 3, 3.5], "texture": "#all"},
|
||||
"east": {"uv": [6.25, 3.25, 9.25, 3.5], "texture": "#all"}
|
||||
"down": {"uv": [6, 0, 9, 3.25], "texture": "#side"},
|
||||
"up": {"uv": [3, 0, 6, 3.25], "texture": "#side"},
|
||||
"north": {"uv": [9.25, 3.25, 12.5, 3.5], "texture": "#side"},
|
||||
"south": {"uv": [3, 3.25, 6.25, 3.5], "texture": "#side"},
|
||||
"west": {"uv": [0, 3.25, 3, 3.5], "texture": "#side"},
|
||||
"east": {"uv": [6.25, 3.25, 9.25, 3.5], "texture": "#side"}
|
||||
}
|
||||
},
|
||||
{
|
||||
"__comment": "cubeHole4",
|
||||
"name": "cubeHole4",
|
||||
"from": [6, 9, 14],
|
||||
"to": [10, 13, 15],
|
||||
"faces": {
|
||||
"down": {"uv": [2, 0, 3, 0.25], "texture": "#all"},
|
||||
"up": {"uv": [1, 0, 2, 0.25], "texture": "#all"},
|
||||
"north": {"uv": [2.25, 0.25, 2.5, 1.25], "texture": "#all"},
|
||||
"south": {"uv": [1, 0.25, 1.25, 1.25], "texture": "#all"},
|
||||
"west": {"uv": [0, 0.25, 1, 1.25], "texture": "#all"},
|
||||
"east": {"uv": [1.25, 0.25, 2.25, 1.25], "texture": "#all"}
|
||||
"down": {"uv": [2, 0, 3, 0.25], "texture": "#top"},
|
||||
"up": {"uv": [1, 0, 2, 0.25], "texture": "#top"},
|
||||
"north": {"uv": [2.25, 0.25, 2.5, 1.25], "texture": "#top"},
|
||||
"south": {"uv": [1, 0.25, 1.25, 1.25], "texture": "#top"},
|
||||
"west": {"uv": [0, 0.25, 1, 1.25], "texture": "#top"},
|
||||
"east": {"uv": [1.25, 0.25, 2.25, 1.25], "texture": "#top"}
|
||||
}
|
||||
},
|
||||
{
|
||||
"__comment": "cubeHole3",
|
||||
"name": "cubeHole3",
|
||||
"from": [6, 1, 14],
|
||||
"to": [10, 5, 15],
|
||||
"faces": {
|
||||
"down": {"uv": [2, 0, 3, 0.25], "texture": "#all"},
|
||||
"up": {"uv": [1, 0, 2, 0.25], "texture": "#all"},
|
||||
"north": {"uv": [2.25, 0.25, 2.5, 1.25], "texture": "#all"},
|
||||
"south": {"uv": [1, 0.25, 1.25, 1.25], "texture": "#all"},
|
||||
"west": {"uv": [0, 0.25, 1, 1.25], "texture": "#all"},
|
||||
"east": {"uv": [1.25, 0.25, 2.25, 1.25], "texture": "#all"}
|
||||
"down": {"uv": [2, 0, 3, 0.25], "texture": "#top"},
|
||||
"up": {"uv": [1, 0, 2, 0.25], "texture": "#top"},
|
||||
"north": {"uv": [2.25, 0.25, 2.5, 1.25], "texture": "#top"},
|
||||
"south": {"uv": [1, 0.25, 1.25, 1.25], "texture": "#top"},
|
||||
"west": {"uv": [0, 0.25, 1, 1.25], "texture": "#top"},
|
||||
"east": {"uv": [1.25, 0.25, 2.25, 1.25], "texture": "#top"}
|
||||
}
|
||||
},
|
||||
{
|
||||
"__comment": "cubeSide1",
|
||||
"name": "cubeSide1",
|
||||
"from": [1, 0, 1],
|
||||
"to": [15, 1, 15],
|
||||
"faces": {
|
||||
"down": {"uv": [7, 0, 10.5, 3.5], "texture": "#all"},
|
||||
"up": {"uv": [3.5, 0, 7, 3.5], "texture": "#all"},
|
||||
"north": {"uv": [10.5, 3.5, 14, 3.75], "texture": "#all"},
|
||||
"south": {"uv": [3.5, 3.5, 7, 3.75], "texture": "#all"},
|
||||
"west": {"uv": [0, 3.5, 3.5, 3.75], "texture": "#all"},
|
||||
"east": {"uv": [7, 3.5, 10.5, 3.75], "texture": "#all"}
|
||||
"down": {"uv": [7, 0, 10.5, 3.5], "texture": "#side"},
|
||||
"up": {"uv": [3.5, 0, 7, 3.5], "texture": "#side"},
|
||||
"north": {"uv": [10.5, 3.5, 14, 3.75], "texture": "#side"},
|
||||
"south": {"uv": [3.5, 3.5, 7, 3.75], "texture": "#side"},
|
||||
"west": {"uv": [0, 3.5, 3.5, 3.75], "texture": "#side"},
|
||||
"east": {"uv": [7, 3.5, 10.5, 3.75], "texture": "#side"}
|
||||
}
|
||||
},
|
||||
{
|
||||
"__comment": "cubeSide3",
|
||||
"name": "cubeSide3",
|
||||
"from": [1, 1, 2],
|
||||
"to": [2, 14, 15],
|
||||
"faces": {
|
||||
"down": {"uv": [0.5, 0, 0.75, 3.25], "texture": "#all"},
|
||||
"up": {"uv": [0.25, 0, 0.5, 3.25], "texture": "#all"},
|
||||
"north": {"uv": [3.75, 3.25, 7, 6.5], "texture": "#all"},
|
||||
"south": {"uv": [0.25, 3.25, 3.5, 6.5], "texture": "#all"},
|
||||
"west": {"uv": [0, 3.25, 0.25, 6.5], "texture": "#all"},
|
||||
"east": {"uv": [3.5, 3.25, 3.75, 6.5], "texture": "#all"}
|
||||
"down": {"uv": [0.5, 0, 0.75, 3.25], "texture": "#side"},
|
||||
"up": {"uv": [0.25, 0, 0.5, 3.25], "texture": "#side"},
|
||||
"north": {"uv": [3.75, 3.25, 7, 6.5], "texture": "#side"},
|
||||
"south": {"uv": [0.25, 3.25, 3.5, 6.5], "texture": "#side"},
|
||||
"west": {"uv": [0, 3.25, 0.25, 6.5], "texture": "#side"},
|
||||
"east": {"uv": [3.5, 3.25, 3.75, 6.5], "texture": "#side"}
|
||||
}
|
||||
},
|
||||
{
|
||||
"__comment": "cubeHole1",
|
||||
"name": "cubeHole1",
|
||||
"from": [10, 1, 14],
|
||||
"to": [14, 13, 15],
|
||||
"faces": {
|
||||
"down": {"uv": [2, 0, 3, 0.25], "texture": "#all"},
|
||||
"up": {"uv": [1, 0, 2, 0.25], "texture": "#all"},
|
||||
"north": {"uv": [2.25, 0.25, 2.5, 3.25], "texture": "#all"},
|
||||
"south": {"uv": [1, 0.25, 1.25, 3.25], "texture": "#all"},
|
||||
"west": {"uv": [0, 0.25, 1, 3.25], "texture": "#all"},
|
||||
"east": {"uv": [1.25, 0.25, 2.25, 3.25], "texture": "#all"}
|
||||
"down": {"uv": [2, 0, 3, 0.25], "texture": "#top"},
|
||||
"up": {"uv": [1, 0, 2, 0.25], "texture": "#top"},
|
||||
"north": {"uv": [2.25, 0.25, 2.5, 3.25], "texture": "#top"},
|
||||
"south": {"uv": [1, 0.25, 1.25, 3.25], "texture": "#top"},
|
||||
"west": {"uv": [0, 0.25, 1, 3.25], "texture": "#top"},
|
||||
"east": {"uv": [1.25, 0.25, 2.25, 3.25], "texture": "#top"}
|
||||
}
|
||||
},
|
||||
{
|
||||
"__comment": "cubeSide2",
|
||||
"name": "cubeSide2",
|
||||
"from": [1, 1, 1],
|
||||
"to": [15, 14, 2],
|
||||
"faces": {
|
||||
"down": {"uv": [7, 0, 10.5, 0.25], "texture": "#all"},
|
||||
"up": {"uv": [3.5, 0, 7, 0.25], "texture": "#all"},
|
||||
"north": {"uv": [7.25, 0.25, 7.5, 3.5], "texture": "#all"},
|
||||
"south": {"uv": [3.5, 0.25, 3.75, 3.5], "texture": "#all"},
|
||||
"west": {"uv": [0, 0.25, 3.5, 3.5], "texture": "#all"},
|
||||
"east": {"uv": [3.75, 0.25, 7.25, 3.5], "texture": "#all"}
|
||||
"down": {"uv": [7, 0, 10.5, 0.25], "texture": "#side"},
|
||||
"up": {"uv": [3.5, 0, 7, 0.25], "texture": "#side"},
|
||||
"north": {"uv": [7.25, 0.25, 7.5, 3.5], "texture": "#side"},
|
||||
"south": {"uv": [3.5, 0.25, 3.75, 3.5], "texture": "#side"},
|
||||
"west": {"uv": [0, 0.25, 3.5, 3.5], "texture": "#side"},
|
||||
"east": {"uv": [3.75, 0.25, 7.25, 3.5], "texture": "#side"}
|
||||
}
|
||||
}
|
||||
]
|
||||
|
||||
Reference in new issue
Block a user