AI_PRO/Main/Board.py
2021-03-29 01:15:48 +02:00

14 lines
353 B
Python

import random
from Main.Field import Field
from Main.constants import *
def generate():
board = []
for i in range(0, int(HORIZONTAL_TILES_NUMBER)):
board.append([])
for j in range(0, int(VERTICAL_TILES_NUMBER)):
board[i].append(Field(int(i * TILE_SIZE), int(j * TILE_SIZE), random.randint(0, 3)))
return board