In this game, you have to create Snek more clever than opponents. According to "program" Snek will eat opponents on a battle arena.
At the beginning of a game you have to create Snek, choose its name and color and program its behavior. Then you enable auto fight mode and run battle.
Two to nine sneks take part in a battle. They crawl on an arena's cells according to "program", analyze surrounding area and try to catch opponents by the tail. If Snek grabs opponent's tail, it grows by one cell and opponent shortens by one cell.
Snek can't move if all surrounding cells filled with its body, enemy's head or body or wall.
Battle finishes any of these events happen:
You can program Snek's behavior using rules patterns 7x7 cells size. Each moment Snek observes 7x7 cells of an arena around its head and compares it with the first rules pattern, rotating it if needed.
A pattern is equal to an arena's fragment if all non-empty cells of a pattern are equal to the observable area.
In this case head direction of the matched pattern shows where Snek will move in a current round. If not, a program compares a fragment with the next pattern until match found. If no matches found, Snek moves to the random direction.
A pattern is considered matched if all non-empty cells are matched to observable arena fragment.
In addition, there are two more cell matching modes: optional and exclusion.
If a pattern contains more than one cells in OPTIONAL mode, the pattern is matched if only at least one of OPTIONAL cells of the same type are matched. If several pattern rotations matched, the program selects the pattern rotation which contains more matched optional cells.
If a pattern contains cell in MUST NOT mode, cell considered matched if a cell from an arena is not equal to the cell of the pattern with the same coordinates.
Snek will move in the random direction because no rules cells set.
Snek will move in the direction where enemy's tail is located (on the adjacent cell).
Snek will move in the random direction because there aren't two enemy tails near Snek's head.
Snek will move in the direction where enemy's tail is located because one optional cell matched.
Snek will move down because it tries to have it's body behind.
Join our community:
For discussions:
For announcements: