# Making the character go diagonally?

**URL:** https://forum.kirupa.com/t/making-the-character-go-diagonally/332381
**Category:** Uncategorized
**Created:** [May 15, 2014, 7:47pm UTC](https://forum.kirupa.com/t/making-the-character-go-diagonally/332381 "2014-05-15T19:47:41Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Thomas\_Macedo](https://avatars.discourse-cdn.com/v4/letter/t/bc79bd/32.png) [@Thomas\_Macedo](https://forum.kirupa.com/u/Thomas_Macedo)
#### Post date: [May 15, 2014, 7:47pm UTC](https://forum.kirupa.com/t/making-the-character-go-diagonally/332381/1 "2014-05-15T19:47:41Z")

</div>

I am working on a game right now but I have a problem.

The game is an overview game and my character has a face so it’s important that he turns the right way when he walks…

But I have a problem. I am trying to make his face go diagonally (Down-Left, Down-Right, Up-Left and Up-Right)

```auto
    if (Key.isDown(Key.LEFT, Key.DOWN)) {
        _x -= power;
        _root.char.gotoAndStop(5);
    }

```

This is the code I could use to make him use the animation on the characters frame 5 to make him look Down-Left.  
But as a player presses left it only registering the left key making him look Down-Left when you got left. And it would be the same if the code was:

```auto
    if (Key.isDown(Key.DOWN, Key.LEFT)) {
        _x -= power;
        _root.char.gotoAndStop(5);
    }

```

I hope you understand and you can help me with my problem.
