AI_PRO/constants.py

43 lines
747 B
Python
Raw Normal View History

2021-03-29 02:19:55 +02:00
#constants
# display size in pixels
2021-03-29 04:17:31 +02:00
from math import ceil, floor
2021-03-29 02:53:27 +02:00
DISPLAY_SIZE_HORIZONTAL = 1600
2021-06-22 23:12:13 +02:00
DISPLAY_SIZE_VERTICAL = 800
2021-03-29 02:19:55 +02:00
#TILE DIVIDER = TILE SIZE
2021-03-29 02:53:27 +02:00
TILE_SIZE = 100
2021-03-29 02:19:55 +02:00
# number of tiles
2021-05-31 21:09:45 +02:00
HORIZONTAL_TILES_NUMBER = floor((DISPLAY_SIZE_HORIZONTAL)/TILE_SIZE)
2021-06-22 23:12:13 +02:00
VERTICAL_TILES_NUMBER = floor((DISPLAY_SIZE_VERTICAL-200)/TILE_SIZE)
2021-03-29 02:19:55 +02:00
#TILE_SIZE
#colors
WHITE = (255, 255, 255) #SUPER UPRAWA
BLACK = (0, 0, 0)
RED = (255, 0, 0) #DO ZASIANIA
YELLOW = (255, 255, 0) #DO PODLANIA
GREEN = (0, 255, 0) #DO SCIECIA
#tractor const
TRACTOR_WIDTH = TILE_SIZE
TRACTOR_HEIGHT = TILE_SIZE
#FRAMES PER SECOND
2021-05-19 04:01:26 +02:00
FPS = 5
2021-03-29 02:19:55 +02:00
2021-03-30 00:54:29 +02:00
#ANIMATION_PART
2021-05-19 04:01:26 +02:00
ANIMATION_PART = 1
TRACTOR_DIRECTION_RIGHT = 2
TRACTOR_DIRECTION_UP = 1
TRACTOR_DIRECTION_DOWN = 3
TRACTOR_DIRECTION_LEFT = 4