Skip to content

Commit 2002acc

Browse files
committed
Updated the README.
1 parent fabd761 commit 2002acc

1 file changed

Lines changed: 27 additions & 8 deletions

File tree

README.md

Lines changed: 27 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,31 @@
11
# Worm-Arena
2-
A [Snake](https://en.wikipedia.org/wiki/Snake_(video_game_genre)) like arena.
3-
Click image below to join the official Discord channel.
2+
Worm is a [Snake](https://en.wikipedia.org/wiki/Snake_(video_game_genre)) like arena.
3+
Click the image below to join the official Discord channel.
44
<br>[![Discord banner2](https://discord.com/api/guilds/765291928454823936/widget.png?style=banner2)](https://discord.gg/wtFvtECqSX)
55

6-
## Rules
7-
You will receive an array representing the gameboard. You receive one point for every eaten object, or if you are the `LastWormStanding`. You will start in the lower middle, facing up. Valid responses are `-1` for turning left, `0` for moving strait forward and `1` for turning right. Also if `threeDimensions` is enabled (currently disabled): `'-i'` for turning down and `'i'` for turning up.
6+
Participants receives a multidimensional array representing the current state of the arena and responds with the direction the worm should travel next. Possible responses are `'x+'`, `'x-'`, `'y+'`, `'y-'`, `'z-'` and `'z+'`. Responding with a invalid move (like turning backwards) results in moving forward.
87

9-
### Disqualifications
10-
Violating any of this will lead to DNF (Did-Not-Finish), aborted game and disqualification from the running tournament.
11-
- Caught exceeding the time limit (`timelimit_ms`) for tick execution defined by the tournament.
12-
- Respond with invalid response.
8+
**Message example**
9+
``` JavaScript
10+
[[[{"eatables":{"apple":null,"other":0},"occupiedBy":null,"grave":[]},{"eatables":{"apple":4,"other":0},"occupiedBy":null,"grave":[]},{"eatables":{"apple":null,"other":0},"occupiedBy":{"type":"SolidWorm","team":3,"isLastTrailingBody":false},"grave":[]},{"eatables":{"apple":null,"other":0},"occupiedBy":null,"grave":[]},{"eatables":{"apple":null,"other":0},"occupiedBy":null,"grave":[]}],[{"eatables":{"apple":null,"other":0},"occupiedBy":null,"grave":[]},{"eatables":{"apple":null,"other":0},"occupiedBy":null,"grave":[]},{"eatables":{"apple":null,"other":0},"occupiedBy":null,"grave":[]},{"eatables":{"apple":null,"other":0},"occupiedBy":null,"grave":[]},{"eatables":{"apple":2,"other":0},"occupiedBy":null,"grave":[]}],[{"eatables":{"apple":null,"other":0},"occupiedBy":{"type":"SolidWorm","team":1,"isLastTrailingBody":false},"grave":[]},{"eatables":{"apple":null,"other":0},"occupiedBy":null,"grave":[]},{"eatables":{"apple":null,"other":0},"occupiedBy":null,"grave":[]},{"eatables":{"apple":null,"other":0},"occupiedBy":null,"grave":[]},{"eatables":{"apple":null,"other":0},"occupiedBy":{"type":"SolidWorm","team":0,"isLastTrailingBody":false},"grave":[]}],[{"eatables":{"apple":3,"other":0},"occupiedBy":null,"grave":[]},{"eatables":{"apple":null,"other":0},"occupiedBy":null,"grave":[]},{"eatables":{"apple":null,"other":0},"occupiedBy":null,"grave":[]},{"eatables":{"apple":null,"other":0},"occupiedBy":null,"grave":[]},{"eatables":{"apple":null,"other":0},"occupiedBy":null,"grave":[]}],[{"eatables":{"apple":null,"other":0},"occupiedBy":null,"grave":[]},{"eatables":{"apple":null,"other":0},"occupiedBy":null,"grave":[]},{"eatables":{"apple":null,"other":0},"occupiedBy":{"type":"SolidWorm","team":2,"isLastTrailingBody":false},"grave":[]},{"eatables":{"apple":1,"other":0},"occupiedBy":null,"grave":[]},{"eatables":{"apple":null,"other":0},"occupiedBy":null,"grave":[]}]]]
11+
```
12+
Note that `eatables.apple` can either be `null` or a number. The number only represent an ID and is always only worth one point. When a worm is defeated and leaves eatables behind, they are put into `eatables.other`.
13+
14+
**Eatable example**
15+
``` JavaScript
16+
{"eatables":{"apple":0,"other":0}}
17+
```
18+
19+
## Configurations
20+
*Basic description of each parameter. Some parameter combinations is incompatible. Read more at the arena.*
21+
| Scope | Value | Description |
22+
| --- | --- |---|
23+
| `arena` | `size` | Defines the size (length of each side) of the arena. |
24+
| `arena` | `threeDimensions` | If enable the size of the arena is `size*size*size` instead of `size*size`. |
25+
| `border` | `noBorder` | If enable the worm will appear of the opposite side of the arena instead of colliding with a wall. |
26+
| `border` | `movesPerArenaShrink` | How many moves a worm can make before the arena shrinks. |
27+
| `border` | `shrinkMode` |`RandomPlacedWall_single`<br>A random wall is placed anywhere on the arena. <br>• `RandomPlacedWall_fourSymmetry`<br>Four walls are placed symmetrically on the arena. <br>• `RandomPlacedWall_perWorm`<br>One random wall pere living worm is placed anywhere on the arena. <br>• `WallOuterArea`<br>Playable arena shrinks my placing a wall on the most outer sides. |
28+
| `rules` | `startLength` | How long the worm will start as. |
29+
| `rules` | `apples` | How many apples is located at the arena and how they are placed. |
30+
| `rules` | `defeatedWorms` | What will happen to a defeated worm.<br>• `Disappears`<br>Defeated worms are removed.<br>• `Eatable`<br>Defeated worms becomes eatable for extra points.<br>• `Solid`<br>Defeated worms turns into a wall. |
31+
| `rules` | `winner` |`LastWormStanding`<br>Participants that are alive receive one point each time a worm is defeated. <br>• `MostPoints`<br>Participants receive one point for every eaten object until there is no more worms alive.|

0 commit comments

Comments
 (0)