implemented support for else if constructs
This commit is contained in:
1 parent
f9e0d7f4b0
commit
8ba7936311
2 files changed
+29
-22
No files matched your search
@@ -28,14 +28,12 @@ public class Rover extends Actor
|
||||
if(richtung.equals("Hoch")) {
|
||||
pri = "links";
|
||||
sec = "rechts";
|
||||
} else {
|
||||
if (richtung.equals("Runter")) {
|
||||
pri = "rechts";
|
||||
sec = "links";
|
||||
} else {
|
||||
nachricht("JUNGE DU SPAST!");
|
||||
return;
|
||||
}
|
||||
} else if (richtung.equals("Runter")) {
|
||||
pri = "rechts";
|
||||
sec = "links";
|
||||
} else {
|
||||
nachricht("JUNGE DU SPAST!");
|
||||
return;
|
||||
}
|
||||
drehe(pri);
|
||||
fahre();
|
||||
|
||||
Reference in new issue
Block a user