diff options
-rw-r--r-- | res/resources/audio/USE_DISK.ogg | bin | 0 -> 54291 bytes | |||
-rw-r--r-- | src/esieequest/engine/commands/KillCommand.java | 5 | ||||
-rw-r--r-- | src/esieequest/game/characters/Athanase.java | 10 | ||||
-rw-r--r-- | src/esieequest/game/items/Banana.java | 1 | ||||
-rw-r--r-- | src/esieequest/game/items/PortableConsole.java | 8 | ||||
-rw-r--r-- | src/esieequest/game/states/Quest.java | 1 |
6 files changed, 20 insertions, 5 deletions
diff --git a/res/resources/audio/USE_DISK.ogg b/res/resources/audio/USE_DISK.ogg new file mode 100644 index 0000000..93ca1b5 --- /dev/null +++ b/res/resources/audio/USE_DISK.ogg | |||
Binary files differ | |||
diff --git a/src/esieequest/engine/commands/KillCommand.java b/src/esieequest/engine/commands/KillCommand.java index bcc0021..9f5dc49 100644 --- a/src/esieequest/engine/commands/KillCommand.java +++ b/src/esieequest/engine/commands/KillCommand.java | |||
@@ -4,6 +4,11 @@ import esieequest.game.Game; | |||
4 | import esieequest.game.Text; | 4 | import esieequest.game.Text; |
5 | import esieequest.ui.View; | 5 | import esieequest.ui.View; |
6 | 6 | ||
7 | /** | ||
8 | * Allows the user to commit suicide. | ||
9 | * | ||
10 | * @author Benoit LUBRANO DI SBARAGLIONE | ||
11 | */ | ||
7 | public class KillCommand implements Executable { | 12 | public class KillCommand implements Executable { |
8 | 13 | ||
9 | @Override | 14 | @Override |
diff --git a/src/esieequest/game/characters/Athanase.java b/src/esieequest/game/characters/Athanase.java index 51fa3c0..442273f 100644 --- a/src/esieequest/game/characters/Athanase.java +++ b/src/esieequest/game/characters/Athanase.java | |||
@@ -10,6 +10,7 @@ import esieequest.ui.View; | |||
10 | * Athanase the mathgorilla. | 10 | * Athanase the mathgorilla. |
11 | * | 11 | * |
12 | * @author Pacien TRAN-GIRARD | 12 | * @author Pacien TRAN-GIRARD |
13 | * @author Benoit LUBRANO DI SBARAGLIONE | ||
13 | */ | 14 | */ |
14 | public class Athanase extends SimpleCharacter { | 15 | public class Athanase extends SimpleCharacter { |
15 | 16 | ||
@@ -36,7 +37,7 @@ public class Athanase extends SimpleCharacter { | |||
36 | if (playersInventory.hasItem(Item.BANANA)) { | 37 | if (playersInventory.hasItem(Item.BANANA)) { |
37 | playersInventory.removeItem(Item.BANANA); | 38 | playersInventory.removeItem(Item.BANANA); |
38 | view.updateInventory(playersInventory); | 39 | view.updateInventory(playersInventory); |
39 | view.echo("Ooooh! You have a banana! *nomz* WAIT!... It tastes like... an EMERGENCY BANANA! That means... Hmmm..." | 40 | view.echo("Ooooh! You have a banana! *nomz* WAIT!... It tastes like... an EMERGENCY BANANA! That means... Hmmm..." |
40 | + "\n" | 41 | + "\n" |
41 | + "They turned it ON... Their stupid machine... It was not ready. It was a beta... Obviously it crashed... WITH THE ENTIRE UNIVERSE" | 42 | + "They turned it ON... Their stupid machine... It was not ready. It was a beta... Obviously it crashed... WITH THE ENTIRE UNIVERSE" |
42 | + "\n" + "I think we have to restart everything..."); | 43 | + "\n" + "I think we have to restart everything..."); |
@@ -71,12 +72,15 @@ public class Athanase extends SimpleCharacter { | |||
71 | if (playersInventory.hasItem(Item.PORTABLE_CONSOLE)) { | 72 | if (playersInventory.hasItem(Item.PORTABLE_CONSOLE)) { |
72 | view.echo("The Universe is far away... Well... Not exactly... Sort of... Complicated. Find an antenna on the outside or something that may act as an amplifier and connect the Portable Console to contact the Universe."); | 73 | view.echo("The Universe is far away... Well... Not exactly... Sort of... Complicated. Find an antenna on the outside or something that may act as an amplifier and connect the Portable Console to contact the Universe."); |
73 | } else { | 74 | } else { |
75 | view.echo("You should go outside, at the Console instead of talking to me."); | ||
76 | } | ||
77 | break; | ||
78 | case USE_DISK: | ||
79 | if (playersInventory.hasItem(Item.DISK)) { | ||
74 | view.echo("Well... You have installed the console, right? Have you turned it ON and inserted the disk? Because you should."); | 80 | view.echo("Well... You have installed the console, right? Have you turned it ON and inserted the disk? Because you should."); |
75 | } | 81 | } |
76 | break; | 82 | break; |
77 | |||
78 | } | 83 | } |
79 | 84 | ||
80 | } | 85 | } |
81 | |||
82 | } | 86 | } |
diff --git a/src/esieequest/game/items/Banana.java b/src/esieequest/game/items/Banana.java index 81f0b45..4350463 100644 --- a/src/esieequest/game/items/Banana.java +++ b/src/esieequest/game/items/Banana.java | |||
@@ -7,6 +7,7 @@ import esieequest.ui.View; | |||
7 | * A Banana that can be eaten only by Athanase. | 7 | * A Banana that can be eaten only by Athanase. |
8 | * | 8 | * |
9 | * @author Pacien TRAN-GIRARD | 9 | * @author Pacien TRAN-GIRARD |
10 | * @author Benoit LUBRANO DI SBARAGLIONE | ||
10 | */ | 11 | */ |
11 | public class Banana extends SimpleItem { | 12 | public class Banana extends SimpleItem { |
12 | 13 | ||
diff --git a/src/esieequest/game/items/PortableConsole.java b/src/esieequest/game/items/PortableConsole.java index 9c14219..cf63da1 100644 --- a/src/esieequest/game/items/PortableConsole.java +++ b/src/esieequest/game/items/PortableConsole.java | |||
@@ -3,12 +3,14 @@ package esieequest.game.items; | |||
3 | import esieequest.game.Game; | 3 | import esieequest.game.Game; |
4 | import esieequest.game.map.Direction; | 4 | import esieequest.game.map.Direction; |
5 | import esieequest.game.map.Room; | 5 | import esieequest.game.map.Room; |
6 | import esieequest.game.states.Quest; | ||
6 | import esieequest.ui.View; | 7 | import esieequest.ui.View; |
7 | 8 | ||
8 | /** | 9 | /** |
9 | * The transponder. | 10 | * The transponder. |
10 | * | 11 | * |
11 | * @author Pacien TRAN-GIRARD | 12 | * @author Pacien TRAN-GIRARD |
13 | * @author Benoit LUBRANO DI SBARAGLIONE | ||
12 | */ | 14 | */ |
13 | public class PortableConsole extends SimpleItem { | 15 | public class PortableConsole extends SimpleItem { |
14 | 16 | ||
@@ -23,11 +25,13 @@ public class PortableConsole extends SimpleItem { | |||
23 | public void use(final Game game, final View view) { | 25 | public void use(final Game game, final View view) { |
24 | final boolean onRoundabout = game.getPlayer().getCurrentRoom().equals( | 26 | final boolean onRoundabout = game.getPlayer().getCurrentRoom().equals( |
25 | Room.ENTRANCE_ROUNDABOUT); | 27 | Room.ENTRANCE_ROUNDABOUT); |
26 | final boolean pointingSouth = game.getPlayer().getCurrentDirection().equals(Direction.EAST); | 28 | final boolean pointingEast = game.getPlayer().getCurrentDirection().equals(Direction.EAST); |
27 | 29 | ||
28 | if (onRoundabout && pointingSouth) { | 30 | if (onRoundabout && pointingEast) { |
29 | game.getPlayer().getInventory().removeItem(Item.PORTABLE_CONSOLE); | 31 | game.getPlayer().getInventory().removeItem(Item.PORTABLE_CONSOLE); |
30 | game.getPlayer().getCurrentSide().getInventory().putItem(Item.PORTABLE_CONSOLE); | 32 | game.getPlayer().getCurrentSide().getInventory().putItem(Item.PORTABLE_CONSOLE); |
33 | game.getPlayer().setCurrentQuest(Quest.USE_DISK); | ||
34 | view.updateQuest(Quest.USE_DISK); | ||
31 | 35 | ||
32 | view.updateInventory(game.getPlayer().getInventory()); | 36 | view.updateInventory(game.getPlayer().getInventory()); |
33 | view.updateLocation(game.getPlayer().getCurrentRoom(), game.getPlayer() | 37 | view.updateLocation(game.getPlayer().getCurrentRoom(), game.getPlayer() |
diff --git a/src/esieequest/game/states/Quest.java b/src/esieequest/game/states/Quest.java index 2a7c591..a09ea09 100644 --- a/src/esieequest/game/states/Quest.java +++ b/src/esieequest/game/states/Quest.java | |||
@@ -18,6 +18,7 @@ public enum Quest { | |||
18 | FIND_DISK("Find the Disk at Club*Nix"), | 18 | FIND_DISK("Find the Disk at Club*Nix"), |
19 | FIND_CONSOLE("Find the Portable Remote Console at ESIEEspace"), | 19 | FIND_CONSOLE("Find the Portable Remote Console at ESIEEspace"), |
20 | INSTALL_CONSOLE("Find a place to install the Console"), | 20 | INSTALL_CONSOLE("Find a place to install the Console"), |
21 | USE_DISK("Insert the disk into the Console"), | ||
21 | 22 | ||
22 | ; | 23 | ; |
23 | 24 | ||