diff options
author | pacien | 2018-01-03 02:29:55 +0100 |
---|---|---|
committer | pacien | 2018-01-03 02:29:55 +0100 |
commit | 26223d88d6d184a3c862c2c9b75638fd66e93617 (patch) | |
tree | 36e25b9e72afa09b4874dc5257140a11ce71cb91 /src/docs | |
parent | 1a9785dca6f875ecf1c34befc1b5abf7829eb9e5 (diff) | |
download | wallj-26223d88d6d184a3c862c2c9b75638fd66e93617.tar.gz |
Write user manual
Signed-off-by: pacien <pacien.trangirard@pacien.net>
Diffstat (limited to 'src/docs')
-rw-r--r-- | src/docs/user.md | 122 |
1 files changed, 117 insertions, 5 deletions
diff --git a/src/docs/user.md b/src/docs/user.md index a680b01..77bbf35 100644 --- a/src/docs/user.md +++ b/src/docs/user.md | |||
@@ -1,14 +1,24 @@ | |||
1 | --- | 1 | --- |
2 | title: "Wall-J User manual" | 2 | title: "BSc IN S5 / OOP with Java / Wall-J / User manual" |
3 | author: [Pacien TRAN-GIRARD, Adam NAILI] | 3 | author: [Pacien TRAN-GIRARD, Adam NAILI] |
4 | date: 2017-12-09 | 4 | date: 2018-01-03 |
5 | ... | 5 | ... |
6 | 6 | ||
7 | # Introduction | 7 | # Preamble |
8 | |||
9 | "Wall-J: the Space Cleaner" is a game in which a player uses bombs to push garbage into trash cans in user definable | ||
10 | worlds. | ||
11 | |||
12 | Being part of the "OOP with Java" course at [UPEM](http://www.u-pem.fr/), this application has been entirely | ||
13 | written in Java and makes use of the Zen5 and [JBox2D](http://www.jbox2d.org/) libraries. | ||
8 | 14 | ||
9 | ## Licensing | 15 | ## Licensing |
10 | 16 | ||
11 | ## Credits | 17 | This work is licensed under the terms of the |
18 | [Creative Commons BY-NC-SA 4.0 license](https://creativecommons.org/licenses/by-nc-sa/4.0/) by its authors: | ||
19 | Pacien TRAN-GIRARD and Adam NAILI. | ||
20 | |||
21 | Build-time and embedded run-time dependencies of this program are licensed under their own respective terms. | ||
12 | 22 | ||
13 | --- | 23 | --- |
14 | 24 | ||
@@ -16,12 +26,114 @@ date: 2017-12-09 | |||
16 | 26 | ||
17 | ## Prerequisites | 27 | ## Prerequisites |
18 | 28 | ||
29 | This application requires the Java Runtime Environment version $\geq$ 8. | ||
30 | |||
31 | A graphical session is also needed to display the game window. | ||
32 | |||
19 | ## Running the program | 33 | ## Running the program |
20 | 34 | ||
21 | --- | 35 | The program can be started by running the following command: |
36 | |||
37 | java -jar wallj.jar | ||
38 | |||
39 | A custom world set contained within a directory can be loaded by supplying its path as command line argument as such: | ||
40 | |||
41 | java -jar wallj.jar /home/sforthright/bnl/axiom_floors/ | ||
42 | |||
43 | World definition files stored within the given directories and named as `level$i.txt`, where `$i` is a padded integer, | ||
44 | are loaded in alphanumerical order. | ||
45 | |||
46 | \newpage | ||
22 | 47 | ||
23 | # Game-play | 48 | # Game-play |
24 | 49 | ||
25 | ## Rules | 50 | ## Rules |
26 | 51 | ||
52 | The player controls a robot, dropping bombs whose explosion can push garbage into trash cans. | ||
53 | |||
54 | Garbage bounce when colliding other elements such as walls, unexploded bombs or other garbage blocks, | ||
55 | and disappear of the screen when reaching a garbage can. | ||
56 | |||
57 | A stage is considered done once the world has been cleared of all its garbage. | ||
58 | The player is then allowed to move on to the next stage. | ||
59 | The game is finished once all stages are completed. | ||
60 | |||
61 | ## World | ||
62 | |||
63 | The world is rectangular grid composed of the following type of tiles: | ||
64 | |||
65 | Entity type Appearance Pushable by bomb Traversable by robot | ||
66 | ----------- ------------ ---------------- -------------------- | ||
67 | Wall Black square No No | ||
68 | Trash can Red square No No | ||
69 | Free Empty No Yes | ||
70 | Bomb Black disk No Yes | ||
71 | Garbage Brown disk Yes Yes | ||
72 | Robot Blue disk / / | ||
73 | |||
74 | ## Controls | ||
75 | |||
76 | Controls are defined as follows: | ||
77 | |||
78 | Trigger Action | ||
79 | ------------------------------- ------------------------------------------------------- | ||
80 | Click on a traversable tile Moves the robot to the pointed location | ||
81 | `RETURN` on a free tile Drops a bomb at the current location | ||
82 | `RETURN` on a tile with a bomb Increases the timer of the bomb at the current location | ||
83 | |||
84 | \newpage | ||
85 | |||
27 | ## Custom levels | 86 | ## Custom levels |
87 | |||
88 | Custom world can be defined by the user in plain text files, each of which containing a single world. | ||
89 | Such a definition file most contain no empty line, leading or trailing tabulation or space. | ||
90 | |||
91 | A tile map is a rectangular character array from the following alphabet: | ||
92 | |||
93 | Block type Character Bounding Must be reachable | ||
94 | ---------- --------- -------- ----------------- | ||
95 | Free (space) No Yes | ||
96 | Garbage G No Yes | ||
97 | Trash can T Yes Yes | ||
98 | Wall W Yes No | ||
99 | |||
100 | A world is defined as valid if its blocks fulfill the following criteria: | ||
101 | |||
102 | * The bounding box of the defined world must be made of bounding blocks. | ||
103 | * The interior space formed by bounding blocks must be unique and simple. | ||
104 | * Reachable blocks are either be adjacent or belong to the interior space. | ||
105 | * The world must contain at least one trash can and one garbage block. | ||
106 | |||
107 | Only valid worlds can be loaded into the game. | ||
108 | |||
109 | The validity of a world may not guaranty the solvability of the puzzle. | ||
110 | |||
111 | \newpage | ||
112 | |||
113 | __Example of invalid world definition:__ | ||
114 | ``` | ||
115 | WWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWW | ||
116 | W W W | ||
117 | W W W T | ||
118 | WWWWWWWWWW W | ||
119 | W W W | ||
120 | W W WWWWWWWWWWW | ||
121 | WWWWWWWWWW W | ||
122 | W W W | ||
123 | W W W | ||
124 | WWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWW | ||
125 | ``` | ||
126 | |||
127 | __Example of valid world definition:__ | ||
128 | ``` | ||
129 | WWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWW | ||
130 | W WWWWWWWWWWW | ||
131 | W WWWWWWWWWWW | ||
132 | T WWWWWWWWWW WWWWWWWWWWW | ||
133 | T WWWWWWWWWW GGGGGGGGGGGGG WWWWWWWWWWW | ||
134 | T WWWWWWWWWW GGGGGGGG G WWWWWWWWWWW | ||
135 | T WWWWWWWWWW GGGGGGGGGGGGG W | ||
136 | W W W | ||
137 | W W W | ||
138 | WWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWW | ||
139 | ``` | ||