Browse Source

added cross Road location

master
Yazan Alaamer 2 years ago
parent
commit
927cfe9d57
  1. 25
      src/main/java/game/StartDarkSoulsGame.java

25
src/main/java/game/StartDarkSoulsGame.java

@ -191,6 +191,14 @@ public class StartDarkSoulsGame {
choice4.setText("");
}
public void crossRoad() {
position= "crossRoad";
mainTextArea.setText("You ar at the Undead Settlement.\n if you go south you will go back to the town");
choice1.setText("GO north");
choice2.setText("Go east");
choice3.setText("Go south");
choice4.setText("Go West");
}
public class TitelScreenHandler implements ActionListener{
public void actionPerformed(ActionEvent event) {
@ -206,7 +214,7 @@ public class StartDarkSoulsGame {
switch(yourChoice) {
case "c1": talkGuard(); break;
case "c2": attackGuard(); break;
case "c3": break;
case "c3": crossRoad(); break;
}
break;
case "talkGuard":
@ -214,12 +222,19 @@ public class StartDarkSoulsGame {
case"c1": townGate();break;
}
break;
case "attackGuard":// commit (26) attack guard
switch(yourChoice) {// commit (26) attack guard
case "c1": townGate();// commit (26) attack guard
break;// commit (26) attack guard
case "attackGuard":
switch(yourChoice) {
case "c1": townGate();
break;
}
break;
case "crossRoad":
switch(yourChoice) {
case "c1": break;
case "c2": break;
case "c3": townGate(); break;
case "c4": break;
}
}
}

Loading…
Cancel
Save