fix more texturing issues
This commit is contained in:
@@ -1,10 +1,12 @@
|
||||
package storagecraft.proxy;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.renderer.ItemMeshDefinition;
|
||||
import net.minecraft.client.renderer.ItemModelMesher;
|
||||
import net.minecraft.client.resources.model.ModelBakery;
|
||||
import net.minecraft.client.resources.model.ModelResourceLocation;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.client.MinecraftForgeClient;
|
||||
import net.minecraftforge.fml.client.registry.ClientRegistry;
|
||||
import net.minecraftforge.fml.common.event.FMLInitializationEvent;
|
||||
@@ -14,10 +16,7 @@ import storagecraft.StorageCraftItems;
|
||||
import storagecraft.block.BlockController;
|
||||
import storagecraft.block.EnumControllerType;
|
||||
import storagecraft.block.EnumGridType;
|
||||
import storagecraft.item.ItemCore;
|
||||
import storagecraft.item.ItemProcessor;
|
||||
import storagecraft.item.ItemStorageCell;
|
||||
import storagecraft.item.ItemStoragePart;
|
||||
import storagecraft.item.*;
|
||||
import storagecraft.render.BlockCableRenderer;
|
||||
import storagecraft.render.ItemCableRenderer;
|
||||
import storagecraft.tile.TileCable;
|
||||
@@ -59,6 +58,11 @@ public class ClientProxy extends CommonProxy
|
||||
"storagecraft:destruction_core"
|
||||
);
|
||||
|
||||
ModelBakery.addVariantName(StorageCraftItems.WIRELESS_GRID,
|
||||
"storagecraft:wireless_grid_connected",
|
||||
"storagecraft:wireless_grid_disconnected"
|
||||
);
|
||||
|
||||
ClientRegistry.bindTileEntitySpecialRenderer(TileCable.class, new BlockCableRenderer());
|
||||
|
||||
MinecraftForgeClient.registerItemRenderer(Item.getItemFromBlock(StorageCraftBlocks.CABLE), new ItemCableRenderer());
|
||||
@@ -99,6 +103,14 @@ public class ClientProxy extends CommonProxy
|
||||
mesher.register(StorageCraftItems.CORE, ItemCore.TYPE_DESTRUCTION, new ModelResourceLocation("storagecraft:destruction_core", "inventory"));
|
||||
|
||||
mesher.register(StorageCraftItems.WIRELESS_GRID_PLATE, 0, new ModelResourceLocation("storagecraft:wireless_grid_plate", "inventory"));
|
||||
mesher.register(StorageCraftItems.WIRELESS_GRID, new ItemMeshDefinition()
|
||||
{
|
||||
@Override
|
||||
public ModelResourceLocation getModelLocation(ItemStack stack)
|
||||
{
|
||||
return new ModelResourceLocation("storagecraft:wireless_grid_" + (ItemWirelessGrid.isValid(stack) ? "connected" : "disconnected"), "inventory");
|
||||
}
|
||||
});
|
||||
|
||||
// Blocks
|
||||
mesher.register(Item.getItemFromBlock(StorageCraftBlocks.GRID), EnumGridType.NORMAL.getId(), new ModelResourceLocation("storagecraft:grid", "inventory"));
|
||||
|
Reference in New Issue
Block a user