Big code cleanup

This commit is contained in:
mezz committed 2016-05-01 15:34:11 -07:00
1 parent 1b58077904
commit a3363fb4bc
132 files changed
+1587 -1863

No files matched your search

@@ -12,8 +12,10 @@ package forestry.greenhouse.proxy;
import net.minecraft.block.Block;
import net.minecraft.client.resources.model.ModelResourceLocation;
import net.minecraftforge.client.model.animation.AnimationTESR;
import net.minecraftforge.fml.client.registry.ClientRegistry;
import forestry.core.models.BlockModelIndex;
import forestry.core.proxy.Proxies;
import forestry.greenhouse.PluginGreenhouse;
@@ -25,17 +27,16 @@ public class ProxyGreenhouseClient extends ProxyGreenhouse {
@Override
public void initializeModels() {
for(BlockGreenhouseType greenhouseType : BlockGreenhouseType.VALUES){
if(greenhouseType == BlockGreenhouseType.DOOR) {
for (BlockGreenhouseType greenhouseType : BlockGreenhouseType.VALUES) {
if (greenhouseType == BlockGreenhouseType.DOOR) {
continue;
}
else if(greenhouseType == BlockGreenhouseType.SPRINKLER){
ClientRegistry.bindTileEntitySpecialRenderer(TileGreenhouseSprinkler.class, new AnimationTESR());
} else if (greenhouseType == BlockGreenhouseType.SPRINKLER) {
ClientRegistry.bindTileEntitySpecialRenderer(TileGreenhouseSprinkler.class, new AnimationTESR<>());
continue;
}
Proxies.render.registerBlockModel(new BlockModelIndex(new ModelResourceLocation("forestry:greenhouse." + greenhouseType),
new ModelResourceLocation("forestry:greenhouse", "inventory"), new ModelGreenhouse(),
Block.getBlockFromItem(PluginGreenhouse.blocks.getGreenhouseBlock(greenhouseType).getItem())));
new ModelResourceLocation("forestry:greenhouse", "inventory"), new ModelGreenhouse(),
Block.getBlockFromItem(PluginGreenhouse.blocks.getGreenhouseBlock(greenhouseType).getItem())));
}
}
}