Tracking speed and moving angle.

Get help using Construct 2

Post » Mon Apr 29, 2013 2:44 pm

Sup, how you doing?

This is my first post and I wanna be as much objective as I can.
I've done a game where my player uses something like this setup of keybinds and behaviors to move:



The problem is that there are clients comunicating and the angle of motion of custommovement is always right, ->, (0?). I think it is that way because I am not using customM behavior to rotate the Player.

My question is, how to track my motion [moving angle and speed] without Player.CustomMovement?

I've been trying something on Vectors, but without much sucess.

Thanks you for you attention.
Cya
B
7
S
3
G
1
Posts: 154
Reputation: 1,812

Post » Mon Apr 29, 2013 3:29 pm

Well, I managed to understand that .dx and .dy are vectors, but the problem persists as there is no .dy being tracked.breackzin2013-04-29 15:30:35
B
7
S
3
G
1
Posts: 154
Reputation: 1,812

Post » Mon Apr 29, 2013 5:32 pm

Custom movement deals with movement. This means that if you use the sprite's normal angle movement actions, it doesn't affect the MOVEMENT angle, just the angle the object is facing. This is akin to a player being able to move and turn to shoot while moving in the same direction. The rotate actions on the custom movement behavior affect the MOVEMENT of the object, and NOT *direction* (where it's facing).

It would seem that simply using the "set angle of motion" action to set the sprite's movement angle to the sprite's visual angle (where it's facing) will produce what you need.JoyfulDreamer2013-04-29 17:41:56
Jack of all trades, and master of some.
B
29
S
9
G
7
Posts: 174
Reputation: 7,601

Post » Mon Apr 29, 2013 6:28 pm

Joyful, I was in the same assumption while posting this, but now I have reworked my server and It is not only working as intended, but also using angle and "direction" as the same thing.

Well, problem solved.
B
7
S
3
G
1
Posts: 154
Reputation: 1,812


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 16 guests