Jump to content

Jamezo97

Members
  • Posts

    4
  • Joined

  • Last visited

Converted

  • Gender
    Undisclosed
  • Personal Text
    I am new!

Jamezo97's Achievements

Tree Puncher

Tree Puncher (2/8)

0

Reputation

  1. What kind of entity code? My EntityMyPerson.class file is 1600 lines long. It pretty much just extends the 'EntityLiving' class, has a few EntityAI tasks. But I really doubt that the issue is in my code. It worked perfectly fine with Risugami's modloader, and even when the mod was loaded with the forge Modloader instead of Risugami's, it worked fine. But now since I've used Forge's mod system, it's started doing this. And also, if it was my code, shouldn't it be happening on both the client side and the server? For it to only occur on the client, means that there is something funky going on with the spawning packets. Do I have to do anything for them? And the brightness. If I render a block using the RenderBlocks class, the brightness is fine, but doing it straight through the tessellator gives me this bug, so I assume I'm just missing some code which sets the brightness. At the moment I've just disabled brightness when rendering my block... Edit: On second thoughts, maybe it is my code. Just made a test entity, and when I spawned it, it was perfectly fine... Hmmm
  2. Hey guys, I've been moving my mod from Risugami's modloader to forge. It's all been going great, and I'm beginning to love forge. However I have a few bugs I can't seem to squish, I looked around, but couldn't find anything to fix them, I'm sure there are ways, so I'll ask here. For one of my blocks, I have a custom TileEntity renderer, and in that I render the whole block just using the Tessellator class. It looks fine, however if you look at the block at certain angles, it goes really dark. I've tried everything to do with brightness and colour, but I just can't seem to fix it. So does anyone know how to make sure the block stays a constant brightness. My code is here: I know my code is far from perfect. I probably should use a Model, however then I'd need to map out a texture file and stuff, and this works fine (kinda), so I'll just do it this way. Anyway, the second one: In my mod I have an entity called a 'clone' or a 'myperson'. However for some random reason, whenever you open up the world, or spawn the clone, they float away(well, walk, but it's not normal, they walk in a perfect straight line, and slowly slow down), and then once they move far enough away, they suddenly teleport back to their starting position (after about 4 seconds) I've registered my entity like so: RenderingRegistry.registerEntityRenderingHandler(net.minecraft.mypeople.EntityMyPerson.class, new RenderMyPerson()); EntityRegistry.registerGlobalEntityID(net.minecraft.mypeople.EntityMyPerson.class, "MyPerson", cloneID, 0x00afaf, 0x463aa5); EntityRegistry.registerModEntity(net.minecraft.mypeople.EntityMyPerson.class, "MyPerson", cloneID, this, 80, 3, false); Have I missed anything I have to do? I kinda just guessed on how to get this working... So yeah, any help is greatly appreciated. If I've left anything out, just ask and I'll tell. Oh, and the floating away, is only happening on the client. I checked the motionX and motionZ for both the client and server, and the values only changed on the client.. Thankyou!
  3. Ah, yes well I looked at the first option, and that looks, complicated The second option, I had thought of that, but that requires updating all the method names every time minecraft updates And the third otpion, I thought of that also, but when the mod is compiled, the class would just be wasted space because it's all put back into one package. So I think i'll just go with the second option, it's only going to take up an extra few bytes worth of class files, so I think it's the best way to go. Thankyou!
  4. tldr: How do I either turn off class sorting while forge is being installed, or how do I get around the inability to access protected methods and fields? -------------------------------------------------------------------------- Hey guys, I'm the author of the 'MyPeople Mod', and am currently trying to convert my mod over to Forge. I was originally using Risugami's Modloader, but many dislike Risguami's Modloader and Forge is used by many now, and I can do much more with Forge. So I installed forge fine, opened up eclipse, created a new package, and then imported my source code. I fixed as many errors that I could, where fields were just renamed and such, or package declarations were now different. So that went well too. However I then looked in the error list, and almost 75% of all the errors I now have to fix, are accessor errors. For example, in my mod the clone try's to make mob's attack it (like a mob would attack a player), so to do that, I check to see whether the entity is using the new AI system, with the method: "protected boolean isAIEnabled()" However, because my class is inside a different package than the 'net.minecraft.entity' package, I can't access that method because it is set to 'protected', and to access it I need to be in the same package. Most of my errors are all because of the protected keyword. With Risugami's Modloader, it doesn't sort the classes into packages, so I just place all my code into the main package of 'net.minecraft.src' and because it's in the same package as 'EntityLiving', it can run the method fine. So, my question is: How do I either turn off class sorting while forge is being installed, or how do I get around this? Thankyou! If you need any more information please just ask.
×
×
  • Create New...

Important Information

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