-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathwizard.tsct
988 lines (963 loc) · 21.6 KB
/
wizard.tsct
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
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
/*
* This file was auto-generated using 'silver-reversing-sct' tool
* to better understand the scripts presented, one is encouraged to
* view the catalogs at:
* https://github.com/nadavshemesh/silver-reversing-sct/blob/master/docs/index.md
*
* Any further information and support of this project please visit:
* https://github.com/nadavshemesh/silver-reversing-sct
*/
._DATA
VAR_17 { 0, 0, 1 }
fx_position { -1818, 1557, -1056 }
VAR_38 { 1876, 1557, -5693 }
init_position1 { -260, -173, 1354 }
init_position2 { -362, -174, 1092 }
VAR_44 { -390, -174, 1449 }
VAR_45 { -189, -174, 1489 }
VAR_46 { -250, -174, 1050 }
arr { VAR_44, VAR_45, VAR_46 }
init_position3 { -13, -173, 1707 }
init_position4 { -148, -173, 1439 }
VAR_52 { -140, -173, 1770 }
VAR_53 { -21, -173, 1785 }
VAR_54 { 48, -173, 1445 }
arr_1 "svy"
VAR_58 { 0, 0, 0 }
VAR_59 { 0, 0, 0 }
VAR_66 { 0, 0, 0, 0 }
init_position { -348, 0, 2494 }
VAR_77 2
VAR_79 "SHR,"
VAR_82 2
VAR_83 { -257, -174, 1176 }
VAR_84 { 421, -174, 1790 }
VAR_87 { -3757, -334, -651 }
VAR_88 { -4, -1350, -516 }
VAR_90 { -348, 350, 2494 }
VAR_91 -1
VAR_110 -1
VAR_111 7
VAR_115 { 0, 0 }
VAR_120 { -10001, -350, 1811 }
VAR_121 -1
walk_position { 490, -528, 1784 }
init_position5 { 1101, -528, 2488 }
._on_load
call stop_bgm(int 1)
execute SCRIPT_3
execute SCRIPT_5
call load_sound_set(int 45)
switch(gamevar room_state)
{
case 1
execute SCRIPT_7
break
case 2
execute SCRIPT_11
break
case 3
break
case 4
gamevar *scene_info_p+1 = int 1
execute SCRIPT_14
break
case 0
break
}
._infinite_loop
execute SCRIPT_18
switch(gamevar room_state)
{
case 1
execute SCRIPT_6
execute SCRIPT_15
execute SCRIPT_16
break
case 2
execute SCRIPT_10
execute SCRIPT_16
break
case 3
break
case 4
execute SCRIPT_13
break
case 0
break
}
._on_exit
switch(gamevar room_state)
{
case 1
if(gamevar changed_scene_via_map)
{
call save_pos_to_room_memory(int 123456, int 0, var VAR_25, int 0)
}
gamevar room_state ++
break
case 2
break
case 3
if(var VAR_24 == int 1)
{
gamevar room_state = int 2
}
if(gamevar changed_scene_via_map)
{
call save_pos_to_room_memory(int 123456, int 0, var VAR_25, int 0)
}
break
case 4
break
case 0
break
default
gamevar room_state = int 0
break
}
._SCRIPT_3
call log_string("it's_raining")
call play_3d_fx("RAIN", var &fx_position, var &VAR_38, int 0)
execute SCRIPT_17
._SCRIPT_4
if(gamevar room_state == int 1)
{
gamevar SMACKER_X = int 336
gamevar SMACKER_Y = int 156
call play_2d_anim("bath_sub", int 0, int 0, var &VAR_58)
}
gamevar SMACKER_X = int 0
gamevar SMACKER_Y = int 388
call play_2d_anim("water", int 1, int 0, int 0)
gamevar SMACKER_X = int 392
gamevar SMACKER_Y = int 200
var VAR_60 = call play_2d_anim("subbob", int 10737418, int 0, var &VAR_59)
._SCRIPT_5
var david = call get_david_char()
while(var david)
{
var VAR_27 = call get_char_handle_id(var david)
switch(var VAR_27)
{
case 65536
call log_string("david")
var VAR_18 = var david
break
case 786432
call log_string("sekune")
var VAR_20 = var david
break
case 327680
call log_string("jug")
var VAR_19 = var david
break
case 196608
call log_string("vivienne")
var VAR_21 = var david
break
case 131072
call log_string("chiaro")
var VAR_22 = var david
break
case 262144
call log_string("cagen")
var VAR_23 = var david
break
default
call log_string("WARNING! Unknown hero while checking heroes")
call log_string("Get a goober -- QUICKLY!!")
break
}
var david = call get_next_char_from_list()
}
._SCRIPT_6
if(var VAR_91 != var VAR_75)
{
var VAR_91 = var VAR_75
call log_var(var VAR_75)
}
switch(var VAR_75)
{
case 0
if(var VAR_76 == int 5)
{
var index = int 0
var david = call get_david_char()
while(var david)
{
call char_stop(var david)
call char_teleport_to_pos(var david, @arr[var VAR_78], int 0)
var index ++
var david = call get_next_char_from_list()
}
var VAR_75 ++
var VAR_76 = int 0
}
break
case 1
if(var VAR_76 == int 5)
{
var david = call get_david_char()
while(var david)
{
call func_e1(var david, var nraft)
var david = call get_next_char_from_list()
}
var VAR_75 ++
var VAR_76 = int 0
}
break
case 2
if(var VAR_76 == int 5)
{
call func_e1(var nboatman, var nraft)
call func_94(var nraft, var &VAR_79, int 10821304)
var VAR_68 = int 1
var VAR_75 ++
var VAR_76 = int 0
}
break
case 3
if(var VAR_76 > int 200)
{
if(var VAR_20)
{
call start_dialog("S_DVDTHA", "NULL")
}
else
{
if(var VAR_21)
{
call start_dialog("V_DVDTHA", "NULL")
}
else
{
if(var VAR_19)
{
call start_dialog("J_DVDTHA", "NULL")
}
else
{
call log_string("OOps! Fuck up! Sekune, Vivienne and Jug not here!")
}
}
}
var VAR_68 = int 0
var VAR_75 ++
var VAR_76 = int 0
}
break
case 4
if(call func_6d() == int 1)
{
call func_116("haven", "h_camptp", int 5)
var VAR_75 ++
var VAR_76 = int 0
}
break
case 5
if(var VAR_76 == int 120)
{
gamevar compile_init_character = int 0
var nthaddeus = call create_char(var &init_position, "nthaddeus", int 195, int 16)
gamevar script_object = var nthaddeus
gamevar *object_p+7 |= int -2147483
gamevar compile_init_character = int 1
var VAR_80 = int 1
call func_f1(var nthaddeus, int 7)
call func_ec(int 229, int 0, int 0, int 0)
call apply_effect_on_char(gamevar char_gen_fx_scripts, int 11, var &VAR_90, int 0)
var VAR_75 ++
var VAR_76 = int 0
}
break
case 6
if(var VAR_76 > int 60)
{
if(var VAR_77 == int 3)
{
var VAR_80 = int 0
}
call resume_conversation()
var VAR_75 ++
var VAR_76 = int 0
}
break
case 7
if(call get_input_sys() != int 4)
{
if(var VAR_77 == int 3)
{
var VAR_80 = int 0
var VAR_75 ++
var VAR_76 = int 0
}
}
break
case 8
if(var VAR_76 > int 100)
{
call func_ec(int 230, int 0, int 0, int 0)
call apply_effect_on_char(gamevar char_gen_fx_scripts, int 11, var &VAR_90, int 0)
var VAR_75 ++
var VAR_76 = int 0
}
break
case 9
var VAR_81 = var VAR_76 % int 3
if(var ! VAR_81)
{
call func_f1(var nthaddeus, var VAR_82)
var VAR_82 ++
if(var VAR_82 > int 7)
{
var VAR_75 ++
var VAR_76 = int 0
}
}
break
case 10
if(var VAR_76 > int 10)
{
var VAR_70 = int 1
call remove_char(var nthaddeus)
var VAR_75 ++
var VAR_76 = int 0
}
break
case 11
if(var VAR_76 == int 100)
{
call set_input_system(int 1)
gamevar no_user_input = int 1
call func_fc(var nboatman)
var david = call get_david_char()
while(var david)
{
call func_fc(var david)
var david = call get_next_char_from_list()
}
}
if(var VAR_76 == int 150)
{
var VAR_75 ++
var VAR_76 = int 0
}
break
case 12
var position = int 0
if(gamevar CLICKED_DOOR != int -1)
{
var VAR_24 = gamevar CLICKED_DOOR
if(gamevar CLICKED_DOOR == int 0)
{
var position = var &VAR_83
var VAR_86 = int 100
}
}
if(gamevar global_zone_type == int 18)
{
var VAR_89 = int 1
var position = var &VAR_84
var VAR_86 = int 100
}
if(var position)
{
call set_input_system(int 2)
gamevar no_user_input = int 0
call char_turn_to_pos(var nboatman, var position)
var david = call get_david_char()
while(var david)
{
call func_fc(var david)
call char_turn_to_pos(var david, var position)
var david = call get_next_char_from_list()
}
var VAR_75 ++
var VAR_76 = int 0
}
break
case 13
if(var VAR_76 == int 45)
{
var david = call get_david_char()
while(var david)
{
call func_e1(var david, var nraft)
var david = call get_next_char_from_list()
}
call func_e1(var nboatman, var nraft)
call func_94(var nraft, var position, int 10737418)
var VAR_68 = int 1
var VAR_75 ++
var VAR_76 = int 0
}
break
case 14
if(var VAR_76 == var VAR_86)
{
if(var VAR_89)
{
call log_string("palace")
call func_e6("palace", "s_throne", var &VAR_88, int 1)
call save_pos_to_room_memory(int 123456, int 0, int 1, int 0)
}
else
{
call log_string("cld_rd_3")
call func_e6("rain", "cld_rd_3", var &VAR_87, int 3)
call save_pos_to_room_memory(int 123456, int 1, int 0, int 0)
}
var VAR_75 = int -1
var VAR_76 = int 0
}
break
}
if(call is_char_handle_in_level(int 11206656 /* THADDEUS */ ))
{
if(var VAR_80)
{
execute SCRIPT_8
}
}
var VAR_76 ++
._SCRIPT_7
call load_char("thaddeus")
execute SCRIPT_9
execute SCRIPT_4
gamevar *scene_info_p+3 = int 2
call set_input_system(int 2)
._SCRIPT_8
switch(var VAR_77)
{
case 0
var VAR_109 = var VAR_108 % int 3
if(var ! VAR_109)
{
call func_f1(var nthaddeus, var VAR_111)
var VAR_111 += var VAR_110
if(var VAR_111 > int 7)
{
var VAR_77 = int 1
var VAR_108 = int 0
}
}
break
case 1
if(var VAR_108 > int 50)
{
var VAR_111 = int 7
var VAR_110 = int -1
var VAR_77 = int 2
var VAR_108 = int 0
}
break
case 2
var VAR_109 = var VAR_108 % int 3
if(var ! VAR_109)
{
call func_f1(var nthaddeus, var VAR_111)
var VAR_111 += var VAR_110
if(var VAR_111 < int 2)
{
var VAR_77 = int 3
var VAR_108 = int 0
}
}
break
case 3
if(var VAR_108 > int 50)
{
var VAR_111 = int 2
var VAR_110 = int 1
var VAR_77 = int 0
var VAR_108 = int 0
}
break
}
var VAR_108 ++
._SCRIPT_9
var nraft = call create_char(var &init_position1, "nraft", int 0, int 13)
var nboatman = call create_char(var &init_position2, "nboatman", int 0, int 13)
call func_d9(var nraft)
gamevar unknown_02_00_65 = int 1
._SCRIPT_10
if(var VAR_121 != var VAR_116)
{
var VAR_121 = var VAR_116
call log_var(var VAR_116)
}
switch(var VAR_116)
{
case 0
if(var VAR_112)
{
var VAR_116 = int 10
var VAR_117 = int 0
}
else
{
var VAR_116 ++
var VAR_117 = int 0
}
break
case 1
if(var VAR_117 == int 5)
{
var index_1 = int 0
var david = call get_david_char()
while(var david)
{
call char_stop(var david)
var index_1 ++
var david = call get_next_char_from_list()
}
}
if(var VAR_117 == int 10)
{
var index_1 = int 0
var david = call get_david_char()
while(var david)
{
call char_teleport_to_pos(var david, @arr_1[var VAR_118], int 0)
var index_1 ++
var david = call get_next_char_from_list()
}
var VAR_116 ++
var VAR_117 = int 0
}
break
case 2
if(var VAR_117 == int 5)
{
var index_1 = int 0
var david = call get_david_char()
while(var david)
{
call func_e1(var david, var nraft)
var index_1 ++
var david = call get_next_char_from_list()
}
call set_input_system(int 1)
gamevar no_user_input = int 1
var VAR_116 ++
var VAR_117 = int 0
}
break
case 3
var VAR_116 = int 14
var VAR_117 = int 0
break
case 10
if(var VAR_117 == int 5)
{
var index = int 0
var david = call get_david_char()
while(var david)
{
call char_stop(var david)
call char_teleport_to_pos(var david, @arr[var index], int 0)
var index ++
var david = call get_next_char_from_list()
}
var VAR_116 ++
var VAR_117 = int 0
}
break
case 11
if(var VAR_117 == int 5)
{
var david = call get_david_char()
while(var david)
{
call func_e1(var david, var nraft)
var david = call get_next_char_from_list()
}
var VAR_116 ++
var VAR_117 = int 0
}
break
case 12
if(var VAR_117 == int 5)
{
call func_e1(var nboatman, var nraft)
call func_94(var nraft, var &VAR_79, int 10821304)
var VAR_68 = int 1
var VAR_116 ++
var VAR_117 = int 0
}
break
case 13
if(var VAR_117 > int 200)
{
call set_input_system(int 1)
gamevar no_user_input = int 1
var VAR_68 = int 0
var VAR_116 ++
var VAR_117 = int 0
}
break
case 14
if(gamevar CLICKED_DOOR != int -1)
{
var VAR_24 = gamevar CLICKED_DOOR
if(gamevar CLICKED_DOOR == int 0)
{
var position = var &VAR_83
var VAR_86 = int 100
}
}
if(gamevar global_zone_type == int 18)
{
var VAR_119 = int 1
var position = var &VAR_84
var VAR_86 = int 100
}
if(var position)
{
call char_turn_to_pos(var nboatman, var position)
var david = call get_david_char()
while(var david)
{
call func_fc(var david)
call char_turn_to_pos(var david, var position)
var david = call get_next_char_from_list()
}
var VAR_116 ++
var VAR_117 = int 0
}
break
case 15
if(var VAR_117 == int 45)
{
var david = call get_david_char()
while(var david)
{
call func_e1(var david, var nraft)
var david = call get_next_char_from_list()
}
call func_e1(var nboatman, var nraft)
call func_94(var nraft, var position, int 10737418)
var VAR_68 = int 1
var VAR_116 ++
var VAR_117 = int 0
}
break
case 16
if(var VAR_117 == var VAR_86)
{
if(var VAR_119)
{
if(var VAR_25)
{
call log_string("spires")
call func_e6("spires", "entrance", var &VAR_120, int 2)
call save_pos_to_room_memory(int 123456, int 0, var VAR_25, int 0)
}
else
{
var VAR_25 = int 1
call log_string("palace")
call func_e6("palace", "s_throne", var &VAR_88, int 1)
}
call save_pos_to_room_memory(int 123456, int 0, var VAR_25, int 0)
}
else
{
call log_string("cld_rd_3")
call func_e6("rain", "cld_rd_3", var &VAR_87, int 3)
call save_pos_to_room_memory(int 123456, int 1, var VAR_25, int 0)
}
var VAR_116 = int -1
var VAR_117 = int 0
}
break
}
var VAR_117 ++
._SCRIPT_11
if(call func_bf(int 123456, gamevar CURRENT_LEVEL, gamevar CURRENT_SCENE))
{
call load_pos_from_room_memory(int 123456, var &VAR_113)
if(var VAR_114)
{
execute SCRIPT_9
var VAR_112 = int 1
}
else
{
execute SCRIPT_12
var VAR_112 = int 0
}
var VAR_25 = var VAR_115
}
else
{
var VAR_112 = int 1
execute SCRIPT_9
var VAR_25 = int 0
}
execute SCRIPT_4
gamevar script_object = var VAR_60
gamevar *smack_object_p+2 -= int 10737418
var VAR_59 = int 1
call set_input_system(int 1)
gamevar no_user_input = int 1
._SCRIPT_12
var nraft = call create_char(var &init_position3, "nraft", int 0, int 13)
var nboatman = call create_char(var &init_position4, "nboatman", int 0, int 13)
call func_d9(var nraft)
gamevar unknown_02_00_65 = int 1
._SCRIPT_13
switch(var VAR_131)
{
case 0
if(gamevar global_zone_type == int 18)
{
call set_input_system(int 2)
gamevar no_user_input = int 0
var VAR_131 ++
var david = call get_selected_hero()
var VAR_138 = var david
call char_walk_to_pos(var david, var &walk_position)
}
break
case 1
var VAR_132 ++
if(var VAR_132 > int 30)
{
var VAR_131 ++
call set_scene_overwrite_act("spires", "entrance", int 0)
call func_116("spires", "entrance", int 2)
call char_exit_door(var david, int 1)
}
break
}
._SCRIPT_14
gamevar SMACKER_X = int 480
gamevar SMACKER_Y = int 272
call play_2d_anim("wizard", int 1, int 1, int 0)
if(call ! is_char_handle_in_level(int 1507328 /* BTREASURE */ ))
{
var btreasure = call create_char(var &init_position5, "btreasure", int 230, int 14)
call add_item_to_char(var btreasure, int 109 /* quiverb */ , int 1, int 0)
call add_item_to_char(var btreasure, int 14 /* triobow */ , int 1, int 0)
call add_item_to_char(var btreasure, int 43 /* cheese */ , int 1, int 0)
}
._SCRIPT_15
switch(var VAR_69)
{
case 0
if(var VAR_70)
{
var VAR_58 = int 1
/* play the sound 'largegts' */
call play_loaded_sound(int 6, int 0, int 45, int 0)
var VAR_69 ++
}
break
case 1
if(var VAR_58 == int -1)
{
call log_string("finished smacker")
var VAR_59 = int 1
gamevar script_object = var VAR_60
gamevar *smack_object_p+2 -= int 10737418
var VAR_69 ++
}
break
}
._SCRIPT_16
switch(var VAR_64)
{
case 0
if(var VAR_68)
{
var VAR_64 = int 10
}
else
{
var VAR_64 ++
var VAR_66 = call randomize_int(int 100, int 201)
}
var VAR_65 = int 0
break
case 1
if(var VAR_68)
{
var VAR_64 = int 10
}
break
case 10
var creak1_sound_ref = call play_loaded_sound(int 1, int -1, int 45, int 0)
var VAR_65 = int 0
var VAR_64 ++
break
case 11
if(var ! VAR_68)
{
call func_9f(var creak1_sound_ref, int 30)
var VAR_65 = int 0
var VAR_64 = int 1
}
break
}
var VAR_65 ++
._SCRIPT_17
call load_sound_set(int 25)
/* play the sound 'blank' */
call play_loaded_sound(int 1, int -1, int 25, int 0)
var thunrumb_sound_ref = call play_loaded_sound(int 3, int -1, int 25, int 0)
var VAR_1 = int 70
call set_sound_volume(var thunrumb_sound_ref, var VAR_1)
var VAR_0 = int 1
._SCRIPT_18
if(var ! VAR_0)
{
call log_string("random_rain_fx: Rain SFX not initialised! See Marc")
exit_script
}
switch(var VAR_4)
{
case 0
if(var VAR_3)
{
var VAR_6 = int 1
var VAR_4 ++
var VAR_5 = int 0
}
break
case 1
if(var VAR_1 < int 200)
{
var VAR_7 = var VAR_5 % int 2
if(var VAR_7 == int 0)
{
var VAR_1 += var VAR_6
call set_sound_volume(var thunrumb_sound_ref, var VAR_1)
}
}
else
{
var VAR_4 ++
var VAR_5 = int 0
}
break
case 2
if(var VAR_5 > int 150)
{
var VAR_4 ++
var VAR_5 = int 0
}
break
case 3
if(var VAR_1 > int 70)
{
var VAR_7 = var VAR_5 % int 2
if(var VAR_7)
{
var VAR_1 -= var VAR_6
call set_sound_volume(var thunrumb_sound_ref, var VAR_1)
}
}
else
{
var VAR_3 = int 0
var VAR_4 = int 0
var VAR_5 = int 0
}
break
}
execute SCRIPT_19
execute SCRIPT_20
var VAR_5 ++
._SCRIPT_19
switch(var VAR_9)
{
case 0
var VAR_10 = int 0
var VAR_11 = call randomize_int(int 1200, int 1801)
var VAR_9 ++
break
case 1
if(var VAR_10 > var VAR_11)
{
var thunstrk_sound_ref = call play_loaded_sound(int 4, int 0, int 25, int 0)
call set_sound_volume(var thunstrk_sound_ref, call randomize_int(int 100, int 201))
call func_11a(var thunstrk_sound_ref, call randomize_int(int 0, int 128))
if(var ! VAR_3)
{
var VAR_3 = int 1
}
var VAR_9 ++
var VAR_10 = int 0
}
break
case 2
if(var VAR_10 > int 200)
{
var VAR_9 = int 0
var VAR_10 = int 0
}
break
}
var VAR_10 ++
._SCRIPT_20
switch(var VAR_13)
{
case 0
if(gamevar scene_counter > int 600)
{
var VAR_13 ++
}
break
case 1
var VAR_14 = int 0
call reset_local_timer()
var VAR_16 = call randomize_int(int 400, int 601)
var VAR_13 ++
break
case 2
if(call is_local_timer_greater_than(var VAR_16))
{
call apply_effect_on_char(gamevar misc_fx_scripts, int 6, int 0, int 0)
call reset_local_timer()
var VAR_17 = int 255
var VAR_16 = call randomize_int(int 1, int 31)
var VAR_14 = int 0
var VAR_13 ++
}
break
case 3
if(call is_local_timer_greater_than(var VAR_16))
{
var VAR_17 -= int 4 * var VAR_16
var verwind_sound_ref = call play_loaded_sound(int 5, int 0, int 25, int 0)
call set_sound_volume(var verwind_sound_ref, var VAR_17)
var VAR_16 = int 255 - var VAR_17
var VAR_14 = int 0
var VAR_13 ++
}
break
case 4
if(var VAR_14 > var VAR_16)
{
var verwind_sound_ref = call play_loaded_sound /* 'thunstrk' */ (int 4, int 0, int 25, int 0)
call set_sound_volume(var verwind_sound_ref, var VAR_17)
if(var ! VAR_3)
{
var VAR_3 = int 1
}
var VAR_13 ++
var VAR_14 = int 0
}
break
case 5
if(var VAR_14 > int 100)
{
var VAR_13 = int 1
var VAR_14 = int 0
}
break
}
var VAR_14 ++