help for collisionhandlerfloor andCollisionHandlerGravity

Return to C++ coding using Panda3D

help for collisionhandlerfloor andCollisionHandlerGravity

Postby samusam » Thu Apr 05, 2012 9:40 am

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. http://www.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. http://www.panda3d.org/manual/index.php ... n_Handlers
Potrei avere un esempio di codice che continui su questa riga?
samusam
 
Posts: 57
Joined: Sat Aug 20, 2011 11:11 am

Postby drwr » Tue Apr 24, 2012 2:40 pm

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

David
drwr
 
Posts: 11286
Joined: Fri Feb 13, 2004 12:42 pm
Location: Glendale, CA

Postby samusam » Sun Apr 29, 2012 10:05 am

yes, i have seen. but i have problem for integrate the code of Ralf in my code.
samusam
 
Posts: 57
Joined: Sat Aug 20, 2011 11:11 am

Postby samusam » Sun Apr 29, 2012 11:47 am

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.
samusam
 
Posts: 57
Joined: Sat Aug 20, 2011 11:11 am

Another solution.

Postby EdmundosTown » Sun Apr 29, 2012 11:56 am

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:
EdmundosTown
 
Posts: 26
Joined: Mon Oct 17, 2011 1:36 pm
Location: Mexico City, Mexico

Postby samusam » Mon Apr 30, 2012 3:40 am

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 :D :D
samusam
 
Posts: 57
Joined: Sat Aug 20, 2011 11:11 am

Yep.

Postby EdmundosTown » Mon Apr 30, 2012 11:32 am

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.
EdmundosTown
 
Posts: 26
Joined: Mon Oct 17, 2011 1:36 pm
Location: Mexico City, Mexico

Postby samusam » Fri May 04, 2012 11:15 am

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à
samusam
 
Posts: 57
Joined: Sat Aug 20, 2011 11:11 am

Postby samusam » Mon May 07, 2012 3:39 am

i have solved.
I had to insert a line of code in the egg file
tnkss
samusam
 
Posts: 57
Joined: Sat Aug 20, 2011 11:11 am


Return to C++ coding using Panda3D

Who is online

Users browsing this forum: No registered users and 0 guests