Problem with pointing a position with mouse and auto-moving the
by Thomas Jobert · in Torque Game Engine · 01/20/2003 (3:42 am) · 3 replies
Hello !
I'm using the example given with torque to develop my own game.
The players have a third person view, and I wanted them to move automaticaly to a pointed location (with the mouse cursor).
So I allowed the cursor to be visible, I integrated the mouse events on GameTSCtrl. When I point the map, I get 3D coordinates (which seems false, but that's another problem), I tell the player to move there ; PS : I integrated some functions of AIPlayer into GameTSCtrl to allow this.
THE PROBLEM (finally !)
Well, when i select a place, the player starts to move to this place, but just after, it comes back to its original position !
---------------------------------
I don't know why the player does not continue its move ; i really need some help !
----------
PS1 : It seems that the 3D coordinates that i get are the projection of the center of the screen of the 1rst person view :/. Maybe that's why the unproject function return the same things...
Thanks !
Thomas
I'm using the example given with torque to develop my own game.
The players have a third person view, and I wanted them to move automaticaly to a pointed location (with the mouse cursor).
So I allowed the cursor to be visible, I integrated the mouse events on GameTSCtrl. When I point the map, I get 3D coordinates (which seems false, but that's another problem), I tell the player to move there ; PS : I integrated some functions of AIPlayer into GameTSCtrl to allow this.
THE PROBLEM (finally !)
Well, when i select a place, the player starts to move to this place, but just after, it comes back to its original position !
---------------------------------
I don't know why the player does not continue its move ; i really need some help !
----------
PS1 : It seems that the 3D coordinates that i get are the projection of the center of the screen of the 1rst person view :/. Maybe that's why the unproject function return the same things...
Thanks !
Thomas
About the author
#2
Thanks !
01/21/2003 (12:49 am)
ok i'm gonna try this this evening. I really thank you, this problem is blocking me, if it works i'll be able to go forward.Thanks !
#3
I think the file version I have are not up-to-date (function missing, etc.). The matter is that for many reasons i can't get the CVS versions of the files.
Can someone send them (aiplayer.h + .cc + gameconnexion + whatever i need to have my character move :) ) to me, at thomas_jobert@yahoo.fr ?
I know i should try to do the missing function by myself but i really don"t have the time :/
Thanks !
01/24/2003 (2:46 am)
mmmm in this ressource, the guy says that the aiplayers class have been updated and there is almost nothing to add to move the player (just creating it as a bot).I think the file version I have are not up-to-date (function missing, etc.). The matter is that for many reasons i can't get the CVS versions of the files.
Can someone send them (aiplayer.h + .cc + gameconnexion + whatever i need to have my character move :) ) to me, at thomas_jobert@yahoo.fr ?
I know i should try to do the missing function by myself but i really don"t have the time :/
Thanks !
Torque Owner J. Donavan Stanley