How do I Update Player Direction - See latest post

0 favourites
  • 7 posts
From the Asset Store
Rotate & Animation for 16 Direction & Mouse Direction
  • I have a character that has all the necessary animations etc for the diablo style movement and now I am attempting to make the player attack always in the direction he is facing.

    Diablo style movement:

    Would it be done the same way using the ceil8 ?

    Some help please as I am stumped!

  • Anyone ?

    Not so much as me but the character

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Anyone know a solution?

    Need the player to be able to attack the same way as the movement is setup

  • Can't you simply switch animations?

  • It is a bit different in this case,

    Player moves to direction of mouse(reticule) in an iso (8 direction) way

    I tried adding a variable direction starting with right, and then if he is facing down, left, up etc change the attack animation but couldn't figure out how to tell(construct2) if the player is actually facing each direction as it is not a platformer(platform behavior not used)

  • More info;

    Player within 22.5 angle 270 > set Player Direction = UP

    Player within 22.5 angle 0 > set Player Direction = RIGHT

    Player within 22.5 angle 90 > set Player Direction = DOWN

    ETC, ETC, ETC for each direction(8)

    When f pressed,

    Player Direction = UP Set Animation to attack1

    When f pressed,

    Player Direction = RIGHT Set Animation to attack2

    When f pressed,

    Player Direction = DOWN Set Animation to attack3

    ETC, ETC, ETC for each direction(8)

    But it will only respond to the first one and always attack UP (attack1)

  • Fixed this, but not the most efficient way.

    If player animation = idle0 (right)

    f pressed > set animation to attack0

    ETC ETC

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