-
Notifications
You must be signed in to change notification settings - Fork 12
/
splash.rpy
322 lines (275 loc) · 8.26 KB
/
splash.rpy
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
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
## This splash screen is the first thing that Renpy will show the player
##
## Before load, check to be sure that the archive files were found.
## If not, display an error message and quit.
init -100 python:
#Check for each archive needed
for archive in ['audio','images', 'fonts']:
if not archive in config.archives:
#If one is missing, throw an error and chlose
renpy.error("DDLC archive files not found in /game folder. Check installation and try again.")
## First, a disclaimer declaring this is a mod is shown, then there is a
## check for the original DDLC assets in the install folder. If those are
## not found, the player is directed to the developer's site to download.
##
init python:
menu_trans_time = 1
#The default splash message, originally shown in Act 1 and Act 4
splash_message_default = "This game is an unofficial fan work, unaffiliated with Team Salvato."
#Optional splash messages, originally chosen at random in Act 2 and Act 3
splash_messages = [
"Please support Doki Doki Literature Club."
"Monika is watching you code."
]
image splash_warning = ParameterizedText(style="splash_text", xalign=0.5, yalign=0.5)
##Here's where you can change the logo file to whatever you want
image menu_logo:
"/mod_assets/DDLCModTemplateLogo.png"
subpixel True
xcenter 240
ycenter 120
zoom 0.60
menu_logo_move
image menu_bg:
topleft
"gui/menu_bg.png"
menu_bg_move
image game_menu_bg:
topleft
"gui/menu_bg.png"
menu_bg_loop
image menu_fade:
"white"
menu_fadeout
image menu_art_y:
subpixel True
"gui/menu_art_y.png"
xcenter 600
ycenter 335
zoom 0.60
menu_art_move(0.54, 600, 0.60)
image menu_art_n:
subpixel True
"gui/menu_art_n.png"
xcenter 750
ycenter 385
zoom 0.58
menu_art_move(0.58, 750, 0.58)
image menu_art_s:
subpixel True
"gui/menu_art_s.png"
xcenter 510
ycenter 500
zoom 0.68
menu_art_move(0.68, 510, 0.68)
image menu_art_m:
subpixel True
"gui/menu_art_m.png"
xcenter 1000
ycenter 640
zoom 1.00
menu_art_move(1.00, 1000, 1.00)
image menu_art_y_ghost:
subpixel True
"gui/menu_art_y_ghost.png"
xcenter 600
ycenter 335
zoom 0.60
menu_art_move(0.54, 600, 0.60)
image menu_art_n_ghost:
subpixel True
"gui/menu_art_n_ghost.png"
xcenter 750
ycenter 385
zoom 0.58
menu_art_move(0.58, 750, 0.58)
image menu_art_s_ghost:
subpixel True
"gui/menu_art_s_ghost.png"
xcenter 510
ycenter 500
zoom 0.68
menu_art_move(0.68, 510, 0.68)
image menu_art_m_ghost:
subpixel True
"gui/menu_art_m_ghost.png"
xcenter 1000
ycenter 640
zoom 1.00
menu_art_move(1.00, 1000, 1.00)
image menu_art_s_glitch:
subpixel True
"gui/menu_art_s_break.png"
xcenter 470
ycenter 600
zoom 0.68
menu_art_move(.8, 470, .8)
image menu_nav:
"gui/overlay/main_menu.png"
menu_nav_move
image menu_particles:
2.481
xpos 224
ypos 104
ParticleBurst("gui/menu_particle.png", explodeTime=0, numParticles=20, particleTime=2.0, particleXSpeed=6, particleYSpeed=4).sm
particle_fadeout
transform particle_fadeout:
easeout 1.5 alpha 0
transform menu_bg_move:
subpixel True
topleft
parallel:
xoffset 0 yoffset 0
linear 3.0 xoffset -100 yoffset -100
repeat
parallel:
ypos 0
time 0.65
ease_cubic 2.5 ypos -500
transform menu_bg_loop:
subpixel True
topleft
parallel:
xoffset 0 yoffset 0
linear 3.0 xoffset -100 yoffset -100
repeat
transform menu_logo_move:
subpixel True
yoffset -300
time 1.925
easein_bounce 1.5 yoffset 0
transform menu_nav_move:
subpixel True
xoffset -500
time 1.5
easein_quint 1 xoffset 0
transform menu_fadeout:
easeout 0.75 alpha 0
time 2.481
alpha 0.4
linear 0.5 alpha 0
transform menu_art_move(z, x, z2):
subpixel True
yoffset 0 + (1200 * z)
xoffset (740 - x) * z * 0.5
zoom z2 * 0.75
time 1.0
parallel:
ease 1.75 yoffset 0
parallel:
pause 0.75
ease 1.5 zoom z2 xoffset 0
image intro:
truecenter
"white"
0.5
"bg/splash.png" with Dissolve(0.5, alpha=True)
2.5
"white" with Dissolve(0.5, alpha=True)
0.5
image warning:
truecenter
"white"
"splash_warning" with Dissolve(0.5, alpha=True)
2.5
"white" with Dissolve(0.5, alpha=True)
0.5
image tos = "bg/warning.png"
image tos2 = "bg/warning2.png"
label splashscreen:
## devmode check
default devmode = ['Devmode']
python:
for x in devmode:
if player in devmode:
config.developer = True
renpy.notify('Developer Mode Enabled')
#If this is the first time the game has been run, show a disclaimer
default persistent.first_run = False
if not persistent.first_run:
$ quick_menu = False
scene white
pause 0.5
scene tos
with Dissolve(1.0)
pause 1.0
"[config.name] is a Doki Doki Literature Club fan mod that is not affiliated with Team Salvato."
"It is designed to be played only after the official game has been completed, and contains spoilers for the official game."
"Game files for Doki Doki Literature Club are required to play this mod and can be downloaded for free at: http://ddlc.moe"
menu:
"By playing [config.name] you agree that you have completed Doki Doki Literature Club and accept any spoilers contained within."
"I agree.":
pass
scene tos2
with Dissolve(1.5)
pause 1.0
#Optional, load a copy of DDLC save data
#call import_ddlc_persistent
scene white
with Dissolve(1.5)
$ persistent.first_run = True
$ basedir = config.basedir.replace('\\', '/')
#autoload handling
#Use persistent.autoload if you want to bypass the splashscreen on startup for some reason
if persistent.autoload and not _restart:
jump autoload
# Start splash logic
$ config.allow_skipping = False
# Splash screen
show white
$ persistent.ghost_menu = False #Handling for easter egg from DDLC
$ splash_message = splash_message_default #Default splash message
$ config.main_menu_music = audio.t1
$ renpy.music.play(config.main_menu_music)
show intro with Dissolve(0.5, alpha=True)
pause 2.5
hide intro with Dissolve(0.5, alpha=True)
#You can use random splash messages, as well. By default, they are only shown during certain acts.
if persistent.playthrough == 2 and renpy.random.randint(0, 3) == 0:
$ splash_message = renpy.random.choice(splash_messages)
show splash_warning "[splash_message]" with Dissolve(0.5, alpha=True)
pause 2.0
hide splash_warning with Dissolve(0.5, alpha=True)
$ config.allow_skipping = True
return
label warningscreen:
hide intro
show warning
pause 3.0
label after_load:
$ config.allow_skipping = allow_skipping
$ _dismiss_pause = config.developer
$ persistent.ghost_menu = False #Handling for easter egg from DDLC
$ style.say_dialogue = style.normal
#Check if the save has been tampered with
if anticheat != persistent.anticheat:
stop music
scene black
"The save file could not be loaded."
"Are you trying to cheat?"
#Handle however you want, default is to force reset all save data
$ renpy.utter_restart()
return
label autoload:
python:
# Stuff that's normally done after splash
if "_old_game_menu_screen" in globals():
_game_menu_screen = _old_game_menu_screen
del _old_game_menu_screen
if "_old_history" in globals():
_history = _old_history
del _old_history
renpy.block_rollback()
# Fix the game context (normally done when loading save file)
renpy.context()._menu = False
renpy.context()._main_menu = False
main_menu = False
_in_replay = None
# Pop the _splashscreen label which has _confirm_quit as False and other stuff
$ renpy.pop_call()
jump expression persistent.autoload
label before_main_menu:
$ config.main_menu_music = audio.t1
return
label quit:
return