2019-05-30 18:37:26 +02:00
|
|
|
import sys, random, MapGenerator
|
2019-04-01 10:33:32 +02:00
|
|
|
|
|
|
|
CELL_SIZE = 64
|
|
|
|
FPS = 60
|
2019-05-30 18:09:57 +02:00
|
|
|
DELAY = 50
|
2019-04-01 10:33:32 +02:00
|
|
|
|
2019-05-30 18:37:26 +02:00
|
|
|
try:
|
|
|
|
map_mode = sys.argv[1]
|
|
|
|
if(map_mode == "auto"):
|
|
|
|
MAP_NAME = MapGenerator.GenerateMap()
|
|
|
|
else:
|
|
|
|
MAP_NAME = map_mode
|
|
|
|
except:
|
|
|
|
print("ERROR: Invalid map mode")
|
|
|
|
sys.exit()
|
|
|
|
|
|
|
|
|
|
|
|
map = open( MAP_NAME, 'r' )
|
2019-04-01 14:07:27 +02:00
|
|
|
|
|
|
|
GRID_WIDTH, GRID_HEIGHT = [int(x) for x in map.readline().split()]
|
|
|
|
GC_X, GC_Y = [int(x) for x in map.readline().split()]
|
2019-04-01 10:33:32 +02:00
|
|
|
|
|
|
|
WINDOW_HEIGHT = GRID_HEIGHT * CELL_SIZE
|
2019-04-01 12:48:11 +02:00
|
|
|
WINDOW_WIDTH = GRID_WIDTH * CELL_SIZE
|
|
|
|
|
2019-04-23 17:15:05 +02:00
|
|
|
HOUSE_CAPACITY = random.randint(1, 11)
|