very simple flip walk question

For questions about using Classic.

Post » Wed May 23, 2012 7:24 pm

hello all :)

i m new around construct and scripting and i can t seem t find the correct solution to my very simple problem.

i have a basic sprite with one frame, and i want it to flip based on where the mouse is, basically when he s moving right or left (he can move up and down but i don t need to change the sprite at all)

i know i can use "is mirrored" effect but i can t seem to find a condition for the mouse (it would be a lot easier by just using keyboard but i really want to use the mouse) to use it with. i really don t know anything about storing previous mouse position or even if i should use a variable.

for the mouse movement, i m using the accelerate effect toward mouse.X or mouse.Y

if anybody can help, i ll be really thankful, or direct me towards the right mouse tutorial...

thankies !!!

Posts: 3
Reputation: 331

Post » Wed May 23, 2012 8:23 pm

You can do it with two events using the compare x condition.

Player X < Mouse.X
----- Player set mirrored
Player X > Mouse.X
----- Player set not mirrored
Posts: 4,663
Reputation: 36,691

Post » Wed May 23, 2012 8:46 pm

perfect :)

thank you SO much :)
Posts: 3
Reputation: 331

Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 4 guests