Game Development Community

Replacing player object

by Kynan Eng · in Torque Game Engine · 08/04/2005 (1:31 pm) · 3 replies

Hi.

I am trying to implement a Hand object that would be animated with the input from a p5 glove. Logically, it should replace the player for each client and get input form the client side for each connected client, right? How exactly do I do this?

Also, as a beginning, I implemented it using the fxRenderObject class template, which derives from SceneObject. It is added to the screen and rendered nicely. But I am not sure about how to make it the controlled object and use the P5 input to drive the hand shape's nodes' rotations.

I also tried to write it as a class deriving from ShapeBase, and use the processTick to read the p5 glove state and alter the node rotations, and send update to the client. Is processTick executed at client side? It would be nicer to have the client read the input, make the update and make the server aware of final state, right? There is another problem with deriving from ShapeBase in that, it seems to be added to the scene, but it doesn't display at the startup, it is visible only after I run the mission editor, and grab the box which contains the invisible hand and move it a bit.

Could someone give me pointers on how to realize this: having the hand object controlled on the client side as the player, with p5 glove input?

Thanks.

#1
08/04/2005 (5:22 pm)
Have you tried hooking the P5 input code to the vehicle code, removing gravity from the physics calculations, and using the glove input to apply 3d forces to it?

I suggest searching the site for control objects, moves, and similar subjects... There's been a lot of discussion of how this aspect of the engine works. Be aware that most of the stuff here is on how to implement a networked solution, which may be a lot more than you want!
#2
08/05/2005 (12:03 am)
Thank you Ben, I'll try that..
Networked stuff is OK for me. It would be like a multiplayer game, only the player is the hand controlled with the cyberglove.
#3
12/04/2006 (7:11 pm)
Hi ,

How you doing?

I recently came across this post and it seems very similar to what am trying to achieve. I have intergrated the P5 with Torque but I am trying to increase the functionality by like you said 'allow the client to read the input of the glove'. I was also wondering if it was possible to drag and drop objects in Torque using the glove.

Any help would be appreciated...

Respectfully,
Irura