UNPKG
snake-ai-game
Version:
latest (1.3.0)
1.3.0
1.1.0
1.0.3
1.0.2
1.0.1
1.0.0
A terminal-based snake game powered by AI.
snake-ai-game
/
src
/
constants
/
gameConstants.ts
13 lines
•
304 B
text/typescript
View Raw
1
2
3
4
5
6
7
8
9
10
11
12
13
export
const
GAME_CONSTANTS
=
{
DEFAULT_TIME_LIMIT:
30
,
DEFAULT_GRID_SIZE:
15
,
DEFAULT_SNAKE_START:
[ {
x:
5
,
y:
5
}, {
x:
5
,
y:
6
}, {
x:
5
,
y:
7
} ],
DEFAULT_FOOD_POSITION:
{
x:
8
,
y:
5
},
DEFAULT_DIRECTION:
'UP'
as
const
,
MIN_TIME_LIMIT:
10
,
MAX_TIME_LIMIT:
300
}
as
const;