-
Notifications
You must be signed in to change notification settings - Fork 0
/
Enums_WinterIsComing.py
132 lines (116 loc) · 3.74 KB
/
Enums_WinterIsComing.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
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
# Enums and data structures
#----------------------------------------------
class ACTIONID():
VIEW = 0
GOTO = 1
OPEN = 2
USE = 3
GET = 4
NOC_YES = 5 #NO Choice, answer is YES
NOC_NO = 6 #NO Choice, answer is NO
class EXCHANGEDIR():
"""Spot exchange direction. FORWARD takes the first set of elements as 'from'
and the second set of elemtent as 'to', and vice verca."""
FORWARD = 1
REVERT = -1
class REACH():
ROOM = 1
SPOT = 2
class MOD():
#None = no mod
EFFONE = 1 #Once usable, effect on calling player
EFFALL = 2 #Once usable, effect on all players
NOTUSABLE = 3 #Item that cannot be used without a combination
PERMANENT = 4 #Item cannot be consumed, it is permanently available
#Player's mod value
CURRMOD = 5 #Get current player motivation/tiredness stat
LASTMOD = 6 #Get previous player motivation/tiredness stat
#Values and ranges for Motivation modificators on start/load game
LORANGE = 2 #values below this value
HIRANGE = 8 #values above this value
RNDM_VLRANGE = range(0,2)
RNDM_LORANGE = range(1,5)
RNDM_MIRANGE = range(3,7)
RNDM_HIRANGE = range(5,10)
#Time ranges for modificators on Restart Game
SHORTBREAK = 600 #seconds
BREAK = 7200
LONGBREAK = 86400
class CMDINPUT():
UNKNOWN = 2
NO = 0
YES = 1
QUIT = -1
class GUICONSTS():
"""This class contains all constants relevant for the gui to build."""
#current screen size
screenWidth = 0
screenHeight = 0
#Currently only used in GUI to define GUI specific contents
GUI_WAIT_UPDATE = 500 #milliseconds
GUI_LINEWRITE_WAIT = 500
GUI_TYPEWRITE_WAIT = 40
GUI_FONT = ["Lucida Console", "12"]
GUI_BOLD = ["Lucida Console", "12", "bold"]
GUI_TITLE = ["Lucida Console", "18", "bold"]
#number of spaces to center text of title menu
CTRSTR = " "*24
#Color Palette used throughout the game
DICTCOLORPALETTE = {
"B0" : '#000000',\
"B1" : '#000040',\
"B2" : '#003870',\
"B3" : '#0064C0',\
"B4" : '#3990C0',\
"Y0" : '#5F4443',\
"Y1" : '#9C7868',\
"Y2" : '#E7E39B',\
"Y3" : '#CEC098',\
"Y4" : '#FFFFBF',\
"Y5" : '#FFFFE6'
}
DICTPLAYERCOLORS = {
1 : '#FFFFFF',\
2 : '#C18C66',\
3 : '#C10CD4',\
4 : '#AC6FFF',\
5 : '#15A7C1',\
6 : '#11D0FF',\
7 : '#7FE1AE',\
8 : '#8EF120',\
}
#game window margin to screen size [pixels]
__XWINDOWMARGIN = 200
__YWINDOWMARGIN = 200
#color selection
FRAMECOLOR = DICTCOLORPALETTE["Y4"]
FONTCOLOR = DICTCOLORPALETTE["Y4"]
BGNDCOLOR = DICTCOLORPALETTE["B1"]
FRAMEBORDER = 2 #pixels, looks nice ;)
@classmethod
def setGameGuiSize(cls, varWidHeight):
cls.screenWidth = int(varWidHeight[0]-cls.__XWINDOWMARGIN)
cls.screenHeight = int(varWidHeight[1]-cls.__YWINDOWMARGIN)
@classmethod
def shortenWaits(cls):
cls.GUI_WAIT_UPDATE = 100 #milliseconds
cls.GUI_LINEWRITE_WAIT = 100
cls.GUI_TYPEWRITE_WAIT = 5
@classmethod
def normalWaits(cls):
cls.GUI_WAIT_UPDATE = 500 # milliseconds
cls.GUI_LINEWRITE_WAIT = 500
cls.GUI_TYPEWRITE_WAIT = 40
class SOUNDS():
SOUND_FADEOUT_TIME = 2000
DICTMUSIC = {\
100: "Sound/Train_Station_1_St_Scene.ogg", \
110: "Sound/DerWinterNaht_MainTheme.ogg", \
140: "Sound/Wellenstation.mp3",\
170: "Sound/SX018_Amb_forest_birds_02.ogg",\
200: "Sound/DerWinterNaht_MainTheme.ogg", \
}
class VIDEOS():
VIDEO_FRAMERATE = 25 #frames per second
DICTVIDEO = {\
0: "Video/SplashScreen.mp4"}