Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
Doppeltgemoppelt
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
btomi96
Doppeltgemoppelt
Commits
5e9a8216
Commit
5e9a8216
authored
May 9, 2016
by
edani95
Browse files
Options
Downloads
Patches
Plain Diff
Bug fix with jaffa's move
parent
b36f39d7
Branches
Branches containing commit
No related tags found
1 merge request
!51
Bug fix with jaffa's move
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
core/app/GameController.java
+4
-4
4 additions, 4 deletions
core/app/GameController.java
with
4 additions
and
4 deletions
core/app/GameController.java
+
4
−
4
View file @
5e9a8216
...
@@ -107,7 +107,7 @@ public class GameController {
...
@@ -107,7 +107,7 @@ public class GameController {
// Jaffa controls
// Jaffa controls
case
KeyEvent
.
VK_W
:
// Move or turn up
case
KeyEvent
.
VK_W
:
// Move or turn up
if
(
Model
.
getInstance
().
get
Colonel
().
getDirection
()
==
Direction
.
UP
)
if
(
Model
.
getInstance
().
get
Jaffa
().
getDirection
()
==
Direction
.
UP
)
{
{
move
(
Model
.
getInstance
().
getJaffa
());
move
(
Model
.
getInstance
().
getJaffa
());
}
}
...
@@ -117,7 +117,7 @@ public class GameController {
...
@@ -117,7 +117,7 @@ public class GameController {
}
}
break
;
break
;
case
KeyEvent
.
VK_D
:
// Move or turn right
case
KeyEvent
.
VK_D
:
// Move or turn right
if
(
Model
.
getInstance
().
get
Colonel
().
getDirection
()
==
Direction
.
RIGHT
)
if
(
Model
.
getInstance
().
get
Jaffa
().
getDirection
()
==
Direction
.
RIGHT
)
{
{
move
(
Model
.
getInstance
().
getJaffa
());
move
(
Model
.
getInstance
().
getJaffa
());
}
}
...
@@ -127,7 +127,7 @@ public class GameController {
...
@@ -127,7 +127,7 @@ public class GameController {
}
}
break
;
break
;
case
KeyEvent
.
VK_S
:
// Move or turn down
case
KeyEvent
.
VK_S
:
// Move or turn down
if
(
Model
.
getInstance
().
get
Colonel
().
getDirection
()
==
Direction
.
DOWN
)
if
(
Model
.
getInstance
().
get
Jaffa
().
getDirection
()
==
Direction
.
DOWN
)
{
{
move
(
Model
.
getInstance
().
getJaffa
());
move
(
Model
.
getInstance
().
getJaffa
());
}
}
...
@@ -137,7 +137,7 @@ public class GameController {
...
@@ -137,7 +137,7 @@ public class GameController {
}
}
break
;
break
;
case
KeyEvent
.
VK_A
:
// Move or turn left
case
KeyEvent
.
VK_A
:
// Move or turn left
if
(
Model
.
getInstance
().
get
Colonel
().
getDirection
()
==
Direction
.
LEFT
)
if
(
Model
.
getInstance
().
get
Jaffa
().
getDirection
()
==
Direction
.
LEFT
)
{
{
move
(
Model
.
getInstance
().
getJaffa
());
move
(
Model
.
getInstance
().
getJaffa
());
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment