Gamestudio Links
Zorro Links
Newest Posts
Change chart colours
by 7th_zorro. 05/11/24 09:25
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
4 registered members (AndrewAMD, Baklazhan, Ayumi, Hanky27), 1,387 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
Newest Members
Hanky27, firatv, wandaluciaia, Mega_Rod, EternallyCurious
19051 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 | chip programmers | 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