Collision Meshes on a PlayerClass derived object?
by Marc-Andre Vachon · in Torque Game Engine · 03/05/2009 (5:44 am) · 2 replies
Hi!
For my current project I'm using a copy of the PlayerClass to control a kind of Hover Tank (Didn't want/need the HoverVehicleClass physic). Anyway, it's going very well but now I need to update the collision system a bit. I have found something to allow the Bounding Box to rotate with player, should work.
But, I think I should be able to use collision meshes instead. The "Player" only run on flat .dif and he will always stay vertical. So I guess using basic collision meshes shouldn't be hard. I have implemented the hitbox ressource and i'd like to use those box for the collison instead of bounding box.
Is it possible? If so, I'm not looking for a complete solution necessarly but at least some hint about where to look at in code or pointing me at a ressource I might have miss. Maybe I could just use the standard ShapeBase collision, but does it will work with the player movements?
Any suggestions , hint or help appreciated!
Thanks
For my current project I'm using a copy of the PlayerClass to control a kind of Hover Tank (Didn't want/need the HoverVehicleClass physic). Anyway, it's going very well but now I need to update the collision system a bit. I have found something to allow the Bounding Box to rotate with player, should work.
But, I think I should be able to use collision meshes instead. The "Player" only run on flat .dif and he will always stay vertical. So I guess using basic collision meshes shouldn't be hard. I have implemented the hitbox ressource and i'd like to use those box for the collison instead of bounding box.
Is it possible? If so, I'm not looking for a complete solution necessarly but at least some hint about where to look at in code or pointing me at a ressource I might have miss. Maybe I could just use the standard ShapeBase collision, but does it will work with the player movements?
Any suggestions , hint or help appreciated!
Thanks
About the author
Silent Torque developper since 2007 (T3D/TGEA) that is trying to start his little independant studio called Nordik Lab. --"Simple is Better"--
#2
I'm not a very good coder but I will do some experiments to see if I can get close of something that could work.
Stay tuned!
03/05/2009 (3:33 pm)
Thanks David, I had a look there but I think I would need to modify the buildConvex and buildPolyList function too. The updatePos function is lacking some commenting too, I'm not sure if I understand it well and how I could adjust it. I will look further into it.I'm not a very good coder but I will do some experiments to see if I can get close of something that could work.
Stay tuned!
Torque 3D Owner Daniel Buckmaster