Angle of Sprite when Decending or Assending

Get help using Construct 2

Post » Fri Feb 01, 2013 11:11 pm

I know how to make a sprite follow a path but how can I change the angle of the sprite when I accend or decend a hill for example?



Any suggestions?
B
17
S
2
G
4
Posts: 6
Reputation: 2,985

Post » Fri Feb 01, 2013 11:19 pm

are you using the physics behaviour?
B
14
S
6
G
2
Posts: 136
Reputation: 3,210

Post » Sat Feb 02, 2013 12:26 am

I guess you should make 2 instance variables for player, X and Y last positions, then if X and Y goes right diagonal like X+ Y- while on floor, the action should be like Cos(angle) and Sin(angle) it could it make smooth angle
B
96
S
25
G
20
Posts: 3,053
Reputation: 22,640

Post » Sun Feb 03, 2013 12:08 am

wretchedshark, I am using the platform behaviour.

joannesalfa,I haven't considered that. Do you know of any examples out there that can help me?

Thanks.
B
17
S
2
G
4
Posts: 6
Reputation: 2,985


Return to How do I....?

Who is online

Users browsing this forum: anty21ro, dieblume86, Kagubro, Yahoo [Bot] and 3 guests