So I'm working on a game that would use mouse or keyboard input to control the character. I have the keyboard input. In other games where I've used both I just have the actor turn towards the location of the mouse, but that won't work for this game. I have for seperate gif files, one walking left, right, away (moving up the screen) and forwards (moving down the screen). I tried to just use an if statement;
and have one of those for each direction, but that didn't seem to work, so I was hoping somebody could help me out.
if (mi.getX() >= getX())
{
move(5);
setImage(right.getCurrentImage());
}

