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.

Featured Replies

Posted

I may have missed some think and just been really blind to something in the code but I am having a problem were I can create a new item fine and add it to the game all works fine but when i go to add a basic block minecraft loads but when i open a world existing or new it crashes.

 

I can Add what ever code is need to help me with this if anyone has an idea about this.

Thank you 

this is the block class

package green.mods.lapfuel.Blocks;

import green.mods.lapfuel.lib.BlockIDs;
import green.mods.lapfuel.lib.Strings;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.creativetab.CreativeTabs;

public class LapronBlock extends Block {

public LapronBlock(int id){
	super(BlockIDs.LAPRON_BLOCK, Material.rock);
	this.setResistance(3F);
	this.setCreativeTab(CreativeTabs.tabBlock);
	this.setUnlocalizedName(Strings.LAPRON_BLOCK_NAME);


}
public void registerIcons(IconRegister iconRegister)
{
         blockIcon = iconRegister.registerIcon("LapronBlock");
}

}

 

 

This is the code for the mod Blocks class

package green.mods.lapfuel.Blocks;

import cpw.mods.fml.common.registry.GameRegistry;
import cpw.mods.fml.common.registry.LanguageRegistry;
import green.mods.lapfuel.lib.BlockIDs;
import green.mods.lapfuel.lib.Strings;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraftforge.common.MinecraftForge;
import green.mods.lapfuel.core.Main;

public class LapFuelBlocks {




public static Block LapronBlock;

public static void init(){

	LapronBlock = new LapronBlock(BlockIDs.LAPRON_BLOCK);


	LanguageRegistry.addName(LapronBlock, "Lapron Block");
	GameRegistry.registerBlock(LapronBlock, Strings.LAPRON_BLOCK_NAME);
	MinecraftForge.setBlockHarvestLevel(LapronBlock, "pickaxe", 3);

}


}

I'm not completely positive, but I believe your problem is you haven't added a variable for the material, it should be something like this:

Public LapronBlock(int id, Material mat)

instead of what you currently have it. Try that and if it doesn't work post the error on here.

 

I am the current head modder for the Metroid Prime Suits mod. I have no other staff members, so I'm hiring! I also co-own the SkyTekkit server.

width=600 height=126http://i1276.photobucket.com/albums/y480/Sypher40/MPSbanner_zps9d50d86a.png[/img]

  • Author

Thank you for the help sadly it did not work but i did get the error from eclipse

 

2013-04-29 22:05:21 [iNFO] [sTDERR] java.lang.OutOfMemoryError: Java heap space
2013-04-29 22:05:21 [iNFO] [sTDERR] 	at net.minecraft.util.AABBPool.getAABB(AABBPool.java:50)
2013-04-29 22:05:21 [iNFO] [sTDERR] 	at net.minecraft.util.AxisAlignedBB.expand(AxisAlignedBB.java:111)
2013-04-29 22:05:21 [iNFO] [sTDERR] 	at net.minecraft.world.World.getCollidingBoundingBoxes(World.java:1690)
2013-04-29 22:05:21 [iNFO] [sTDERR] 	at net.minecraft.entity.player.EntityPlayerMP.<init>(EntityPlayerMP.java:178)
2013-04-29 22:05:21 [iNFO] [sTDERR] 	at net.minecraft.server.management.ServerConfigurationManager.createPlayerForUser(ServerConfigurationManager.java:383)
2013-04-29 22:05:21 [iNFO] [sTDERR] 	at net.minecraft.server.integrated.IntegratedServerListenThread.networkTick(IntegratedServerListenThread.java:91)
2013-04-29 22:05:21 [iNFO] [sTDERR] 	at net.minecraft.server.MinecraftServer.updateTimeLightAndEntities(MinecraftServer.java:674)
2013-04-29 22:05:21 [iNFO] [sTDERR] 	at net.minecraft.server.MinecraftServer.tick(MinecraftServer.java:570)
2013-04-29 22:05:21 [iNFO] [sTDERR] 	at net.minecraft.server.integrated.IntegratedServer.tick(IntegratedServer.java:127)
2013-04-29 22:05:21 [iNFO] [sTDERR] 	at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:468)
2013-04-29 22:05:21 [iNFO] [sTDERR] 	at net.minecraft.server.ThreadMinecraftServer.run(ThreadMinecraftServer.java:16)
2013-04-29 22:05:21 [sEVERE] [Minecraft-Server] Encountered an unexpected exception OutOfMemoryError
java.lang.OutOfMemoryError: Java heap space
at net.minecraft.util.AABBPool.getAABB(AABBPool.java:50)
at net.minecraft.util.AxisAlignedBB.expand(AxisAlignedBB.java:111)
at net.minecraft.world.World.getCollidingBoundingBoxes(World.java:1690)
at net.minecraft.entity.player.EntityPlayerMP.<init>(EntityPlayerMP.java:178)
at net.minecraft.server.management.ServerConfigurationManager.createPlayerForUser(ServerConfigurationManager.java:383)
at net.minecraft.server.integrated.IntegratedServerListenThread.networkTick(IntegratedServerListenThread.java:91)
at net.minecraft.server.MinecraftServer.updateTimeLightAndEntities(MinecraftServer.java:674)
at net.minecraft.server.MinecraftServer.tick(MinecraftServer.java:570)
at net.minecraft.server.integrated.IntegratedServer.tick(IntegratedServer.java:127)
at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:468)
at net.minecraft.server.ThreadMinecraftServer.run(ThreadMinecraftServer.java:16)
2013-04-29 22:05:30 [sEVERE] [Minecraft-Server] This crash report has been saved to: C:\Users\Jordan\Desktop\Hide\Green's Mod\jars\.\crash-reports\crash-2013-04-29_22.05.27-server.txt
2013-04-29 22:05:30 [iNFO] [Minecraft-Server] Stopping server
2013-04-29 22:05:30 [iNFO] [Minecraft-Server] Saving players
2013-04-29 22:05:30 [iNFO] [Minecraft-Server] Saving worlds
2013-04-29 22:05:30 [iNFO] [Minecraft-Server] Saving chunks for level 'Test'/Overworld
2013-04-29 22:05:57 [iNFO] [sTDERR] java.lang.OutOfMemoryError: Java heap space
2013-04-29 22:05:57 [iNFO] [sTDERR] 	at java.util.HashMap.<init>(Unknown Source)
2013-04-29 22:05:57 [iNFO] [sTDERR] 	at java.util.HashMap.<init>(Unknown Source)
2013-04-29 22:05:57 [iNFO] [sTDERR] 	at net.minecraft.nbt.NBTTagCompound.<init>(NBTTagCompound.java:19)
2013-04-29 22:05:57 [iNFO] [sTDERR] 	at net.minecraft.world.chunk.storage.AnvilChunkLoader.writeChunkToNBT(AnvilChunkLoader.java:333)
2013-04-29 22:05:57 [iNFO] [sTDERR] 	at net.minecraft.world.chunk.storage.AnvilChunkLoader.saveChunk(AnvilChunkLoader.java:127)
2013-04-29 22:05:57 [iNFO] [sTDERR] 	at net.minecraft.world.gen.ChunkProviderServer.safeSaveChunk(ChunkProviderServer.java:232)
2013-04-29 22:05:57 [iNFO] [sTDERR] 	at net.minecraft.world.gen.ChunkProviderServer.saveChunks(ChunkProviderServer.java:284)
2013-04-29 22:05:57 [iNFO] [sTDERR] 	at net.minecraft.world.WorldServer.saveAllChunks(WorldServer.java:906)
2013-04-29 22:05:57 [iNFO] [sTDERR] 	at net.minecraft.server.MinecraftServer.saveAllWorlds(MinecraftServer.java:344)
2013-04-29 22:05:57 [iNFO] [sTDERR] 	at net.minecraft.server.MinecraftServer.stopServer(MinecraftServer.java:377)
2013-04-29 22:05:57 [iNFO] [sTDERR] 	at net.minecraft.server.integrated.IntegratedServer.stopServer(IntegratedServer.java:240)
2013-04-29 22:06:00 [iNFO] [sTDERR] 	at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:521)
2013-04-29 22:06:00 [iNFO] [sTDERR] 	at net.minecraft.server.ThreadMinecraftServer.run(ThreadMinecraftServer.java:16)
2013-04-29 22:06:03 [sEVERE] [ForgeModLoader] Fatal errors were detected during the transition from SERVER_STARTED to SERVER_STOPPED. Loading cannot continue
2013-04-29 22:06:06 [sEVERE] [ForgeModLoader] 
mcp{7.44} [Minecraft Coder Pack] (minecraft.jar) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available->Available
FML{5.1.29.662} [Forge Mod Loader] (coremods) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available->Available
Forge{7.7.1.662} [Minecraft Forge] (coremods) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available->Available
LPFUEL{1.0.1} [Lapis Fuel Mod] (bin) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available->Available
2013-04-29 22:06:06 [sEVERE] [ForgeModLoader] The ForgeModLoader state engine has become corrupted. Probably, a state was missed by and invalid modification to a base classForgeModLoader depends on. This is a critical error and not recoverable. Investigate any modifications to base classes outside ofForgeModLoader, especially Optifine, to see if there are fixes available.
2013-04-29 22:06:06 [iNFO] [sTDERR] Exception in thread "Server thread" java.lang.RuntimeException: The ForgeModLoader state engine is invalid
2013-04-29 22:06:06 [iNFO] [sTDERR] 	at cpw.mods.fml.common.LoadController.transition(LoadController.java:134)
2013-04-29 22:06:06 [iNFO] [sTDERR] 	at cpw.mods.fml.common.Loader.serverStopped(Loader.java:800)
2013-04-29 22:06:06 [iNFO] [sTDERR] 	at cpw.mods.fml.common.FMLCommonHandler.handleServerStopped(FMLCommonHandler.java:468)
2013-04-29 22:06:06 [iNFO] [sTDERR] 	at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:530)
2013-04-29 22:06:09 [iNFO] [sTDERR] 	at net.minecraft.server.ThreadMinecraftServer.run(ThreadMinecraftServer.java:16)
2013-04-29 22:06:10 [iNFO] [Minecraft-Client] Stopping!

 

Thank You For the Help :)

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

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.