Skip to content

Commit

Permalink
WIP: add explanation of food expiration under a bot's shadow
Browse files Browse the repository at this point in the history
  • Loading branch information
otizonaizit committed Aug 2, 2024
1 parent 491a2e4 commit 8babf76
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@ The rules:

- **noisy enemy positions**: bots can know their enemies' exact positions only when the enemies are within a distance of **5** squares. If the enemies are further away than that, the bots have access only to a noisy position (more details [below](#is-noisy)).

- **food relocation**: a ghost casts a shadow of **3** squares around itself. Food pellets that stay in the shadow of a ghost for more than 30 turns without interruption are moved to a different location at random (more details [below](#shaded-food)).

- **timeouts**: each bot has **3** seconds to return a valid move. If it doesn't return in time a random legal move is executed instead and an error is recorded.

- **illegal moves**: if a bot returns an illegal move, a random legal move is executed instead and an error is recorded.
Expand Down Expand Up @@ -342,6 +344,7 @@ Note that the `Bot` object is read-only, i.e. any modifications you make to that
```
as soon as the enemy starts eating your food pellets this list will shorten up!
- **`bot.shaded_food`** <a id="shaded-food"></a> a list of the food pellets currently in the shadow of one or both of the team's bots. When a bot is in its homezone it casts a shadow of **3** squares. Food pellets that happen to be in the shadow for **30** turns without interruption will get relocated at the next turn. The new position of the pellets is chosen randomly within the free squares of the bot homezone, but outside of the bot's shadow and not on top of another bot. Note that **`bot.enemy[0].shaded_food`** is always empty, i.e. you can not see which food pellets are in the shadow of the enemy.
- **`bot.track`** is a list of the coordinates of the positions that the bot has taken until now. It gets reset every time the bot gets killed by an enemy ghost.
Expand Down

0 comments on commit 8babf76

Please sign in to comment.