help for collisionhandlerfloor andCollisionHandlerGravity

hi, I would like to know how you can make that your character will go on the ground. I read that those two classes would be nice, but I can not develop fully. I read this on CollisionHandlerFloor but I do not know how to continue to develop in order to set the coordinates of z pg. panda3d.org/manual/index.php … n_Handlers
Could I have a code example that continues to this line?

Ciao, vorrei sapere come è possibile far si che il pg vada sul terreno. Ho letto che andrebbero bene quelle due classi, ma non so svilupparle a fondo. Ho letto questo su CollisionHandlerFloor ma non so come continuare a sviluppare per settare le coordinate z del pg. panda3d.org/manual/index.php … n_Handlers
Potrei avere un esempio di codice che continui su questa riga?

Have you seen the Roaming Ralph C++ example posted elsewhere in this forum?

David

yes, i have seen. but i have problem for integrate the code of Ralf in my code.

now I’ve tested my code with the ground ralf and it seems to work. I wonder then that feature should I put in the ground so that the code ralf functions. I generated the ground with l3dt.
In practice I do not detect the collision with the ground.

ora io ho provato il mio codice con il terreno di ralf e mi sembra che funzioni. Mi chiedo allora che funzionalità devo inserire nel terreno affinché il codice di ralf funzioni. io ho generato il terreno con l3dt.
in pratica non mi rileva la collisione con il terreno.

Before sstarting with Bullet Physics (now being documented by me) I had your same problem, so here’s my personal solution http://consultoriaconverge.com/p3d/papino.zip (I have created with Netbeans under Ubuntu with Makefile).

I hope that it helps. :wink:

my code is functional but no with terrain that i create. I save terrain in format obj or dae after i export this files in egg format. with the terrain of ralf the collision is ok. i think that my error is in generate and export the terrain.

il mio codice è funzionale, ma non con il terreno che creo. Posso salvare terreno in formato obj o dae dopo i esportare questi file in formato uovo. con il terreno di Ralf la collisione è ok. Penso che il mio errore è nella generare ed esportare il terreno.

I thank you for the example given, I consider whether I have not my solutions

io ti ringrazio per l’esempio proposto, io lo esaminerò se non ho mie soluzioni :smiley: :smiley:

There are a lot of problems exporting to egg files, i.e. I had one trying to export a “resized” mesh with YABEE Blender extension, so I can’t resize my entire models with blender, but I can resize meshes and it works.

So It’s almost possible that your egg is corrupted or something like that because you code works with other meshes so, you can try to load this obj models into a Blender (or 3D Studio) and export it with YABEE.

Just a bridge solution but may works.

I export the obj file with chicken. now I need to know the version of the bullet is in the manual as an example. The most recent exhibit incompatibilities.

io esporto il file obj con chiken. ora ho bisogno di sapere la versione del proiettile che vi è nel manuale di esempio. La più recente mostra incompatibilità

i have solved.
I had to insert a line of code in the egg file
tnkss