Posted January 23, 201411 yr Hey guys SuperHB here and I've been working on a mod and I've been using a OBJ model and I can't get to load. It just shows up as a regular block... here is my code in ClientProxy http://pastebin.com/ERtrngeu here is my code in the Block Class http://pastebin.com/ZzHYWbvY here is my code in my TESR Class(TileEntitySpecialRenderer) http://pastebin.com/PigB8wTz and here is my TileEntity Class, Small... but still, from what I know, needed. http://pastebin.com/NRfiU0h9 All of these classes have no errors and I can load up Minecraft fine so I don't know whats wrong Please help! Thanks, SuperHB MobDrops http://www.planetminecraft.com/mod/125-mobdrops/
January 23, 201411 yr Author Help Please? Really need help. MobDrops http://www.planetminecraft.com/mod/125-mobdrops/
January 23, 201411 yr you need to specify in the block file which render to use /** * Is this block (a) opaque and (b) a full 1m cube? This determines whether or not to render the shared face of two * adjacent blocks and also whether the player can attach torches, redstone wire, etc to this block. */ public boolean isOpaqueCube() { return false; } /** * If this block doesn't render as an ordinary block it will return False (examples: signs, buttons, stairs, etc) */ public boolean renderAsNormalBlock() { return false; } /** * The type of render function that is called for this block */ @Override public int getRenderType() { return YourMod.yourRenderType; } }
January 24, 201411 yr Author you need to specify in the block file which render to use /** * Is this block (a) opaque and (b) a full 1m cube? This determines whether or not to render the shared face of two * adjacent blocks and also whether the player can attach torches, redstone wire, etc to this block. */ public boolean isOpaqueCube() { return false; } /** * If this block doesn't render as an ordinary block it will return False (examples: signs, buttons, stairs, etc) */ public boolean renderAsNormalBlock() { return false; } /** * The type of render function that is called for this block */ @Override public int getRenderType() { return YourMod.yourRenderType; } } what do i put for the @Override public int getRenderType() { return YourMod.yourRenderType; } } Like can you give an example? EDIT: I added the code that you said it still didn't work unless i did the getRenderType code wrong. here is the code: http://pastebin.com/zrDYgTPz MobDrops http://www.planetminecraft.com/mod/125-mobdrops/
January 24, 201411 yr Hi I think the problem is that your TileEntity is never being created. In order for your TileEntity to be created, it needs to be created by your Block. I forget exactly how it looks, but based on BlockSign you need public class BlockMyBlock extends Block implements ITileEntityProvider or alternatively public class BlockMyBlock extends BlockContainer and you need to override createNewTileEntity Do you want your TileEntity to do the rendering, or your Block, or both? -TGG
January 24, 201411 yr Author Hi I think the problem is that your TileEntity is never being created. In order for your TileEntity to be created, it needs to be created by your Block. I forget exactly how it looks, but based on BlockSign you need public class BlockMyBlock extends Block implements ITileEntityProvider or alternatively public class BlockMyBlock extends BlockContainer and you need to override createNewTileEntity Do you want your TileEntity to do the rendering, or your Block, or both? -TGG It depends on which one helps with FPS and helps it load quicker. but I think you method worked. but not 100% sure because my game just crashed because it is a really big model EDIT: When I Export the Model as OBJ I use Cinema 4D what measurement should I use? MobDrops http://www.planetminecraft.com/mod/125-mobdrops/
January 24, 201411 yr Hi EDIT: When I Export the Model as OBJ I use Cinema 4D what measurement should I use? sorry dude I am way out of my depth with that one. I'd suggest making a really simple model (say - a cube) and exporting it in a range of different sizes to see what's about right. What crash message do you get? Might be nothing to do with your model at all -TGG
January 24, 201411 yr Hi I think the problem is that your TileEntity is never being created. In order for your TileEntity to be created, it needs to be created by your Block. I forget exactly how it looks, but based on BlockSign you need public class BlockMyBlock extends Block implements ITileEntityProvider or alternatively public class BlockMyBlock extends BlockContainer and you need to override createNewTileEntity Do you want your TileEntity to do the rendering, or your Block, or both? -TGG It depends on which one helps with FPS and helps it load quicker. but I think you method worked. but not 100% sure because my game just crashed because it is a really big model EDIT: When I Export the Model as OBJ I use Cinema 4D what measurement should I use? For me (c4d 14) 1m = 1block. Here could be your advertisement!
January 24, 201411 yr Author Hi EDIT: When I Export the Model as OBJ I use Cinema 4D what measurement should I use? sorry dude I am way out of my depth with that one. I'd suggest making a really simple model (say - a cube) and exporting it in a range of different sizes to see what's about right. What crash message do you get? Might be nothing to do with your model at all -TGG I don't get an error log. My minecraft just runs out of memory. EDIT: I tried a Simple model. Still lags out my game... not sure why it was a regular minecraft block size MobDrops http://www.planetminecraft.com/mod/125-mobdrops/
January 24, 201411 yr Author Hi I think the problem is that your TileEntity is never being created. In order for your TileEntity to be created, it needs to be created by your Block. I forget exactly how it looks, but based on BlockSign you need public class BlockMyBlock extends Block implements ITileEntityProvider or alternatively public class BlockMyBlock extends BlockContainer and you need to override createNewTileEntity Do you want your TileEntity to do the rendering, or your Block, or both? -TGG It depends on which one helps with FPS and helps it load quicker. but I think you method worked. but not 100% sure because my game just crashed because it is a really big model EDIT: When I Export the Model as OBJ I use Cinema 4D what measurement should I use? For me (c4d 14) 1m = 1block. So my model is 2,2,3.5 (l,w,h) MobDrops http://www.planetminecraft.com/mod/125-mobdrops/
January 24, 201411 yr Author Hi I think the problem is that your TileEntity is never being created. In order for your TileEntity to be created, it needs to be created by your Block. I forget exactly how it looks, but based on BlockSign you need public class BlockMyBlock extends Block implements ITileEntityProvider or alternatively public class BlockMyBlock extends BlockContainer and you need to override createNewTileEntity Do you want your TileEntity to do the rendering, or your Block, or both? -TGG It depends on which one helps with FPS and helps it load quicker. but I think you method worked. but not 100% sure because my game just crashed because it is a really big model EDIT: When I Export the Model as OBJ I use Cinema 4D what measurement should I use? For me (c4d 14) 1m = 1block. So my model is 2,2,3.5 (l,w,h) what should I do? MobDrops http://www.planetminecraft.com/mod/125-mobdrops/
January 24, 201411 yr Hi This is just a guess - perhaps your minecraft is running out of memory / becoming laggy for a different reason i.e. one of your statements is being run very often, is slow, or has a memory leak. For example, I notice your TESR does a few things in its constructor whereas the vanilla TESR don't public TESR(){ EleventhTardis = AdvancedModelLoader.loadModel("/assets/dwadventures/OBJ/Tardis/Model11thDoctorTardis.obj"); tardisTexture = new ResourceLocation("mobdrops:textures/tardisTexture.png"); } I don't expect that the TESR constructor would be called frequently, but if it is that might explain the symptoms. I'd suggest you comment out parts of the code one by one and see if you can find the part which is making it laggy. For example, if your code is still laggy after doing this - // EleventhTardis.renderAll(); then your model rendering is not the problem. Apart from that I'm out of ideas, sorry! -TGG
January 25, 201411 yr Author Hi This is just a guess - perhaps your minecraft is running out of memory / becoming laggy for a different reason i.e. one of your statements is being run very often, is slow, or has a memory leak. For example, I notice your TESR does a few things in its constructor whereas the vanilla TESR don't public TESR(){ EleventhTardis = AdvancedModelLoader.loadModel("/assets/dwadventures/OBJ/Tardis/Model11thDoctorTardis.obj"); tardisTexture = new ResourceLocation("mobdrops:textures/tardisTexture.png"); } I don't expect that the TESR constructor would be called frequently, but if it is that might explain the symptoms. I'd suggest you comment out parts of the code one by one and see if you can find the part which is making it laggy. For example, if your code is still laggy after doing this - // EleventhTardis.renderAll(); then your model rendering is not the problem. Apart from that I'm out of ideas, sorry! -TGG Okay, I'll try it I tell you what happens MobDrops http://www.planetminecraft.com/mod/125-mobdrops/
January 25, 201411 yr Author Since I don't have a clue what's going on here is the Console Log Jan 24, 2014 8:49:11 PM net.minecraft.launchwrapper.LogWrapper log INFO: Loading tweak class name cpw.mods.fml.common.launcher.FMLTweaker Jan 24, 2014 8:49:11 PM net.minecraft.launchwrapper.LogWrapper log INFO: Using primary tweak class name cpw.mods.fml.common.launcher.FMLTweaker Jan 24, 2014 8:49:11 PM net.minecraft.launchwrapper.LogWrapper log INFO: Calling tweak class cpw.mods.fml.common.launcher.FMLTweaker 2014-01-24 20:49:11 [iNFO] [ForgeModLoader] Forge Mod Loader version 6.4.49.965 for Minecraft 1.6.4 loading 2014-01-24 20:49:11 [iNFO] [ForgeModLoader] Java is Java HotSpot(TM) 64-Bit Server VM, version 1.7.0_25, running on Windows 8:amd64:6.2, installed at C:\Program Files\Java\jre7 2014-01-24 20:49:11 [iNFO] [ForgeModLoader] Managed to load a deobfuscated Minecraft name- we are in a deobfuscated environment. Skipping runtime deobfuscation 2014-01-24 20:49:11 [iNFO] [ForgeModLoader] Loading tweak class name cpw.mods.fml.common.launcher.FMLInjectionAndSortingTweaker 2014-01-24 20:49:11 [iNFO] [ForgeModLoader] Loading tweak class name cpw.mods.fml.common.launcher.FMLDeobfTweaker 2014-01-24 20:49:11 [iNFO] [ForgeModLoader] Calling tweak class cpw.mods.fml.common.launcher.FMLInjectionAndSortingTweaker 2014-01-24 20:49:11 [iNFO] [ForgeModLoader] Calling tweak class cpw.mods.fml.common.launcher.FMLInjectionAndSortingTweaker 2014-01-24 20:49:11 [iNFO] [ForgeModLoader] Calling tweak class cpw.mods.fml.relauncher.CoreModManager$FMLPluginWrapper 2014-01-24 20:49:11 [iNFO] [sTDOUT] Loaded 40 rules from AccessTransformer config file fml_at.cfg 2014-01-24 20:49:11 [sEVERE] [ForgeModLoader] The binary patch set is missing. Either you are in a development environment, or things are not going to work! 2014-01-24 20:49:12 [iNFO] [ForgeModLoader] Calling tweak class cpw.mods.fml.relauncher.CoreModManager$FMLPluginWrapper 2014-01-24 20:49:12 [iNFO] [sTDOUT] Loaded 110 rules from AccessTransformer config file forge_at.cfg 2014-01-24 20:49:12 [iNFO] [ForgeModLoader] Calling tweak class cpw.mods.fml.common.launcher.FMLDeobfTweaker 2014-01-24 20:49:12 [iNFO] [ForgeModLoader] Launching wrapped minecraft {net.minecraft.client.main.Main} 2014-01-24 20:49:13 [iNFO] [Minecraft-Client] Setting user: Player718 2014-01-24 20:49:14 [iNFO] [Minecraft-Client] LWJGL Version: 2.9.0 2014-01-24 20:49:14 [iNFO] [Minecraft-Client] Reloading ResourceManager: Default 2014-01-24 20:49:14 [iNFO] [MinecraftForge] Attempting early MinecraftForge initialization 2014-01-24 20:49:14 [iNFO] [sTDOUT] MinecraftForge v9.11.1.965 Initialized 2014-01-24 20:49:14 [iNFO] [ForgeModLoader] MinecraftForge v9.11.1.965 Initialized 2014-01-24 20:49:15 [iNFO] [sTDOUT] Replaced 111 ore recipies 2014-01-24 20:49:15 [iNFO] [MinecraftForge] Completed early MinecraftForge initialization 2014-01-24 20:49:15 [iNFO] [ForgeModLoader] Reading custom logging properties from C:\Users\Kenneth\Desktop\Stuff\Modding Stuff\Doctor Who 1.6.4\forge\mcp\jars\config\logging.properties 2014-01-24 20:49:15 [OFF] [ForgeModLoader] Logging level for ForgeModLoader logging is set to ALL 2014-01-24 20:49:15 [iNFO] [ForgeModLoader] Searching C:\Users\Kenneth\Desktop\Stuff\Modding Stuff\Doctor Who 1.6.4\forge\mcp\jars\mods for mods 2014-01-24 20:49:16 [iNFO] [ForgeModLoader] Forge Mod Loader has identified 4 mods to load 2014-01-24 20:49:16 [iNFO] [mcp] Activating mod mcp 2014-01-24 20:49:16 [iNFO] [FML] Activating mod FML 2014-01-24 20:49:16 [iNFO] [Forge] Activating mod Forge 2014-01-24 20:49:16 [iNFO] [doctorwhoadventures] Activating mod doctorwhoadventures 2014-01-24 20:49:16 [WARNING] [Forge Mod Loader] Mod Forge Mod Loader is missing a pack.mcmeta file, things may not work well 2014-01-24 20:49:16 [WARNING] [Minecraft Forge] Mod Minecraft Forge is missing a pack.mcmeta file, things may not work well 2014-01-24 20:49:16 [WARNING] [Doctor Who Adventures] Mod Doctor Who Adventures is missing a pack.mcmeta file, things may not work well 2014-01-24 20:49:16 [iNFO] [Minecraft-Client] Reloading ResourceManager: Default, FMLFileResourcePack:Forge Mod Loader, FMLFileResourcePack:Minecraft Forge, FMLFileResourcePack:Doctor Who Adventures 2014-01-24 20:49:17 [iNFO] [ForgeModLoader] Registering Forge Packet Handler 2014-01-24 20:49:17 [iNFO] [ForgeModLoader] Succeeded registering Forge Packet Handler 2014-01-24 20:49:17 [iNFO] [ForgeModLoader] Configured a dormant chunk cache size of 0 2014-01-24 20:49:18 [sEVERE] [Minecraft-Client] Using missing texture, unable to load: dwadventures:textures/blocks/EleventhTARDIS.png 2014-01-24 20:49:18 [iNFO] [ForgeModLoader] Forge Mod Loader has successfully loaded 4 mods 2014-01-24 20:49:18 [WARNING] [Forge Mod Loader] Mod Forge Mod Loader is missing a pack.mcmeta file, things may not work well 2014-01-24 20:49:18 [WARNING] [Minecraft Forge] Mod Minecraft Forge is missing a pack.mcmeta file, things may not work well 2014-01-24 20:49:18 [WARNING] [Doctor Who Adventures] Mod Doctor Who Adventures is missing a pack.mcmeta file, things may not work well 2014-01-24 20:49:18 [iNFO] [Minecraft-Client] Reloading ResourceManager: Default, FMLFileResourcePack:Forge Mod Loader, FMLFileResourcePack:Minecraft Forge, FMLFileResourcePack:Doctor Who Adventures 2014-01-24 20:49:19 [sEVERE] [Minecraft-Client] Using missing texture, unable to load: dwadventures:textures/blocks/EleventhTARDIS.png 2014-01-24 20:49:19 [iNFO] [sTDOUT] 2014-01-24 20:49:19 [iNFO] [sTDOUT] Starting up SoundSystem... 2014-01-24 20:49:19 [sEVERE] [Minecraft-Client] Realms: Server not available! 2014-01-24 20:49:19 [iNFO] [sTDOUT] Initializing LWJGL OpenAL 2014-01-24 20:49:19 [iNFO] [sTDOUT] (The LWJGL binding of OpenAL. For more information, see http://www.lwjgl.org) 2014-01-24 20:49:19 [iNFO] [sTDOUT] OpenAL initialized. 2014-01-24 20:49:19 [iNFO] [sTDOUT] 2014-01-24 20:49:21 [iNFO] [Minecraft-Server] Starting integrated minecraft server version 1.6.4 2014-01-24 20:49:21 [iNFO] [Minecraft-Server] Generating keypair 2014-01-24 20:49:21 [sEVERE] [fml.ItemTracker] FML has detected item discrepancies 2014-01-24 20:49:21 [sEVERE] [fml.ItemTracker] Missing items : {6256=Item 6256, Type net.DoctorWhoAdventures.superhb.mod.sonic.ItemSonic, owned by doctorwhoadventures, ordinal 0, name null, claimedModId null} 2014-01-24 20:49:21 [sEVERE] [fml.ItemTracker] Mismatched items : {} 2014-01-24 20:49:26 [iNFO] [ForgeModLoader] Loading dimension 0 (DWTardis Test) (net.minecraft.server.integrated.IntegratedServer@399232dc) 2014-01-24 20:49:26 [iNFO] [ForgeModLoader] Loading dimension 1 (DWTardis Test) (net.minecraft.server.integrated.IntegratedServer@399232dc) 2014-01-24 20:49:26 [iNFO] [ForgeModLoader] Loading dimension -1 (DWTardis Test) (net.minecraft.server.integrated.IntegratedServer@399232dc) 2014-01-24 20:49:26 [iNFO] [Minecraft-Server] Preparing start region for level 0 2014-01-24 20:49:27 [iNFO] [Minecraft-Server] Preparing spawn area: 51% 2014-01-24 20:49:28 [iNFO] [Minecraft-Server] Preparing spawn area: 96% 2014-01-24 20:49:57 [iNFO] [sTDERR] java.lang.OutOfMemoryError: Java heap space 2014-01-24 20:49:58 [iNFO] [sTDERR] at net.minecraft.util.AABBPool.getAABB(AABBPool.java:50) 2014-01-24 20:50:00 [iNFO] [sTDERR] at net.minecraft.block.Block.getCollisionBoundingBoxFromPool(Block.java:602) 2014-01-24 20:50:00 [iNFO] [sTDERR] at net.minecraft.block.Block.addCollisionBoxesToList(Block.java:568) 2014-01-24 20:50:01 [iNFO] [sTDERR] at net.minecraft.world.World.getCollidingBoundingBoxes(World.java:1684) 2014-01-24 20:50:02 [iNFO] [sTDERR] at net.minecraft.entity.player.EntityPlayerMP.<init>(EntityPlayerMP.java:187) 2014-01-24 20:50:04 [iNFO] [sTDERR] at net.minecraft.server.management.ServerConfigurationManager.createPlayerForUser(ServerConfigurationManager.java:389) 2014-01-24 20:50:05 [iNFO] [sTDERR] at net.minecraft.server.integrated.IntegratedServerListenThread.networkTick(IntegratedServerListenThread.java:91) 2014-01-24 20:50:08 [iNFO] [sTDERR] at net.minecraft.server.MinecraftServer.updateTimeLightAndEntities(MinecraftServer.java:691) 2014-01-24 20:50:09 [iNFO] [sTDERR] at net.minecraft.server.MinecraftServer.tick(MinecraftServer.java:587) 2014-01-24 20:50:10 [iNFO] [sTDERR] at net.minecraft.server.integrated.IntegratedServer.tick(IntegratedServer.java:129) 2014-01-24 20:50:11 [iNFO] [sTDERR] at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:484) 2014-01-24 20:50:12 [iNFO] [sTDERR] at net.minecraft.server.ThreadMinecraftServer.run(ThreadMinecraftServer.java:16) MobDrops http://www.planetminecraft.com/mod/125-mobdrops/
January 25, 201411 yr Ah. That error has nothing to do with the TESR at all. I have seen this problem before. When the player first spawns into the world, it looks for a place that is not occupied by any blocks. Each time it looks in a particular position, it creates an AABB, which takes a little bit of memory. If the position is full, it tries the next position, one higher, creates another AABB, and tries again. Eventually it reaches air, which should always be empty, and stop. In your case, you have incorrectly registered your block so that it has been assigned the ID zero, which is air. So every time the code tries to put the player into air, it thinks it is full because your block has overwritten the air Block. Eventually it creates so many AABB that the memory runs out. Long explanation, simple fix: give your Block a non-zero ID when you create it. If you're not sure what I mean, post the rest of the code where you are creating the instance of your Block. i.e. the public static BlockEleventhTardis blockEleventhTardis = new BlockEleventhTardis(id, material); -TGG
January 25, 201411 yr Author Ah. That error has nothing to do with the TESR at all. I have seen this problem before. When the player first spawns into the world, it looks for a place that is not occupied by any blocks. Each time it looks in a particular position, it creates an AABB, which takes a little bit of memory. If the position is full, it tries the next position, one higher, creates another AABB, and tries again. Eventually it reaches air, which should always be empty, and stop. In your case, you have incorrectly registered your block so that it has been assigned the ID zero, which is air. So every time the code tries to put the player into air, it thinks it is full because your block has overwritten the air Block. Eventually it creates so many AABB that the memory runs out. Long explanation, simple fix: give your Block a non-zero ID when you create it. If you're not sure what I mean, post the rest of the code where you are creating the instance of your Block. i.e. the public static BlockEleventhTardis blockEleventhTardis = new BlockEleventhTardis(id, material); -TGG Got it fixed. but now it is just the regular block model.... MobDrops http://www.planetminecraft.com/mod/125-mobdrops/
January 25, 201411 yr Author Okay so here is my new class files for the obj model. I can't get the obj model to work and it gives me the regular block... ClientProxy Class: http://pastebin.com/Nf003Fac TileEntity Class: http://pastebin.com/mSA1YCNA New TESR(Renamed to TardisTESR): http://pastebin.com/9yzU0TRv New Block Class: http://pastebin.com/s5w5sTwr MobDrops http://www.planetminecraft.com/mod/125-mobdrops/
January 26, 201411 yr Hi where is your registerTESR called from? Are you sure it's being called? I'd suggest that the first thing to check is whether your TESR.renderTileEntityAt is ever being called. If you know how to use breakpoints, put one on this line and see if it ever gets there Minecraft.getMinecraft().renderEngine.getTexture(tardisTexture);// dont create them here, create them in Otherwise, add System.out.println("TardisTESR::renderTileEntityAt"); just before the getTexture, and see if the message gets printed to the console or not. That will help you narrow down whether the problem is with the rendering of your model, or with the setup of the TESR or TileEntity. -TGG
January 26, 201411 yr Author Hi where is your registerTESR called from? Are you sure it's being called? I'd suggest that the first thing to check is whether your TESR.renderTileEntityAt is ever being called. If you know how to use breakpoints, put one on this line and see if it ever gets there Minecraft.getMinecraft().renderEngine.getTexture(tardisTexture);// dont create them here, create them in Otherwise, add System.out.println("TardisTESR::renderTileEntityAt"); just before the getTexture, and see if the message gets printed to the console or not. That will help you narrow down whether the problem is with the rendering of your model, or with the setup of the TESR or TileEntity. -TGG Okay, I'll try it, and thanks for the help. Even if it isn't helping me 100% EDIT: Okay so when I placed the block this is what showed up in the Dev Console: 2014-01-25 21:13:53 [sEVERE] [ForgeModLoader] A TileEntity type net.DoctorWhoAdventures.superhb.mod.TARDIS.TileEntityTardis has throw an exception trying to write state. It will not persist. Report this to the mod author java.lang.RuntimeException: class net.DoctorWhoAdventures.superhb.mod.TARDIS.TileEntityTardis is missing a mapping! This is a bug! at net.minecraft.tileentity.TileEntity.writeToNBT(TileEntity.java:108) at net.minecraft.world.chunk.storage.AnvilChunkLoader.writeChunkToNBT(AnvilChunkLoader.java:317) at net.minecraft.world.chunk.storage.AnvilChunkLoader.saveChunk(AnvilChunkLoader.java:127) at net.minecraft.world.gen.ChunkProviderServer.safeSaveChunk(ChunkProviderServer.java:232) at net.minecraft.world.gen.ChunkProviderServer.saveChunks(ChunkProviderServer.java:284) at net.minecraft.world.WorldServer.saveAllChunks(WorldServer.java:899) at net.minecraft.server.MinecraftServer.saveAllWorlds(MinecraftServer.java:360) at net.minecraft.server.MinecraftServer.tick(MinecraftServer.java:593) at net.minecraft.server.integrated.IntegratedServer.tick(IntegratedServer.java:129) at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:484) at net.minecraft.server.ThreadMinecraftServer.run(ThreadMinecraftServer.java:16) EDIT: It doesn't Show the message System.out.println("TardisTESR::renderTileEntityAt"); MobDrops http://www.planetminecraft.com/mod/125-mobdrops/
January 26, 201411 yr Hi That error message is because you're missing the code from your TileEntity that saves and loads it from disk, i.e. readFromNBT and writeToNBT. See here http://www.minecraftforge.net/wiki/Basic_Tile_Entity Did you check if your registerTESR function is called (add a breakpoint or a println to it...)? -TGG
January 26, 201411 yr Author Hi That error message is because you're missing the code from your TileEntity that saves and loads it from disk, i.e. readFromNBT and writeToNBT. See here http://www.minecraftforge.net/wiki/Basic_Tile_Entity Did you check if your registerTESR function is called (add a breakpoint or a println to it...)? -TGG Okay so read the tutorial and the last part 1. don't know where to put it 2. I have the errors with the variable i,j,k And I read the tutorial it just made my block disappeared... EDIT: I don't have a registerTESR function. but if you mean the one in the TESR class which is renderTileEntityAt function then yes I put the code to print the text onto the console but it doesn't show up MobDrops http://www.planetminecraft.com/mod/125-mobdrops/
January 26, 201411 yr Hi You've got a suitable function here to register the TESR, but you never call it? public class ClientProxy extends ServerProxy { public void registerTESR(){ //ClientRegistry.bindTileEntitySpecialRenderer(Class <? extends TileEntity> tileEntityClass, TileEntitySpecialRenderer specialRenderer) <- this is the method you call to register your TESR ClientRegistry.bindTileEntitySpecialRenderer(TileEntityTardis.class, new TESR()); } } I'd suggest you just move it to your main class, something like this one @Mod(modid="speedytoolsmod", name="Build Faster Mod", version="1.0.0") @NetworkMod(clientSideRequired=true, serverSideRequired=true, channels={"speedytools"}, packetHandler = PacketHandler.class) public class SpeedyToolsMod { // .. etc .. @EventHandler public void postInit(FMLPostInitializationEvent event) { ClientRegistry.bindTileEntitySpecialRenderer(TileEntityTardis.class, new TESR()); // you are missing this bit } } also, do you have GameRegistry.registerTileEntity(tileEntityClass, id); somewhere? -TGG
January 26, 201411 yr Author Hi You've got a suitable function here to register the TESR, but you never call it? public class ClientProxy extends ServerProxy { public void registerTESR(){ //ClientRegistry.bindTileEntitySpecialRenderer(Class <? extends TileEntity> tileEntityClass, TileEntitySpecialRenderer specialRenderer) <- this is the method you call to register your TESR ClientRegistry.bindTileEntitySpecialRenderer(TileEntityTardis.class, new TESR()); } } I'd suggest you just move it to your main class, something like this one @Mod(modid="speedytoolsmod", name="Build Faster Mod", version="1.0.0") @NetworkMod(clientSideRequired=true, serverSideRequired=true, channels={"speedytools"}, packetHandler = PacketHandler.class) public class SpeedyToolsMod { // .. etc .. @EventHandler public void postInit(FMLPostInitializationEvent event) { ClientRegistry.bindTileEntitySpecialRenderer(TileEntityTardis.class, new TESR()); // you are missing this bit } } also, do you have GameRegistry.registerTileEntity(tileEntityClass, id); somewhere? -TGG Okay I'll try it and yes i do have GameRegistry.registerTileEntity(tileEntityClass, id); it is in my main class: GameRegistry.registerTileEntity(TileEntityTardis.class, "eleventhTardis"); EDIT: Okay I can tell it is working now because it crashed due to the model here is the error: net.minecraftforge.client.model.ModelFormatException: Error parsing entry ('v -1.5 0 1.5', line 5) in file '/assets/dwadventures/OBJ/Tardis/Model11thDoctorTardis.obj' - Incorrect format at net.minecraftforge.client.model.obj.WavefrontObject.parseVertex(WavefrontObject.java:314) at net.minecraftforge.client.model.obj.WavefrontObject.loadObjModel(WavefrontObject.java:91) at net.minecraftforge.client.model.obj.WavefrontObject.<init>(WavefrontObject.java:55) at net.minecraftforge.client.model.obj.ObjModelLoader.loadInstance(ObjModelLoader.java:28) at net.minecraftforge.client.model.AdvancedModelLoader.loadModel(AdvancedModelLoader.java:70) at net.DoctorWhoAdventures.superhb.mod.TESR.TardisTESR.<init>(TardisTESR.java:20) at net.DoctorWhoAdventures.superhb.mod.DoctorWhoAdventure.postInit(DoctorWhoAdventure.java:88) 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:545) 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:313) 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.sendEventToModContainer(LoadController.java:201) at cpw.mods.fml.common.LoadController.propogateStateMessage(LoadController.java:181) 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:313) 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:112) at cpw.mods.fml.common.Loader.initializeMods(Loader.java:704) at cpw.mods.fml.client.FMLClientHandler.finishMinecraftLoading(FMLClientHandler.java:249) at net.minecraft.client.Minecraft.startGame(Minecraft.java:509) at net.minecraft.client.Minecraft.run(Minecraft.java:808) at net.minecraft.client.main.Main.main(Main.java:93) 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 net.minecraft.launchwrapper.Launch.launch(Launch.java:131) at net.minecraft.launchwrapper.Launch.main(Launch.java:27) 2014-01-26 09:56:18 [iNFO] [sTDOUT] ---- Minecraft Crash Report ---- 2014-01-26 09:56:18 [iNFO] [sTDOUT] // Ooh. Shiny. 2014-01-26 09:56:18 [iNFO] [sTDOUT] 2014-01-26 09:56:18 [iNFO] [sTDOUT] Time: 1/26/14 9:56 AM 2014-01-26 09:56:18 [iNFO] [sTDOUT] Description: Initializing game 2014-01-26 09:56:18 [iNFO] [sTDOUT] 2014-01-26 09:56:18 [iNFO] [sTDOUT] net.minecraftforge.client.model.ModelFormatException: Error parsing entry ('v -1.5 0 1.5', line 5) in file '/assets/dwadventures/OBJ/Tardis/Model11thDoctorTardis.obj' - Incorrect format 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraftforge.client.model.obj.WavefrontObject.parseVertex(WavefrontObject.java:314) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraftforge.client.model.obj.WavefrontObject.loadObjModel(WavefrontObject.java:91) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraftforge.client.model.obj.WavefrontObject.<init>(WavefrontObject.java:55) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraftforge.client.model.obj.ObjModelLoader.loadInstance(ObjModelLoader.java:28) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraftforge.client.model.AdvancedModelLoader.loadModel(AdvancedModelLoader.java:70) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.DoctorWhoAdventures.superhb.mod.TESR.TardisTESR.<init>(TardisTESR.java:20) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.DoctorWhoAdventures.superhb.mod.DoctorWhoAdventure.postInit(DoctorWhoAdventure.java:88) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at java.lang.reflect.Method.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at cpw.mods.fml.common.FMLModContainer.handleModStateEvent(FMLModContainer.java:545) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at java.lang.reflect.Method.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.EventHandler.handleEvent(EventHandler.java:74) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.SynchronizedEventHandler.handleEvent(SynchronizedEventHandler.java:45) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.EventBus.dispatch(EventBus.java:313) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:296) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.EventBus.post(EventBus.java:267) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at cpw.mods.fml.common.LoadController.sendEventToModContainer(LoadController.java:201) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at cpw.mods.fml.common.LoadController.propogateStateMessage(LoadController.java:181) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at java.lang.reflect.Method.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.EventHandler.handleEvent(EventHandler.java:74) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.SynchronizedEventHandler.handleEvent(SynchronizedEventHandler.java:45) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.EventBus.dispatch(EventBus.java:313) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:296) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.EventBus.post(EventBus.java:267) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at cpw.mods.fml.common.LoadController.distributeStateMessage(LoadController.java:112) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at cpw.mods.fml.common.Loader.initializeMods(Loader.java:704) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at cpw.mods.fml.client.FMLClientHandler.finishMinecraftLoading(FMLClientHandler.java:249) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraft.client.Minecraft.startGame(Minecraft.java:509) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraft.client.Minecraft.run(Minecraft.java:808) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraft.client.main.Main.main(Main.java:93) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at java.lang.reflect.Method.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraft.launchwrapper.Launch.launch(Launch.java:131) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraft.launchwrapper.Launch.main(Launch.java:27) 2014-01-26 09:56:18 [iNFO] [sTDOUT] 2014-01-26 09:56:18 [iNFO] [sTDOUT] 2014-01-26 09:56:18 [iNFO] [sTDOUT] A detailed walkthrough of the error, its code path and all known details is as follows: 2014-01-26 09:56:18 [iNFO] [sTDOUT] --------------------------------------------------------------------------------------- 2014-01-26 09:56:18 [iNFO] [sTDOUT] 2014-01-26 09:56:18 [iNFO] [sTDOUT] -- Head -- 2014-01-26 09:56:18 [iNFO] [sTDOUT] Stacktrace: 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraftforge.client.model.obj.WavefrontObject.parseVertex(WavefrontObject.java:314) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraftforge.client.model.obj.WavefrontObject.loadObjModel(WavefrontObject.java:91) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraftforge.client.model.obj.WavefrontObject.<init>(WavefrontObject.java:55) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraftforge.client.model.obj.ObjModelLoader.loadInstance(ObjModelLoader.java:28) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraftforge.client.model.AdvancedModelLoader.loadModel(AdvancedModelLoader.java:70) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.DoctorWhoAdventures.superhb.mod.TESR.TardisTESR.<init>(TardisTESR.java:20) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.DoctorWhoAdventures.superhb.mod.DoctorWhoAdventure.postInit(DoctorWhoAdventure.java:88) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at java.lang.reflect.Method.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at cpw.mods.fml.common.FMLModContainer.handleModStateEvent(FMLModContainer.java:545) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at java.lang.reflect.Method.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.EventHandler.handleEvent(EventHandler.java:74) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.SynchronizedEventHandler.handleEvent(SynchronizedEventHandler.java:45) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.EventBus.dispatch(EventBus.java:313) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:296) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.EventBus.post(EventBus.java:267) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at cpw.mods.fml.common.LoadController.sendEventToModContainer(LoadController.java:201) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at cpw.mods.fml.common.LoadController.propogateStateMessage(LoadController.java:181) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at java.lang.reflect.Method.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.EventHandler.handleEvent(EventHandler.java:74) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.SynchronizedEventHandler.handleEvent(SynchronizedEventHandler.java:45) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.EventBus.dispatch(EventBus.java:313) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:296) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at com.google.common.eventbus.EventBus.post(EventBus.java:267) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at cpw.mods.fml.common.LoadController.distributeStateMessage(LoadController.java:112) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at cpw.mods.fml.common.Loader.initializeMods(Loader.java:704) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at cpw.mods.fml.client.FMLClientHandler.finishMinecraftLoading(FMLClientHandler.java:249) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraft.client.Minecraft.startGame(Minecraft.java:509) 2014-01-26 09:56:18 [iNFO] [sTDOUT] 2014-01-26 09:56:18 [iNFO] [sTDOUT] -- Initialization -- 2014-01-26 09:56:18 [iNFO] [sTDOUT] Details: 2014-01-26 09:56:18 [iNFO] [sTDOUT] Stacktrace: 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraft.client.Minecraft.run(Minecraft.java:808) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraft.client.main.Main.main(Main.java:93) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at java.lang.reflect.Method.invoke(Unknown Source) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraft.launchwrapper.Launch.launch(Launch.java:131) 2014-01-26 09:56:18 [iNFO] [sTDOUT] at net.minecraft.launchwrapper.Launch.main(Launch.java:27) I understand that it says that their is something wrong with the model but I tried a different, simple model and it still got an error. MobDrops http://www.planetminecraft.com/mod/125-mobdrops/
January 26, 201411 yr It is something wrong with the format. I've never tried doing an OBJ model before, (I wanted to but can't model anything better in blender than I can in techne so I use techne and skip the OBJ part. ) It appears to be the way you are directing it to your OBJ file, maybe try doing it another way like (YOURMODIDHERE + ":" + "Model11thDoctorTardis.obj") That is the only thing I can really think of. Sorry if it isn't what you need.
January 27, 201411 yr Author It is something wrong with the format. I've never tried doing an OBJ model before, (I wanted to but can't model anything better in blender than I can in techne so I use techne and skip the OBJ part. ) It appears to be the way you are directing it to your OBJ file, maybe try doing it another way like (YOURMODIDHERE + ":" + "Model11thDoctorTardis.obj") That is the only thing I can really think of. Sorry if it isn't what you need. That method won't work but thanks for trying to help anyways! MobDrops http://www.planetminecraft.com/mod/125-mobdrops/
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.