Skip to content
Snippets Groups Projects
Commit 030fab66 authored by btomi96's avatar btomi96
Browse files

Merge branch 'graphcontroller' into 'master'

Bug fix with jaffa's move



See merge request !51
parents 2cd43ed0 5e9a8216
No related branches found
No related tags found
1 merge request!51Bug fix with jaffa's move
......@@ -107,7 +107,7 @@ public class GameController {
// Jaffa controls
case KeyEvent.VK_W: // Move or turn up
if(Model.getInstance().getColonel().getDirection() == Direction.UP)
if(Model.getInstance().getJaffa().getDirection() == Direction.UP)
{
move(Model.getInstance().getJaffa());
}
......@@ -117,7 +117,7 @@ public class GameController {
}
break;
case KeyEvent.VK_D: // Move or turn right
if(Model.getInstance().getColonel().getDirection() == Direction.RIGHT)
if(Model.getInstance().getJaffa().getDirection() == Direction.RIGHT)
{
move(Model.getInstance().getJaffa());
}
......@@ -127,7 +127,7 @@ public class GameController {
}
break;
case KeyEvent.VK_S: // Move or turn down
if(Model.getInstance().getColonel().getDirection() == Direction.DOWN)
if(Model.getInstance().getJaffa().getDirection() == Direction.DOWN)
{
move(Model.getInstance().getJaffa());
}
......@@ -137,7 +137,7 @@ public class GameController {
}
break;
case KeyEvent.VK_A: // Move or turn left
if(Model.getInstance().getColonel().getDirection() == Direction.LEFT)
if(Model.getInstance().getJaffa().getDirection() == Direction.LEFT)
{
move(Model.getInstance().getJaffa());
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment