8 Direction angle and Mirror/Flip

0 favourites
  • 5 posts
From the Asset Store
Rotate & Animation for 16 Direction & Mouse Direction
  • Hi,

    I'm trying to have a player mirror the animation as the angle rotates in 180 degrees. I looked into the forum and I found guidance for the usage of bullets and platform, but I couldn't find one for 8 Direction angle behavior.

    It is possible to set something like

    Player is between angle 0 and 180 -> set player mirrored

    Else -> set player not mirrored

    I tried but the system is not allowing me to do it. I believe is because I'm using the following condition:

    Is in touch, distance (player.x,player.y,touch.x, touch.y) >100*dt

    -> move 100*dt pixels at angle angle(player.x,player.y,touch.x, touch.y)

    Set angle toward (touch.x, touch.Y)

    I think the solution is somewhere there... but I can't see it.

    Thanks!

  • can you do screenshots of your events, or maybe put your capx on dropbox and share it here, because it's a bit hard for me to understand your question

    what do you mean by "the system is not allowing me to do it"? does the player animation mirrored or not? have you check the player's angle after the action "set angle toward(touch.x, touch.y)"? because if the angle is between 180 and 360, it doesn't mirrored (based on what I see on your small code)

  • Daggio thank you!!!! Here's the capx

    Using 8 direction

    You can tell that the player looks upside down depending on where you are clicking. I would like the player to just mirror after certain angle... not sure if it is the right approach.

  • I can't open your CAPX as it's a different version than mine.

    But this event setup wont work?

    <img src="http://i526.photobucket.com/albums/cc346/adjustvolume/Angled_zps95baae2a.jpg" border="0" />

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • VictoryX thanks, it is closed, but I have not been able to figure it out... I have been using the r151 from C2.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)