calclavia Posted April 30, 2012 Posted April 30, 2012 Hi, I'm rather inexperienced in Minecraft Forge, so please excuse this "noob" question. I created a new type of TNT in my mod and the problem is I'm not sure how to convert it to SMP. I read the FML guides and I made it work. The only problem is that the TNT primed entity won't render and is invisible. It also doesn't show any explosion animation or sound. Can anyone please help me with this? - Calclavia http://calclavia.com/uploads/banner.png[/img]
Methuselah96 Posted April 30, 2012 Posted April 30, 2012 Make sure you are using the absolute latest Forge (3.1.3.102). That is most likely the problem.
calclavia Posted April 30, 2012 Author Posted April 30, 2012 On 4/30/2012 at 10:34 AM, Methuselah96 said: Make sure you are using the absolute latest Forge (3.1.3.102). That is most likely the problem. I am using the latest Forge. This is the first time for me to create a SMP mod so I really need help on porting my mod to multiplayer. Most likely it is my mod's problem. I added the Minecraft Forge entity tracker and stuff said on most tutorials but I am still not clear on how to make my entities render in the client side. (I noticed the client side had this statement: if(!world.isRemote)) and I am not sure on how to make non-mob entities to render in the game... http://calclavia.com/uploads/banner.png[/img]
OvermindDL1 Posted April 30, 2012 Posted April 30, 2012 On 4/30/2012 at 11:17 AM, calclavia said: I am using the latest Forge. This is the first time for me to create a SMP mod so I really need help on porting my mod to multiplayer. Most likely it is my mod's problem. I added the Minecraft Forge entity tracker and stuff said on most tutorials but I am still not clear on how to make my entities render in the client side. (I noticed the client side had this statement: if(!world.isRemote)) and I am not sure on how to make non-mob entities to render in the game... They work fine in Single Player? The code for Single Player is identical for the Multi Player client in terms of rendering. You are sure that everything is registered properly? A reduced test case of code would help.
calclavia Posted May 1, 2012 Author Posted May 1, 2012 On 4/30/2012 at 8:07 PM, OvermindDL1 said: Quote I am using the latest Forge. This is the first time for me to create a SMP mod so I really need help on porting my mod to multiplayer. Most likely it is my mod's problem. I added the Minecraft Forge entity tracker and stuff said on most tutorials but I am still not clear on how to make my entities render in the client side. (I noticed the client side had this statement: if(!world.isRemote)) and I am not sure on how to make non-mob entities to render in the game... They work fine in Single Player? The code for Single Player is identical for the Multi Player client in terms of rendering. You are sure that everything is registered properly? A reduced test case of code would help. Yes they do work in single player perfectly. It works in multiplayer too also perfectly except for the entities not rendering and the animations and sound fxs not playing. I wrote this code on both the single player and the server. This block is basically a TNT to sum it up in a few words. MinecraftForge.registerEntity(net.minecraft.src.EntityAdvanceTNTPrimed.class, this, 252, 20, 2, true); Did I miss something? The TNT becomes invisible/disappears once it becomes primed. http://calclavia.com/uploads/banner.png[/img]
calclavia Posted May 1, 2012 Author Posted May 1, 2012 To clarify my problem, this is what I get when I play my mod on multiplayer: Before I power the TNT with redstone (before the TNT is primed): After I power the TNT with redstone (when the TNT is primed): The ONLY code I used from Minecraft Forge to register this entity is MinecraftForge.registerEntity(). I don't have any other code about registering this entity except for this line: MinecraftForge.registerEntity(net.minecraft.src.EntityAdvanceTNTPrimed.class, this, 252, 20, 2, true); The code for the TNT is basically the same as the vanilla code for the TNT, but modified to fit my needs. Is there something I did wrong? P.S You may test out the mod here: http://calclavia.com/ICBM/ http://calclavia.com/uploads/banner.png[/img]
OvermindDL1 Posted May 1, 2012 Posted May 1, 2012 I thought you needed the ModLoader entity registration.
calclavia Posted May 1, 2012 Author Posted May 1, 2012 On 5/1/2012 at 11:02 PM, OvermindDL1 said: I thought you needed the ModLoader entity registration. Tried that. Didn't work. Is it Forge's problem or mine? http://calclavia.com/uploads/banner.png[/img]
LexManos Posted May 2, 2012 Posted May 2, 2012 change your entity id to <128 I do Forge for free, however the servers to run it arn't free, so anything is appreciated. Consider supporting the team on Patreon
OvermindDL1 Posted May 2, 2012 Posted May 2, 2012 On 5/2/2012 at 6:47 PM, LexManos said: change your entity id to <128 Is this a hard requirement? If so I should remember that, it seems like it would not allow for much variety though. What causes the limit?
calclavia Posted May 2, 2012 Author Posted May 2, 2012 On 5/2/2012 at 6:47 PM, LexManos said: change your entity id to <128 Ha, I feel bad now. Took 4 days just to find out I made a simple mistake. But anyway, thanks! http://calclavia.com/uploads/banner.png[/img]
Recommended Posts