/
config.py
85 lines (66 loc) · 2.59 KB
/
config.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
# -*- coding: utf-8 -*-
# set which part of the game you want to debug, set all for maximum output
# DEBUG = ('init', 'font', 'track', 'path', 'station', 'passenger', 'random' )
DEBUG = ('init','font' )
# these basic gamemodes change the gameplay drastical
ANIMALS = False # an alternative animals graphic set from erlehmann
FREE_PASSENGERS = True # new passengers not at stations
STATION_PASSENGERS = False # new passengers at stations
BUILD_STATIONS = True # player can build new stations
DOUBLE_TRACKS = False # more than one track between same stations allowed?
CROSSING = False # crossing tracks allowed? TODO: Crossing=True does not work
COLLISION = False # set False if Cars should stop if other car is in the way
MAXWAITING = 80
BLACK = ( 0, 0, 0)
VERYLIGHTGREY= (220, 220, 220)
LIGHTGREY= (200, 200, 200)
WHITE = (255, 255, 255)
BLUE = ( 0, 0, 255)
GREEN = ( 0, 255, 0)
RED = (255, 0, 0)
MAGENTA = (255, 0, 255)
CYAN = ( 0, 255, 255)
YELLOW = (255, 255, 0)
COLORS = [YELLOW,MAGENTA,CYAN,GREEN,BLUE,RED]
#COLORS = [CYAN,GREEN,BLUE,RED]
# LINES = list(COLORS)
COLORNAMES = ['red','blue','green','cyan','magenta','yellow']
SHAPES = ('circle','triangle','square','rhombus','semicircle')
OTHERSTATIONS = ('circle','triangle','rhombus','semicircle')
# use this two lines instead if you don't have the pygame patch from benni:
SHAPES = ('circle','triangle','square','rhombus')
OTHERSTATIONS = ('circle','triangle','rhombus')
MAINSTATION = 'square'
MAXSTATIONS = 0 # stations build (without mainstation) during game init
PASSENGERSIZE = 7
PASSENGERSPEED = 0.3 # speed of passengers by foot
PASSENGER_RANDOMNESS = 0.01 # rate at which passenger in random mode changes direction
CARCAPACITY = 3
CARWITH = PASSENGERSIZE + 3 # actually half of it
CARLENGTH = 13 + PASSENGERSIZE * CARCAPACITY # actually half of it
CARSPEED = 3
MAXTRACKLENGTH = CARLENGTH * 5 # set to 0 for no length restrictions
# MAXTRACKLENGTH = 0 # set to 0 for no length restrictions
STATIONSIZE = 17
STATIONTHICKNESS = 5
STATIONDISTANCE = CARLENGTH * 2
MAXSTATIONTRACKS = 5
STATIONTRACKDIST = 0 # TODO: minimal distance between tracks and center of station
PROBABILITY_START = .01
PROBABILITY_DIFF = .000005
# PROBABILITY_DIFF = 0
MAXWAITING_STATION = 9999
RIGHT_OFFSET = 200
#RIGHT_OFFSET = 200
MAX_Y = 500
MAX_X = MAX_Y + RIGHT_OFFSET
STATUSHEIGHT = 30 # height of status line at the bottom
MAX_DEPTH = 99999 # max distance for path finding (means no path)
FPS = 30
# money and prices
STARTMONEY = 30 # 30
STATIONCOST = 5
TRACKCOST = 1
DELETECOST = 1
# LINECOST = 5
FONTSIZE = 18 # size of the default font used