I'm trying to create a TARDIS mod. The TARDIS entity spawns in the world, and you can interact with it in every way thus far programmed (which isn't a lot yet), but I'm running into two problems: first it's not visible. I can turn on bounding boxes and see that it's there, and it shows a shadow, but you can't see the texture. The other problems is that when I mount the TARDIS to fly it around, once I dismount the game crashes from a ticking entity. Any help that can be given would be much appreciated.
the crash is caused by you still assuming that the rider is not null after dismounting. adding a return statement after this line should fix that.
The second error is caused by you not binding the entity texture, thus the game engine rendering the entity with no texture applied. In your render class just override the doRender() method and call bindTexture() with your entity texture, then call the super method.
Thank you for your response. I missed the fact that I tried to access a null rider. That fixed one problem, however adding bindTexture to doRender didn't actually make the entity visible. I've updated the code on GitHib.
Thank you for your response. I missed the fact that I tried to access a null rider. That fixed one problem, however adding bindTexture to doRender didn't actually make the entity visible. I've updated the code on GitHib.
Alright. Thank you. Actually, the model editor was me, because I really don't know any good ones. I'll take a look to try to understand for next time. Again, thank you.
Hello all,
I'm trying to create a TARDIS mod. The TARDIS entity spawns in the world, and you can interact with it in every way thus far programmed (which isn't a lot yet), but I'm running into two problems: first it's not visible. I can turn on bounding boxes and see that it's there, and it shows a shadow, but you can't see the texture. The other problems is that when I mount the TARDIS to fly it around, once I dismount the game crashes from a ticking entity. Any help that can be given would be much appreciated.
Here is the code for the TARDIS entity: https://github.com/Padwolf/TARDIS-Mod/tree/master/src/main/java/com/codewolf/tardis/entities
And here is the registry info:
https://github.com/Padwolf/TARDIS-Mod/tree/master/src/main/java/com/codewolf/tardis/proxy
(EntityRegistry is in common and RendererRegistry is in client)
If there's any other information you need, please don't hesitate to ask
Thanks,
Padthewolf
the crash is caused by you still assuming that the rider is not null after dismounting. adding a return statement after this line should fix that.
The second error is caused by you not binding the entity texture, thus the game engine rendering the entity with no texture applied. In your render class just override the doRender() method and call bindTexture() with your entity texture, then call the super method.
Thank you for your response. I missed the fact that I tried to access a null rider. That fixed one problem, however adding bindTexture to doRender didn't actually make the entity visible. I've updated the code on GitHib.
yeah you've had the texture in the wrong location, and whatever model editor you used hadmessed up the texture mapping. I fixed all the issues and opened a pull request
Alright. Thank you. Actually, the model editor was me, because I really don't know any good ones. I'll take a look to try to understand for next time. Again, thank you.