Change Constants to Uppercase
This commit is contained in:
parent
df68a49f3c
commit
3bc388f198
24 changed files with 53 additions and 43 deletions
|
|
@ -21,15 +21,15 @@ import net.minecraftforge.fml.common.event.FMLInitializationEvent;
|
|||
import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
|
||||
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
|
||||
|
||||
@Mod(modid = Lib.modid, name = Lib.name, version = Lib.version, guiFactory = Lib.guifactory, acceptedMinecraftVersions = "1.8.8, 1.8.9")
|
||||
@Mod(modid = Lib.MODID, name = Lib.NAME, version = Lib.VERSION, guiFactory = Lib.GUI_FACTORY, acceptedMinecraftVersions = "1.8.8, 1.8.9")
|
||||
public class CrissCross
|
||||
{
|
||||
public static CreativeTabs CCTab = new CreativeTab();
|
||||
|
||||
@Instance(Lib.modid)
|
||||
@Instance(Lib.MODID)
|
||||
public static CrissCross instance;
|
||||
|
||||
@SidedProxy(clientSide = Lib.clientProxy, serverSide = Lib.commonProxy)
|
||||
@SidedProxy(clientSide = Lib.CLIENT_PROXY, serverSide = Lib.COMMON_PROXY)
|
||||
public static CommonProxy proxy;
|
||||
|
||||
@EventHandler
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ public class BlockMachineBase extends BlockContainer
|
|||
this.setHardness(2.0F);
|
||||
this.setResistance(2.0F);
|
||||
this.setStepSound(soundTypeMetal);
|
||||
this.setUnlocalizedName(Lib.modid + "." + unlocName);
|
||||
this.setUnlocalizedName(Lib.MODID + "." + unlocName);
|
||||
this.setCreativeTab(CrissCross.CCTab);
|
||||
this.unlocalizedName = unlocName;
|
||||
this.setDefaultState(this.blockState.getBaseState().withProperty(FACING, EnumFacing.NORTH));
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ public class ConfigGUI extends GuiConfig
|
|||
{
|
||||
public ConfigGUI(GuiScreen guiScreen)
|
||||
{
|
||||
super(guiScreen, getConfigElements(), Lib.modid, false, true, GuiConfig.getAbridgedConfigPath(Config.config.toString()));
|
||||
super(guiScreen, getConfigElements(), Lib.MODID, false, true, GuiConfig.getAbridgedConfigPath(Config.config.toString()));
|
||||
}
|
||||
|
||||
private static List<IConfigElement> getConfigElements()
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ import net.minecraft.util.StatCollector;
|
|||
|
||||
public class GUICropomator extends GuiContainer
|
||||
{
|
||||
public static final ResourceLocation texture = new ResourceLocation("crisscross", "textures/gui/cropomator.png");
|
||||
public static final ResourceLocation backgroundTexture = new ResourceLocation("crisscross", "textures/gui/cropomator.png");
|
||||
|
||||
private TileCropomator cropomator;
|
||||
|
||||
|
|
@ -33,7 +33,7 @@ public class GUICropomator extends GuiContainer
|
|||
protected void drawGuiContainerBackgroundLayer(float partialTickTime, int mouseX, int mouseY)
|
||||
{
|
||||
GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
this.mc.renderEngine.bindTexture(texture);
|
||||
this.mc.renderEngine.bindTexture(backgroundTexture);
|
||||
int k = (this.width - this.xSize) / 2;
|
||||
int l = (this.height - this.ySize) / 2;
|
||||
this.drawTexturedModalRect(k, l, 0, 0, this.xSize, this.ySize);
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ import net.minecraft.util.StatCollector;
|
|||
|
||||
public class GUIElectroextractor extends GuiContainer
|
||||
{
|
||||
public static final ResourceLocation texture = new ResourceLocation("crisscross", "textures/gui/electroextractor.png");
|
||||
public static final ResourceLocation backgroundTexture = new ResourceLocation("crisscross", "textures/gui/electroextractor.png");
|
||||
|
||||
private TileElectroextractor electroextractor;
|
||||
|
||||
|
|
@ -31,7 +31,7 @@ public class GUIElectroextractor extends GuiContainer
|
|||
protected void drawGuiContainerBackgroundLayer(float partialTickTime, int mouseX, int mouseY)
|
||||
{
|
||||
GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
this.mc.renderEngine.bindTexture(texture);
|
||||
this.mc.renderEngine.bindTexture(backgroundTexture);
|
||||
int k = (this.width - this.xSize) / 2;
|
||||
int l = (this.height - this.ySize) / 2;
|
||||
this.drawTexturedModalRect(k, l, 0, 0, this.xSize, this.ySize);
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ import net.minecraft.util.StatCollector;
|
|||
|
||||
public class GUIScribe extends GuiContainer
|
||||
{
|
||||
public static final ResourceLocation texture = new ResourceLocation("crisscross", "textures/gui/scribe.png");
|
||||
public static final ResourceLocation backgroundTexture = new ResourceLocation("crisscross", "textures/gui/scribe.png");
|
||||
|
||||
private TileScribe scribe;
|
||||
|
||||
|
|
@ -31,7 +31,7 @@ public class GUIScribe extends GuiContainer
|
|||
protected void drawGuiContainerBackgroundLayer(float partialTickTime, int mouseX, int mouseY)
|
||||
{
|
||||
GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
this.mc.renderEngine.bindTexture(texture);
|
||||
this.mc.renderEngine.bindTexture(backgroundTexture);
|
||||
int k = (this.width - this.xSize) / 2;
|
||||
int l = (this.height - this.ySize) / 2;
|
||||
this.drawTexturedModalRect(k, l, 0, 0, this.xSize, this.ySize);
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ import net.minecraft.util.StatCollector;
|
|||
|
||||
public class GUIWoodchipper extends GuiContainer
|
||||
{
|
||||
public static final ResourceLocation texture = new ResourceLocation("crisscross", "textures/gui/woodchipper.png");
|
||||
public static final ResourceLocation backgroundTexture = new ResourceLocation("crisscross", "textures/gui/woodchipper.png");
|
||||
|
||||
private TileWoodchipper woodchipper;
|
||||
|
||||
|
|
@ -31,7 +31,7 @@ public class GUIWoodchipper extends GuiContainer
|
|||
protected void drawGuiContainerBackgroundLayer(float partialTickTime, int mouseX, int mouseY)
|
||||
{
|
||||
GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
this.mc.renderEngine.bindTexture(texture);
|
||||
this.mc.renderEngine.bindTexture(backgroundTexture);
|
||||
int k = (this.width - this.xSize) / 2;
|
||||
int l = (this.height - this.ySize) / 2;
|
||||
this.drawTexturedModalRect(k, l, 0, 0, this.xSize, this.ySize);
|
||||
|
|
|
|||
|
|
@ -74,7 +74,7 @@ public class ItemDust extends Item
|
|||
@Override
|
||||
public String getUnlocalizedName(ItemStack itemStack)
|
||||
{
|
||||
return "item." + Lib.modid + ".dust";
|
||||
return "item." + Lib.MODID + ".dust";
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ public class ItemInfiniApple extends Item
|
|||
{
|
||||
this.setMaxStackSize(1);
|
||||
this.setCreativeTab(CrissCross.CCTab);
|
||||
this.setUnlocalizedName(Lib.modid + ".infini_apple");
|
||||
this.setUnlocalizedName(Lib.MODID + ".infini_apple");
|
||||
GameRegistry.registerItem(this, this.getUnlocalizedName());
|
||||
MinecraftForge.EVENT_BUS.register(new InfiniAppleEvent());
|
||||
Lib.add(this);
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ public class ItemMantleSmasher extends ItemPickaxe
|
|||
public ItemMantleSmasher(ToolMaterial material)
|
||||
{
|
||||
super(material);
|
||||
this.setUnlocalizedName(Lib.modid + ".mantle_smasher_" + material.name());
|
||||
this.setUnlocalizedName(Lib.MODID + ".mantle_smasher_" + material.name());
|
||||
this.setCreativeTab(CrissCross.CCTab);
|
||||
MinecraftForge.EVENT_BUS.register(new ToolEfficiencyEvent());
|
||||
GameRegistry.registerItem(this, this.getUnlocalizedName());
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ public class ItemModBuckets extends Item
|
|||
this.maxStackSize = 1;
|
||||
this.setCreativeTab(CrissCross.CCTab);
|
||||
this.setContainerItem(this);
|
||||
this.setUnlocalizedName(Lib.modid + ".special_bucket");
|
||||
this.setUnlocalizedName(Lib.MODID + ".special_bucket");
|
||||
GameRegistry.registerItem(this, "special_bucket");
|
||||
Lib.add(this);
|
||||
}
|
||||
|
|
@ -119,7 +119,7 @@ public class ItemModBuckets extends Item
|
|||
@Override
|
||||
public String getUnlocalizedName(ItemStack itemStack)
|
||||
{
|
||||
return "item." + Lib.modid + "." + types[itemStack.getItemDamage()];
|
||||
return "item." + Lib.MODID + "." + types[itemStack.getItemDamage()];
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ public class ItemPouch extends Item
|
|||
public ItemPouch()
|
||||
{
|
||||
this.setMaxStackSize(1);
|
||||
this.setUnlocalizedName(Lib.modid + ".pouch");
|
||||
this.setUnlocalizedName(Lib.MODID + ".pouch");
|
||||
this.setCreativeTab(CrissCross.CCTab);
|
||||
GameRegistry.registerItem(this, this.getUnlocalizedName());
|
||||
MinecraftForge.EVENT_BUS.register(new PouchCleanEvent());
|
||||
|
|
|
|||
|
|
@ -173,7 +173,7 @@ public class Config
|
|||
@SubscribeEvent
|
||||
public void onConfigurationChangedEvent(ConfigChangedEvent.OnConfigChangedEvent event)
|
||||
{
|
||||
if (event.modID.equalsIgnoreCase(Lib.modid))
|
||||
if (event.modID.equalsIgnoreCase(Lib.MODID))
|
||||
loadConfiguration();
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ public class CreativeTab extends CreativeTabs
|
|||
{
|
||||
public CreativeTab()
|
||||
{
|
||||
super(CreativeTabs.getNextID(), "tab" + Lib.modid);
|
||||
super(CreativeTabs.getNextID(), "tab" + Lib.MODID);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -7,13 +7,18 @@ import net.minecraft.item.Item;
|
|||
|
||||
public class Lib
|
||||
{
|
||||
public static final String modid = "CrissCross";
|
||||
public static final String name = "CrissCross";
|
||||
public static final String version = "@VERSION@";
|
||||
public static final String guifactory = "com.oitsjustjose.criss_cross.gui.ConfigGUI$GUIFactory";
|
||||
public static final String clientProxy = "com.oitsjustjose.criss_cross.util.ClientProxy";
|
||||
public static final String commonProxy = "com.oitsjustjose.criss_cross.util.CommonProxy";
|
||||
|
||||
public static final String MODID = "CrissCross";
|
||||
public static final String NAME = "CrissCross";
|
||||
public static final String VERSION = "@VERSION@";
|
||||
public static final String GUI_FACTORY = "com.oitsjustjose.criss_cross.gui.ConfigGUI$GUIFactory";
|
||||
public static final String CLIENT_PROXY = "com.oitsjustjose.criss_cross.util.ClientProxy";
|
||||
public static final String COMMON_PROXY = "com.oitsjustjose.criss_cross.util.CommonProxy";
|
||||
|
||||
public static final String CROPOMATOR_UID = MODID + ":Cropomator";
|
||||
public static final String ELECTROEXTRACTOR_UID = MODID + ":Electroextractor";
|
||||
public static final String WOODCHIPPER_UID = MODID + ":Woodchipper";
|
||||
public static final String SCRIBE_UID = MODID + ":Scribe";
|
||||
|
||||
private static final ArrayList<Item> allItems = new ArrayList<Item>();
|
||||
private static final ArrayList<Block> allBlocks = new ArrayList<Block>();
|
||||
|
||||
|
|
|
|||
|
|
@ -15,8 +15,7 @@ public class TileAtmosManipulator extends TileEntity implements ITickable
|
|||
@Override
|
||||
public void update()
|
||||
{
|
||||
if (worldObj.isRemote)
|
||||
System.out.println(worldObj.isRaining());
|
||||
|
||||
}
|
||||
|
||||
public void setRain()
|
||||
|
|
|
|||
|
|
@ -176,7 +176,7 @@ public class TileCobblegen extends TileEntityLockable implements ITickable, ISid
|
|||
@Override
|
||||
public String getGuiID()
|
||||
{
|
||||
return Lib.modid + ":container.cobblestonegen";
|
||||
return Lib.MODID + ":container.cobblestonegen";
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -179,7 +179,7 @@ public class TileCropomator extends TileEntityLockable implements ITickable, ISi
|
|||
@Override
|
||||
public String getGuiID()
|
||||
{
|
||||
return Lib.modid + ":container.cropomator";
|
||||
return Lib.MODID + ":container.cropomator";
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -283,6 +283,12 @@ public class TileElectroextractor extends TileEntityLockable implements ITickabl
|
|||
return false;
|
||||
}
|
||||
|
||||
public static ArrayList<ItemStack> getFuels()
|
||||
{
|
||||
return fuelItems;
|
||||
|
||||
}
|
||||
|
||||
public static boolean isValid(ItemStack itemstack)
|
||||
{
|
||||
if (ElectroextractorRecipes.getInstance().getResult(itemstack) != null)
|
||||
|
|
@ -414,7 +420,7 @@ public class TileElectroextractor extends TileEntityLockable implements ITickabl
|
|||
@Override
|
||||
public String getGuiID()
|
||||
{
|
||||
return Lib.modid + ":container.electroextractor";
|
||||
return Lib.MODID + ":container.electroextractor";
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -168,7 +168,7 @@ public class TileScribe extends TileEntityLockable implements ITickable, ISidedI
|
|||
@Override
|
||||
public String getGuiID()
|
||||
{
|
||||
return Lib.modid + ":container.scribe";
|
||||
return Lib.MODID + ":container.scribe";
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -178,7 +178,7 @@ public class TileStonegen extends TileEntityLockable implements ITickable, ISide
|
|||
@Override
|
||||
public String getGuiID()
|
||||
{
|
||||
return Lib.modid + ":container.stonegen";
|
||||
return Lib.MODID + ":container.stonegen";
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -178,7 +178,7 @@ public class TileWoodchipper extends TileEntityLockable implements ITickable, IS
|
|||
@Override
|
||||
public String getGuiID()
|
||||
{
|
||||
return Lib.modid + ":container.woodchipper";
|
||||
return Lib.MODID + ":container.woodchipper";
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -43,8 +43,8 @@ public class ClientProxy extends CommonProxy
|
|||
for (ItemStack sub : subItems)
|
||||
{
|
||||
String name = item.getUnlocalizedName(sub).substring(16).toLowerCase();
|
||||
ModelBakery.addVariantName(item, Lib.modid.toLowerCase() + ":" + name);
|
||||
Minecraft.getMinecraft().getRenderItem().getItemModelMesher().register(item, meta, new ModelResourceLocation(Lib.modid.toLowerCase() + ":" + name, "inventory"));
|
||||
ModelBakery.addVariantName(item, Lib.MODID.toLowerCase() + ":" + name);
|
||||
Minecraft.getMinecraft().getRenderItem().getItemModelMesher().register(item, meta, new ModelResourceLocation(Lib.MODID.toLowerCase() + ":" + name, "inventory"));
|
||||
meta++;
|
||||
}
|
||||
|
||||
|
|
@ -62,14 +62,14 @@ public class ClientProxy extends CommonProxy
|
|||
for (ItemStack sub : subItems)
|
||||
{
|
||||
String name = itemBlock.getUnlocalizedName(sub).toLowerCase().replace("crisscross.", "").replace("tile.", "");
|
||||
ModelBakery.addVariantName(itemBlock, Lib.modid.toLowerCase() + ":" + name);
|
||||
Minecraft.getMinecraft().getRenderItem().getItemModelMesher().register(itemBlock, meta, new ModelResourceLocation(Lib.modid.toLowerCase() + ":" + name, "inventory"));
|
||||
ModelBakery.addVariantName(itemBlock, Lib.MODID.toLowerCase() + ":" + name);
|
||||
Minecraft.getMinecraft().getRenderItem().getItemModelMesher().register(itemBlock, meta, new ModelResourceLocation(Lib.MODID.toLowerCase() + ":" + name, "inventory"));
|
||||
meta++;
|
||||
}
|
||||
}
|
||||
else if (customName == "")
|
||||
Minecraft.getMinecraft().getRenderItem().getItemModelMesher().register(itemBlock, 0, new ModelResourceLocation(Lib.modid.toLowerCase() + ":" + block.getUnlocalizedName().substring(16).toLowerCase(), "inventory"));
|
||||
Minecraft.getMinecraft().getRenderItem().getItemModelMesher().register(itemBlock, 0, new ModelResourceLocation(Lib.MODID.toLowerCase() + ":" + block.getUnlocalizedName().substring(16).toLowerCase(), "inventory"));
|
||||
else
|
||||
Minecraft.getMinecraft().getRenderItem().getItemModelMesher().register(itemBlock, 0, new ModelResourceLocation(Lib.modid.toLowerCase() + ":" + customName, "inventory"));
|
||||
Minecraft.getMinecraft().getRenderItem().getItemModelMesher().register(itemBlock, 0, new ModelResourceLocation(Lib.MODID.toLowerCase() + ":" + customName, "inventory"));
|
||||
}
|
||||
}
|
||||
|
|
@ -7,7 +7,7 @@ import com.oitsjustjose.criss_cross.lib.Lib;
|
|||
|
||||
public class LogHelper
|
||||
{
|
||||
private static Logger LOGGER = LogManager.getLogger(Lib.modid);
|
||||
private static Logger LOGGER = LogManager.getLogger(Lib.MODID);
|
||||
|
||||
public LogHelper()
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in a new issue