Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Nicba1010

Forge Modder
  • Joined

  • Last visited

Everything posted by Nicba1010

  1. OMG THANKS. You will definetly be credited man.
  2. I DID 5 http://www.minecraftforge.net/wiki/Gui_Overlay
  3. package nicba1010.chemistryzation.common; import net.minecraft.block.Block; import net.minecraft.block.material.Material; import net.minecraft.client.Minecraft; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraft.item.crafting.FurnaceRecipes; import net.minecraftforge.common.MinecraftForge; import cpw.mods.fml.common.Mod; import cpw.mods.fml.common.Mod.Init; import cpw.mods.fml.common.Mod.PostInit; import cpw.mods.fml.common.event.FMLInitializationEvent; import cpw.mods.fml.common.event.FMLPostInitializationEvent; import cpw.mods.fml.common.network.NetworkMod; import cpw.mods.fml.common.registry.GameRegistry; import cpw.mods.fml.common.registry.LanguageRegistry; @Mod(modid = Chemistryzation.modid, name = "chemistryzation", version = "0") @NetworkMod(clientSideRequired = true, serverSideRequired = false) public class Chemistryzation { public static final String modid = "chemistryzation"; public static Block NaClBlock; public static Item NaClItem, NaClInBucketSolid, NaClInBucketMelted, TestTube, NaClInTestTubeSolid; @Init public void load(FMLInitializationEvent event) { NaClBlock = new BlockNaClBlock(500, Material.rock) .setUnlocalizedName("NaClBlock"); GameRegistry.registerBlock(NaClBlock, modid + "NaClBlock"); LanguageRegistry.addName(NaClBlock, "Salt"); NaClItem = new ItemNaClItem(5000).setUnlocalizedName("NaClItem"); LanguageRegistry.addName(NaClItem, "NaCl"); NaClInBucketSolid = new NaClInBucketSolid(5001) .setUnlocalizedName("NaClInBucketSolid"); LanguageRegistry.addName(NaClInBucketSolid, "NaCl"); NaClInBucketMelted = new NaClInBucketMelted(5002) .setUnlocalizedName("NaClInBucketMelted"); LanguageRegistry.addName(NaClInBucketMelted, "NaCl"); TestTube = new TestTube(5003).setUnlocalizedName("TestTube"); LanguageRegistry.addName(TestTube, "Test Tube"); NaClInTestTubeSolid = new NaClInTestTubeSolid(5004) .setUnlocalizedName("NaClInTestTubeSolid"); LanguageRegistry.addName(NaClInTestTubeSolid, "NaCl"); GameRegistry.addRecipe(new ItemStack(Chemistryzation.TestTube, , "XYX", "X X", " X ", Character.valueOf('X'), new ItemStack( Block.glass), Character.valueOf('Y'), Item.slimeBall); ItemStack NaClItemStack = new ItemStack(Chemistryzation.NaClItem); GameRegistry.addShapelessRecipe(new ItemStack(NaClInBucketSolid), new Object[] { NaClItemStack, NaClItemStack, NaClItemStack, NaClItemStack, NaClItemStack, NaClItemStack, NaClItemStack, NaClItemStack, new ItemStack(Item.bucketEmpty) }); GameRegistry .addShapelessRecipe(new ItemStack(NaClInTestTubeSolid), new Object[] { NaClItemStack, NaClItemStack, NaClItemStack, NaClItemStack, new ItemStack(Chemistryzation.TestTube) }); FurnaceRecipes.smelting().addSmelting( Chemistryzation.NaClInBucketSolid.itemID, 0, new ItemStack(Chemistryzation.NaClInBucketMelted), 0.1F); } @PostInit public void postInit(FMLPostInitializationEvent event) { MinecraftForge.EVENT_BUS.register(new GuiChemistryLevel(Minecraft .getMinecraft())); } }
  4. errors on p.getEntityData !
  5. BTW STILL Caught exception from chemistryzation java.lang.NullPointerException at nicba1010.chemistryzation.common.GuiChemistryLevel.<init>(GuiChemistryLevel.java:49) at nicba1010.chemistryzation.common.Chemistryzation.postInit(Chemistryzation.java:76) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at cpw.mods.fml.common.FMLModContainer.handleModStateEvent(FMLModContainer.java:494) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at com.google.common.eventbus.EventHandler.handleEvent(EventHandler.java:74) at com.google.common.eventbus.SynchronizedEventHandler.handleEvent(SynchronizedEventHandler.java:45) at com.google.common.eventbus.EventBus.dispatch(EventBus.java:314) at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:296) at com.google.common.eventbus.EventBus.post(EventBus.java:267) at cpw.mods.fml.common.LoadController.propogateStateMessage(LoadController.java:165) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at com.google.common.eventbus.EventHandler.handleEvent(EventHandler.java:74) at com.google.common.eventbus.SynchronizedEventHandler.handleEvent(SynchronizedEventHandler.java:45) at com.google.common.eventbus.EventBus.dispatch(EventBus.java:314) at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:296) at com.google.common.eventbus.EventBus.post(EventBus.java:267) at cpw.mods.fml.common.LoadController.distributeStateMessage(LoadController.java:98) at cpw.mods.fml.common.Loader.initializeMods(Loader.java:695) at cpw.mods.fml.client.FMLClientHandler.finishMinecraftLoading(FMLClientHandler.java:206) at net.minecraft.client.Minecraft.startGame(Minecraft.java:447) at net.minecraft.client.MinecraftAppletImpl.startGame(MinecraftAppletImpl.java:44) at net.minecraft.client.Minecraft.run(Minecraft.java:732) at java.lang.Thread.run(Unknown Source) 2013-06-27 16:23:32 [iNFO] [sTDERR] java.lang.NullPointerException 2013-06-27 16:23:32 [iNFO] [sTDERR] at nicba1010.chemistryzation.common.GuiChemistryLevel.<init>(GuiChemistryLevel.java:49) 2013-06-27 16:23:32 [iNFO] [sTDERR] at nicba1010.chemistryzation.common.Chemistryzation.postInit(Chemistryzation.java:76) 2013-06-27 16:23:32 [iNFO] [sTDERR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 2013-06-27 16:23:32 [iNFO] [sTDERR] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) 2013-06-27 16:23:32 [iNFO] [sTDERR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) 2013-06-27 16:23:32 [iNFO] [sTDERR] at java.lang.reflect.Method.invoke(Unknown Source) 2013-06-27 16:23:32 [iNFO] [sTDERR] at cpw.mods.fml.common.FMLModContainer.handleModStateEvent(FMLModContainer.java:494) 2013-06-27 16:23:32 [iNFO] [sTDERR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 2013-06-27 16:23:32 [iNFO] [sTDERR] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) 2013-06-27 16:23:32 [iNFO] [sTDERR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) 2013-06-27 16:23:32 [iNFO] [sTDERR] at java.lang.reflect.Method.invoke(Unknown Source) 2013-06-27 16:23:32 [iNFO] [sTDERR] at com.google.common.eventbus.EventHandler.handleEvent(EventHandler.java:74) 2013-06-27 16:23:32 [iNFO] [sTDERR] at com.google.common.eventbus.SynchronizedEventHandler.handleEvent(SynchronizedEventHandler.java:45) 2013-06-27 16:23:32 [iNFO] [sTDERR] at com.google.common.eventbus.EventBus.dispatch(EventBus.java:314) 2013-06-27 16:23:32 [iNFO] [sTDERR] at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:296) 2013-06-27 16:23:32 [iNFO] [sTDERR] at com.google.common.eventbus.EventBus.post(EventBus.java:267) 2013-06-27 16:23:32 [iNFO] [sTDERR] at cpw.mods.fml.common.LoadController.propogateStateMessage(LoadController.java:165) 2013-06-27 16:23:32 [iNFO] [sTDERR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 2013-06-27 16:23:32 [iNFO] [sTDERR] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) 2013-06-27 16:23:32 [iNFO] [sTDERR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) 2013-06-27 16:23:32 [iNFO] [sTDERR] at java.lang.reflect.Method.invoke(Unknown Source) 2013-06-27 16:23:32 [iNFO] [sTDERR] at com.google.common.eventbus.EventHandler.handleEvent(EventHandler.java:74) 2013-06-27 16:23:32 [iNFO] [sTDERR] at com.google.common.eventbus.SynchronizedEventHandler.handleEvent(SynchronizedEventHandler.java:45) 2013-06-27 16:23:32 [iNFO] [sTDERR] at com.google.common.eventbus.EventBus.dispatch(EventBus.java:314) 2013-06-27 16:23:32 [iNFO] [sTDERR] at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:296) 2013-06-27 16:23:32 [iNFO] [sTDERR] at com.google.common.eventbus.EventBus.post(EventBus.java:267) 2013-06-27 16:23:32 [iNFO] [sTDERR] at cpw.mods.fml.common.LoadController.distributeStateMessage(LoadController.java:98) 2013-06-27 16:23:32 [iNFO] [sTDERR] at cpw.mods.fml.common.Loader.initializeMods(Loader.java:695) 2013-06-27 16:23:32 [iNFO] [sTDERR] at cpw.mods.fml.client.FMLClientHandler.finishMinecraftLoading(FMLClientHandler.java:206) 2013-06-27 16:23:32 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.startGame(Minecraft.java:447) 2013-06-27 16:23:32 [iNFO] [sTDERR] at net.minecraft.client.MinecraftAppletImpl.startGame(MinecraftAppletImpl.java:44) 2013-06-27 16:23:32 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.run(Minecraft.java:732) 2013-06-27 16:23:32 [iNFO] [sTDERR] at java.lang.Thread.run(Unknown Source)
  6. ive modifed and put side only but it doesnt work :'( pls could you modify my gui code for me
  7. Minecraft.getMinecraft().thePlayer still gives me null pointer
  8. this is the core of the problem: how can i get the entityplayer in my gui class
  9. so, you mean i save the data to the world as an array about info on the player?
  10. So, is there any chance i can do what i want?
  11. I am trying to make a level system. I have succseeded in some places but in other not. The main problem is: how to get current minecraft player, like i mean EntityPlayer. Here is the error log: http://pastebin.com/ZMVjyjD6 This is the Gui class code:http://pastebin.com/LkVbuNQB Before i have had EntityPlayer p = mc.theplayer; but this doesn't work. Example where it works: I the Block On Activated method: public boolean onBlockActivated(World world, int x, int y, int z,EntityPlayer p, int a, float f, float b, float c){ nbt=p.getEntityData(); nbt.setInteger("level", getLevel()+1); return true; } public int getLevel() { return nbt.getInteger("level"); } because here i have the EntityPlayer supplied. Chemistryzation.java(main class):http://pastebin.com/aNg5VYCq Please help! For any useful info you will be credited!

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.