Gamestudio Links
Zorro Links
Newest Posts
Zorro 2.70
by jcl. 09/29/25 09:24
optimize global parameters SOLVED
by dBc. 09/27/25 17:07
ZorroGPT
by TipmyPip. 09/27/25 10:05
assetHistory one candle shift
by jcl. 09/21/25 11:36
Plugins update
by Grant. 09/17/25 16:28
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
0 registered members (), 18,767 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
krishna, DrissB, James168, Ed_Love, xtns
19168 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 3 of 3 1 2 3
Re: How i can make to a entity turn to face player [Re: LWD] #105503
01/06/07 03:53
01/06/07 03:53
Joined: Dec 2006
Posts: 78
Nevada, USA
Futurulus Offline
Junior Member
Futurulus  Offline
Junior Member

Joined: Dec 2006
Posts: 78
Nevada, USA
The angles might be straddling 0 and 360. Try adding
Code:
temp.pan = ang(temp.pan);  // EDIT: I put x instead of pan... shouldn't matter though :P
temp.tilt = ang(temp.tilt);


right after you scale temp. This changes it so the angles are -180 to 180, so he'll turn in the right direction.

Last edited by Futurulus; 01/06/07 03:58.
Re: How i can make to a entity turn to face player [Re: Futurulus] #105504
01/06/07 04:40
01/06/07 04:40
Joined: Jan 2006
Posts: 53
L
LWD Offline OP
Junior Member
LWD  Offline OP
Junior Member
L

Joined: Jan 2006
Posts: 53
Thanks a lot, this code works fine!
Just one more question, when i jump the entity's face go up with me, how i can make to the entity dont move the face for up or down?
Thanks to all for the help!

Last edited by LWD; 01/07/07 02:09.
Re: How i can make to a entity turn to face player [Re: LWD] #105505
01/08/07 20:26
01/08/07 20:26
Joined: Jan 2006
Posts: 53
L
LWD Offline OP
Junior Member
LWD  Offline OP
Junior Member
L

Joined: Jan 2006
Posts: 53
I already fix the problem, thanks a lot to all!!!

Last edited by LWD; 01/08/07 23:26.
Page 3 of 3 1 2 3

Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1