-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathscript_18eb520705898614.gsc
2657 lines (2573 loc) · 63 KB
/
script_18eb520705898614.gsc
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
989
990
991
992
993
994
995
996
997
998
999
1000
// Decompiled by Serious. Credits to Scoba for his original tool, Cerberus, which I heavily upgraded to support remaining features, other games, and other platforms.
#using scripts\zm\zm_mansion_util.gsc;
#using scripts\zm\zm_mansion_pap_quest.gsc;
#using scripts\zm\ai\zm_ai_nosferatu.gsc;
#using script_387eab232fe22983;
#using scripts\zm_common\zm_zonemgr.gsc;
#using scripts\zm_common\zm_vo.gsc;
#using scripts\zm_common\zm_ui_inventory.gsc;
#using scripts\zm_common\zm_utility.gsc;
#using scripts\zm_common\zm_unitrigger.gsc;
#using scripts\zm_common\zm_transformation.gsc;
#using scripts\zm_common\zm_sq.gsc;
#using scripts\zm_common\zm_powerups.gsc;
#using scripts\zm_common\zm_characters.gsc;
#using scripts\zm_common\zm_audio.gsc;
#using scripts\zm\ai\zm_ai_bat.gsc;
#using scripts\zm_common\zm_score.gsc;
#using scripts\zm_common\zm_customgame.gsc;
#using scripts\core_common\lui_shared.gsc;
#using scripts\core_common\scene_shared.gsc;
#using scripts\core_common\vehicle_shared.gsc;
#using scripts\core_common\values_shared.gsc;
#using scripts\core_common\util_shared.gsc;
#using scripts\core_common\spawner_shared.gsc;
#using scripts\core_common\struct.gsc;
#using scripts\core_common\math_shared.gsc;
#using scripts\core_common\flag_shared.gsc;
#using scripts\core_common\exploder_shared.gsc;
#using scripts\core_common\clientfield_shared.gsc;
#using scripts\core_common\callbacks_shared.gsc;
#using scripts\core_common\array_shared.gsc;
#namespace namespace_b6ca3ccc;
/*
Name: init
Namespace: namespace_b6ca3ccc
Checksum: 0x3953A79C
Offset: 0x628
Size: 0x2BC
Parameters: 0
Flags: Linked
*/
function init()
{
clientfield::register("scriptmover", "" + #"falling_leaves", 8000, 1, "int");
clientfield::register("scriptmover", "" + #"hash_34321e7ca580e772", 8000, 1, "int");
clientfield::register("scriptmover", "" + #"stick_fire", 8000, 2, "int");
clientfield::register("scriptmover", "" + #"stone_rise", 8000, 1, "counter");
clientfield::register("toplayer", "" + #"player_dragged", 8000, 1, "int");
clientfield::register("toplayer", "" + #"hash_4be98315796ad666", 8000, 1, "int");
clientfield::register("allplayers", "" + #"sacrifice_player", 8000, 1, "int");
clientfield::register("allplayers", "" + #"hash_30aa04edc476253f", 8000, 1, "int");
register_steps();
init_flags();
function_c6e2a4fd();
if(zm_utility::is_ee_enabled())
{
if(zm_custom::function_901b751c(#"hash_3c5363541b97ca3e") && zm_custom::function_901b751c(#"zmpapenabled") != 2)
{
level thread start_stick_man();
level thread function_2c554640();
}
}
}
/*
Name: function_c6e2a4fd
Namespace: namespace_b6ca3ccc
Checksum: 0x725A58BC
Offset: 0x8F0
Size: 0xCC
Parameters: 0
Flags: Linked
*/
function function_c6e2a4fd()
{
level.var_d70578ff = [];
level.player_out_of_playable_area_override = &function_8b12e689;
var_65c9997c = getent("health_stone", "targetname");
var_65c9997c setinvisibletoall();
var_65c9997c.v_start_org = var_65c9997c.origin;
var_fe0f27ef = getentarray("living_tree", "targetname");
array::thread_all(var_fe0f27ef, &function_7c9b48a9);
}
/*
Name: init_flags
Namespace: namespace_b6ca3ccc
Checksum: 0x5B087673
Offset: 0x9C8
Size: 0x1E4
Parameters: 0
Flags: Linked
*/
function init_flags()
{
level flag::init(#"portrait_found");
level flag::init(#"stick_done");
level flag::init(#"stick_ready");
level flag::init(#"stick_drag");
level flag::init(#"stick_rise");
level flag::init(#"stick_hide");
level flag::init(#"hash_7ffc33bb45377f5e");
level flag::init(#"stone_visible");
level flag::init(#"cemetery_defend");
level flag::init(#"hash_684b700932f4018f");
level flag::init(#"hash_6100d5ec10bed5cc");
level flag::init(#"hash_12f4b41ff140e181");
level flag::init(#"hash_6a70f9021505a71e");
level flag::init(#"cemetery_done");
level flag::init(#"cemetery_open");
}
/*
Name: start_stick_man
Namespace: namespace_b6ca3ccc
Checksum: 0x364F0987
Offset: 0xBB8
Size: 0x44
Parameters: 0
Flags: Linked
*/
function start_stick_man()
{
level flag::wait_till(#"open_pap");
zm_sq::start(#"hash_578d0d7709a00e6e");
}
/*
Name: register_steps
Namespace: namespace_b6ca3ccc
Checksum: 0xCFC214B3
Offset: 0xC08
Size: 0x124
Parameters: 0
Flags: Linked
*/
function register_steps()
{
zm_sq::register(#"hash_578d0d7709a00e6e", #"step_1", #"hash_6e38611b5382ee7f", &function_cdfe68a2, &cleanup_step_1);
zm_sq::register(#"hash_578d0d7709a00e6e", #"step_2", #"hash_6e38621b5382f032", &function_a03f8d25, &cleanup_step_2);
zm_sq::register(#"hash_578d0d7709a00e6e", #"step_3", #"hash_6e38631b5382f1e5", &function_aa79a199, &cleanup_step_3);
}
/*
Name: function_cdfe68a2
Namespace: namespace_b6ca3ccc
Checksum: 0xD3C7674E
Offset: 0xD38
Size: 0x17C
Parameters: 1
Flags: Linked
*/
function function_cdfe68a2(var_a276c861)
{
var_65c9997c = getent("gazing_stone_cellar", "targetname");
var_47323b73 = var_65c9997c zm_unitrigger::create(undefined, 64, &function_55b79f54);
var_47323b73.str_loc = "greenhouse";
var_47323b73.var_f0e6c7a2 = var_65c9997c;
if(!var_47323b73.var_f0e6c7a2 flag::exists(#"flag_gazing_stone_in_use"))
{
var_47323b73.var_f0e6c7a2 flag::init(#"flag_gazing_stone_in_use");
}
if(!var_a276c861)
{
level flag::wait_till(#"gazed_greenhouse");
level zm_ui_inventory::function_7df6bb60(#"hash_7b00694a8b213123", 1);
exploder::exploder("fxexp_leaves_fall_dead");
level thread init_sticks();
level flag::wait_till(#"stick_done");
}
}
/*
Name: cleanup_step_1
Namespace: namespace_b6ca3ccc
Checksum: 0xDADE489E
Offset: 0xEC0
Size: 0x28C
Parameters: 2
Flags: Linked
*/
function cleanup_step_1(var_a276c861, var_19e802fa)
{
level flag::set(#"gazed_greenhouse");
level flag::set(#"stick_done");
e_bush = getent("burning_man_shrub", "targetname");
if(isdefined(e_bush))
{
e_bush delete();
}
if(var_a276c861 || var_19e802fa)
{
level notify(#"hash_425e8c53dcecb85d");
s_scene = struct::get(#"p8_fxanim_zm_man_wm_01_bundle", "scriptbundlename");
s_scene thread scene::play("Shot 1");
var_fe0f27ef = getentarray("living_tree", "targetname");
foreach(var_3303f46 in var_fe0f27ef)
{
var_3303f46 clientfield::set("" + #"hash_34321e7ca580e772", 0);
var_3303f46 clientfield::set("" + #"falling_leaves", 1);
if(isdefined(var_3303f46.var_8be24fed))
{
var_3303f46.var_8be24fed delete();
}
}
array::run_all(getentarray("stick_man_stick", "script_noteworthy"), &delete);
hidemiscmodels("misc_sticks");
}
}
/*
Name: function_55b79f54
Namespace: namespace_b6ca3ccc
Checksum: 0x9DBF78F1
Offset: 0x1158
Size: 0x198
Parameters: 0
Flags: Linked
*/
function function_55b79f54()
{
while(true)
{
waitresult = undefined;
waitresult = self waittill(#"trigger");
player = waitresult.activator;
if(!isalive(player) || !zm_utility::can_use(player) || (isdefined(player.var_d049df11) && player.var_d049df11) || (distancesquared(groundtrace(player.origin, player.origin + (vectorscale((0, 0, -1), 128)), 0, player)[#"position"], player.origin)) > 16)
{
continue;
}
level thread mansion_pap::function_9e7129d2(player, self.stub.var_f0e6c7a2, 15, "stick");
player thread mansion_util::function_58dfa337(15);
player thread mansion_util::function_a113df82(18);
level flag::set(#"gazed_greenhouse");
}
}
/*
Name: init_sticks
Namespace: namespace_b6ca3ccc
Checksum: 0xF3A59301
Offset: 0x12F8
Size: 0x16C
Parameters: 0
Flags: Linked
*/
function init_sticks()
{
var_e036b66c = getentarray("stick_man_stick", "script_noteworthy");
foreach(var_1f23d8cf in var_e036b66c)
{
var_1f23d8cf.s_form = struct::get(var_1f23d8cf.target);
var_1f23d8cf.s_fall = struct::get(var_1f23d8cf.targetname);
var_1f23d8cf thread function_e8f819b0();
}
level.n_sticks = 0;
level waittill(#"hash_68c10418963ac1fc");
array::run_all(getentarray("stick_man_stick", "script_noteworthy"), &delete);
hidemiscmodels("misc_sticks");
}
/*
Name: function_e8f819b0
Namespace: namespace_b6ca3ccc
Checksum: 0xF62C2E90
Offset: 0x1470
Size: 0x1DA
Parameters: 0
Flags: Linked
*/
function function_e8f819b0()
{
level endon(#"stick_done");
self.health = 99999;
self val::set("stick", "takedamage", 1);
self solid();
while(true)
{
s_notify = undefined;
s_notify = self waittill(#"damage");
self.health = self.health + s_notify.amount;
if(isplayer(s_notify.attacker))
{
self stoploopsound();
self hide();
str_scene = ("p8_fxanim_zm_man_wm_stick_0" + self.script_int) + "_bundle";
s_scene = struct::get(str_scene, "scriptbundlename");
s_scene scene::play("Shot 1");
s_target = struct::get(self.target);
var_47323b73 = s_target zm_unitrigger::create(undefined, (92, 92, 100), &function_ff1dea25);
var_47323b73.var_1f23d8cf = self;
break;
}
}
}
/*
Name: function_ff1dea25
Namespace: namespace_b6ca3ccc
Checksum: 0xA6AF9C4B
Offset: 0x1658
Size: 0xB8
Parameters: 0
Flags: Linked
*/
function function_ff1dea25()
{
level endon(#"cemetery_done");
while(true)
{
waitresult = undefined;
waitresult = self waittill(#"trigger");
player = waitresult.activator;
if(!zm_utility::can_use(player))
{
continue;
}
level thread function_1ca135cf(self.stub.var_1f23d8cf.script_int);
zm_unitrigger::unregister_unitrigger(self.stub);
}
}
/*
Name: function_1ca135cf
Namespace: namespace_b6ca3ccc
Checksum: 0x93E9824E
Offset: 0x1718
Size: 0x1A4
Parameters: 1
Flags: Linked
*/
function function_1ca135cf(n_int)
{
level.n_sticks++;
if(level.n_sticks >= 5)
{
level flag::set(#"stick_done");
}
str_scene = ("p8_fxanim_zm_man_wm_stick_0" + n_int) + "_bundle";
scene::add_scene_func(str_scene, &function_4b15ba35, "Shot 2");
s_scene = struct::get(str_scene, "scriptbundlename");
s_scene scene::play("Shot 2");
if(level.n_sticks == 1)
{
e_bush = getent("burning_man_shrub", "targetname");
e_bush clientfield::set("" + #"stick_fire", 1);
wait(1);
e_bush clientfield::set("" + #"stick_fire", 0);
waitframe(1);
e_bush delete();
}
}
/*
Name: function_4b15ba35
Namespace: namespace_b6ca3ccc
Checksum: 0xF1386E2C
Offset: 0x18C8
Size: 0x8C
Parameters: 1
Flags: Linked
*/
function function_4b15ba35(a_ents)
{
level endon(#"hash_7ffc33bb45377f5e");
level waittill(#"hash_68c10418963ac1fc", #"hash_425e8c53dcecb85d");
if(isdefined(a_ents[#"prop 1"]))
{
a_ents[#"prop 1"] delete();
}
}
/*
Name: function_7c9b48a9
Namespace: namespace_b6ca3ccc
Checksum: 0xFA0E54D7
Offset: 0x1960
Size: 0x19C
Parameters: 0
Flags: Linked
*/
function function_7c9b48a9()
{
level endon(#"stick_done");
level flag::wait_till(#"all_players_spawned");
self clientfield::set("" + #"hash_34321e7ca580e772", 1);
level flag::wait_till(#"gazed_greenhouse");
self.var_8be24fed = spawn("trigger_radius_new", self.origin, 0, 641);
self.var_8be24fed endon(#"death");
if(isdefined(self.script_noteworthy) && self.script_noteworthy == "entrance_left_t")
{
self function_f2071006();
}
else
{
self.var_8be24fed waittill(#"trigger");
}
self clientfield::set("" + #"hash_34321e7ca580e772", 0);
self clientfield::set("" + #"falling_leaves", 1);
self.var_8be24fed delete();
}
/*
Name: function_f2071006
Namespace: namespace_b6ca3ccc
Checksum: 0xAA1FA6CE
Offset: 0x1B08
Size: 0xCE
Parameters: 0
Flags: Linked
*/
function function_f2071006()
{
self.var_8be24fed endon(#"death");
while(true)
{
s_result = undefined;
s_result = self.var_8be24fed waittill(#"trigger");
if(s_result.activator util::is_looking_at(self, 0.61, 1))
{
return;
}
if(distance2dsquared(s_result.activator.origin, self.origin) <= 242064)
{
return;
}
}
}
/*
Name: function_a03f8d25
Namespace: namespace_b6ca3ccc
Checksum: 0xEF4E0F5D
Offset: 0x1BE0
Size: 0x184
Parameters: 1
Flags: Linked
*/
function function_a03f8d25(var_a276c861)
{
level zm_ui_inventory::function_7df6bb60(#"hash_7b006a4a8b2132d6", 1);
if(!var_a276c861)
{
callback::on_disconnect(&function_44a7951d);
callback::on_player_killed(&function_44a7951d);
callback::on_laststand(&function_44a7951d);
level function_2345b68a();
level thread function_d8ca90b7();
level flag::wait_till(#"stick_rise");
}
level zm_ui_inventory::function_7df6bb60(#"hash_7b006b4a8b213489", 1);
if(!var_a276c861)
{
level thread function_9e01297e();
level thread stick_guide();
level thread function_6f6fef08();
level flag::wait_till(#"stone_visible");
}
}
/*
Name: cleanup_step_2
Namespace: namespace_b6ca3ccc
Checksum: 0x9F73E9BA
Offset: 0x1D70
Size: 0x1DC
Parameters: 2
Flags: Linked
*/
function cleanup_step_2(var_5ea5c94d, ended_early)
{
level flag::set(#"stick_rise");
level flag::set(#"stone_visible");
if(isdefined(level.stick_player))
{
level.stick_player setvisibletoall();
}
if(isdefined(level.e_guide) && isdefined(level.e_guide.mdl_head))
{
if(isdefined(level.e_guide.var_c176969a))
{
level.e_guide.var_c176969a scene::stop();
level.e_guide.var_c176969a delete();
}
level.e_guide scene::stop();
level.e_guide.mdl_head delete();
level.e_guide delete();
}
if(var_5ea5c94d || ended_early)
{
level thread function_6f6fef08();
}
if(!var_5ea5c94d)
{
callback::remove_on_disconnect(&function_44a7951d);
callback::remove_on_player_killed(&function_44a7951d);
callback::remove_on_laststand(&function_44a7951d);
}
}
/*
Name: function_2345b68a
Namespace: namespace_b6ca3ccc
Checksum: 0xCBE6F55E
Offset: 0x1F58
Size: 0x3FC
Parameters: 0
Flags: Linked, Private
*/
function private function_2345b68a()
{
foreach(var_24b5be21 in level.var_d70578ff)
{
if(isdefined(var_24b5be21.s_trig.s_unitrigger))
{
level thread zm_unitrigger::unregister_unitrigger(var_24b5be21.s_trig.s_unitrigger);
}
var_24b5be21.mdl_bd setmodel(var_24b5be21.var_3916fb8b);
}
var_6adbf325 = getent("pic_gypsy", "targetname");
var_1b2ca394 = getent("pic_brigadier", "targetname");
var_3c9ce3a9 = getent("pic_butler", "targetname");
var_36ebb951 = getent("pic_gunslinger", "targetname");
level.stick_player = function_8a51807c();
level.stick_player thread function_4aa24b78();
level.stick_player thread function_c5c7d880();
switch(level.stick_player.str_name)
{
case "pic_gypsy":
{
s_loc = var_6adbf325.s_loc;
s_trig = struct::get(s_loc.target);
var_24b5be21 = var_6adbf325;
break;
}
case "pic_brigadier":
{
s_loc = var_1b2ca394.s_loc;
s_trig = struct::get(s_loc.target);
var_24b5be21 = var_1b2ca394;
break;
}
case "pic_butler":
{
s_loc = var_3c9ce3a9.s_loc;
s_trig = struct::get(s_loc.target);
var_24b5be21 = var_3c9ce3a9;
break;
}
case "pic_gunslinger":
{
s_loc = var_36ebb951.s_loc;
s_trig = struct::get(s_loc.target);
var_24b5be21 = var_36ebb951;
break;
}
}
level.stick_player.s_portrait = s_loc;
var_24b5be21.mdl_bd setmodel(#"p8_zm_headstone_engraving_1912");
level.var_76c1632f = s_trig zm_unitrigger::create(undefined, (64, 64, 100), &function_6ae66179);
level.var_76c1632f.s_portrait = s_loc;
/#
sphere(s_loc.origin + vectorscale((0, 0, 1), 60), 24, (0, 1, 1), 1, 0, 16, 10000);
#/
}
/*
Name: function_44a7951d
Namespace: namespace_b6ca3ccc
Checksum: 0x30448702
Offset: 0x2360
Size: 0xD4
Parameters: 0
Flags: Linked, Private
*/
function private function_44a7951d()
{
if(self === level.stick_player)
{
self notify(#"hash_1544918b5f670dae");
self setvisibletoall();
if(isdefined(self.e_linkto))
{
self.e_linkto delete();
}
if(isdefined(level.var_76c1632f))
{
level zm_unitrigger::unregister_unitrigger(level.var_76c1632f);
level.var_76c1632f = undefined;
}
self thread function_a0a113c9("death");
level thread function_36d70cbd();
}
}
/*
Name: function_4aa24b78
Namespace: namespace_b6ca3ccc
Checksum: 0x4D72E0C6
Offset: 0x2440
Size: 0xA4
Parameters: 0
Flags: Linked, Private
*/
function private function_4aa24b78()
{
self notify("5a517bbed613c3ee");
self endon("5a517bbed613c3ee");
level endon(#"stone_visible");
self endon(#"player_downed", #"death", #"hash_1544918b5f670dae");
if(self === level.stick_player)
{
self waittill(#"_zombie_game_over");
self thread function_a0a113c9("death");
}
}
/*
Name: function_36d70cbd
Namespace: namespace_b6ca3ccc
Checksum: 0xC5659002
Offset: 0x24F0
Size: 0x4CC
Parameters: 0
Flags: Linked, Private
*/
function private function_36d70cbd()
{
self notify("2c7398c281ee6695");
self endon("2c7398c281ee6695");
level endon(#"stone_visible");
if(level flag::get(#"stick_drag"))
{
level flag::clear(#"stick_drag");
}
if(isdefined(level.var_fb97a4cf))
{
if(level.var_fb97a4cf clientfield::get("" + #"stick_fire"))
{
level.var_fb97a4cf clientfield::set("" + #"stick_fire", 0);
}
level.var_fb97a4cf delete();
level.var_fb97a4cf = undefined;
}
level.stick_player = undefined;
level function_2345b68a();
var_65c9997c = getent("health_stone", "targetname");
if(var_65c9997c.origin !== var_65c9997c.v_start_org)
{
var_65c9997c.origin = var_65c9997c.v_start_org;
}
if(level flag::get(#"hash_7ffc33bb45377f5e"))
{
level flag::clear(#"hash_7ffc33bb45377f5e");
}
if(isdefined(level.var_d2ff3b06))
{
zm_unitrigger::unregister_unitrigger(level.var_d2ff3b06);
level.var_d2ff3b06 = undefined;
}
if(isdefined(level.var_e34d55ef) && isdefined(level.var_e34d55ef.var_71c444c7))
{
level.var_e34d55ef setmodel(level.var_e34d55ef.var_71c444c7);
}
s_scene = struct::get(#"p8_fxanim_zm_man_wm_01_bundle", "scriptbundlename");
if(isdefined(s_scene))
{
s_scene thread scene::play("Shot 1");
}
if(level flag::get(#"stick_rise"))
{
level flag::clear(#"stick_rise");
if(level flag::get(#"stick_hide"))
{
level flag::clear(#"stick_hide");
}
level zm_ui_inventory::function_7df6bb60(#"hash_7b006b4a8b213489", 0);
level thread function_d8ca90b7();
if(isdefined(level.e_guide) && isdefined(level.e_guide.mdl_head))
{
if(isdefined(level.e_guide.var_c176969a))
{
level.e_guide.var_c176969a scene::stop();
level.e_guide.var_c176969a delete();
}
level.e_guide scene::stop();
level.e_guide.mdl_head delete();
level.e_guide delete();
}
level flag::wait_till(#"stick_rise");
level zm_ui_inventory::function_7df6bb60(#"hash_7b006b4a8b213489", 1);
level thread function_9e01297e();
level thread stick_guide();
}
else
{
level thread function_d8ca90b7();
}
}
/*
Name: function_8a51807c
Namespace: namespace_b6ca3ccc
Checksum: 0x1B746967
Offset: 0x29C8
Size: 0x166
Parameters: 0
Flags: Linked, Private
*/
function private function_8a51807c()
{
level flag::wait_till(#"all_players_spawned");
player = undefined;
a_players = getplayers();
if(a_players.size > 1)
{
var_5eb47b1d = util::get_active_players();
player = array::random(var_5eb47b1d);
}
if(!isdefined(player))
{
player = a_players[0];
}
switch(player.characterindex)
{
case 9:
{
player.str_name = "pic_gypsy";
break;
}
case 10:
{
player.str_name = "pic_brigadier";
break;
}
case 11:
{
player.str_name = "pic_gunslinger";
break;
}
case 12:
{
player.str_name = "pic_butler";
break;
}
}
return player;
}
/*
Name: function_d8ca90b7
Namespace: namespace_b6ca3ccc
Checksum: 0xBDEA5EB6
Offset: 0x2B38
Size: 0x1E8
Parameters: 0
Flags: Linked, Private
*/
function private function_d8ca90b7()
{
level endon(#"stick_drag");
level.stick_player endon(#"disconnect", #"hash_1544918b5f670dae");
level flag::wait_till(#"hash_7ffc33bb45377f5e");
while(true)
{
level flag::wait_till(#"stick_ready");
s_loc = struct::get("stick_drag_loc");
a_e_drag = getentarray("entity_drag", "targetname");
e_drag = array::get_all_closest(s_loc.origin, a_e_drag)[0];
if(isdefined(e_drag) && distance(e_drag.origin, s_loc.origin) <= s_loc.radius)
{
var_7a7793c6 = struct::get("wicker_fire_pos", "targetname");
level.var_fb97a4cf = util::spawn_model("tag_origin", var_7a7793c6.origin);
util::wait_network_frame();
if(isdefined(level.var_fb97a4cf))
{
level.var_fb97a4cf thread function_959fcbff(level.stick_player);
return;
}
}
wait(1);
}
}
/*
Name: function_959fcbff
Namespace: namespace_b6ca3ccc
Checksum: 0x908EEB
Offset: 0x2D28
Size: 0xBA4
Parameters: 1
Flags: Linked, Private
*/
function private function_959fcbff(player)
{
player endon(#"disconnect");
level flag::set(#"stick_drag");
self clientfield::set("" + #"stick_fire", 2);
if(isdefined(level.var_d2ff3b06))
{
zm_unitrigger::unregister_unitrigger(level.var_d2ff3b06);
level.var_d2ff3b06 = undefined;
}
wait(2);
level.var_e34d55ef setmodel(#"p8_zm_man_dead_tree_branches_burned");
if(player zm_characters::is_character(array(#"hash_5ebf024e1559c04a")))
{
player thread function_3ce20299();
}
else
{
player thread function_eabb32ca();
}
player val::set(#"hash_3c30825a658c87fd", "show_hud", 0);
player playsound(#"hash_64796b1ee9c1a0df");
player clientfield::set_to_player("" + #"hash_4be98315796ad666", 1);
player thread lui::screen_fade_out(0.9, (0.8, 0.24, 0.15));
if(isdefined(level.var_9661fac0))
{
level.var_9661fac0 = undefined;
var_3add8e25 = struct::get("s_stick_scene", "targetname");
var_3add8e25 scene::stop(level.var_9661fac0);
}
if(!isdefined(player.e_linkto))
{
player.e_linkto = util::spawn_model("tag_origin", player.origin, player.angles);
player playerlinkto(player.e_linkto, "tag_origin", 0, 0, 0, 0, 0);
}
player.e_linkto clientfield::set("" + #"hash_69b312bcaae6308b", 1);
player clientfield::set("" + #"hash_30aa04edc476253f", 1);
player.e_linkto movez(-80, 1.5);
wait(0.375);
a_players = getplayers();
arrayremovevalue(a_players, player);
foreach(e_player in a_players)
{
player setinvisibletoplayer(e_player, 1);
}
player thread function_25a79bc1();
player.e_linkto waittilltimeout(1.5 - 0.375, #"movedone");
player.e_linkto clientfield::set("" + #"hash_69b312bcaae6308b", 0);
player clientfield::set("" + #"hash_30aa04edc476253f", 0);
s_pos = struct::get("wm_ht_pos", "targetname");
player.e_linkto.origin = s_pos.origin;
player setorigin(player.e_linkto.origin);
player.e_linkto.angles = s_pos.angles;
player setplayerangles(player.e_linkto.angles);
player thread function_3b71b7a7();
self clientfield::set("" + #"stick_fire", 0);
self delete();
level flag::clear(#"stick_drag");
s_pos = struct::get("wm_ht_pos", "targetname");
s_end_pos = struct::get(s_pos.target, "targetname");
if(!isdefined(player.e_linkto))
{
player.e_linkto = util::spawn_model("tag_origin", player.origin, player.angles);
player playerlinkto(player.e_linkto, "tag_origin", 0, 0, 0, 0, 0);
}
exploder::exploder("exp_lgt_hell_tunnel");
player thread lui::screen_fade_in(1, (0.8, 0.24, 0.15));
player.e_linkto moveto(s_end_pos.origin, 3);
player.e_linkto rotateroll(120, 3);
player thread function_e84d4271();
wait(2);
player thread lui::screen_fade_out(1, (0.8, 0.24, 0.15));
level waittilltimeout(10, #"hash_132b5b79b9aeaf9e");
player notify(#"tunnel_complete");
level flag::set(#"stick_rise");
if(!isdefined(player.e_linkto))
{
player.e_linkto = util::spawn_model("tag_origin", player.origin, player.angles);
player playerlinkto(player.e_linkto, "tag_origin", 0, 0, 0, 0, 0);
}
s_rise = struct::get(player.s_portrait.target);
player clientfield::set_to_player("" + #"hash_4be98315796ad666", 0);
player clientfield::set_to_player("" + #"player_dragged", 1);
player.var_7ebdb2c9 = 1;
player.e_linkto.origin = s_rise.origin + (vectorscale((0, 0, -1), 32));
player.e_linkto.angles = s_rise.angles;
player thread lui::screen_fade_in(1.35, (0.8, 0.24, 0.15));
player.e_linkto moveto(s_rise.origin, 1.5);
player.e_linkto waittilltimeout(1.5, #"movedone");
player unlink();
player.e_linkto delete();
player.s_portrait struct::delete();
player val::reset(#"hash_3c30825a658c87fd", "show_hud");
player.b_stuck = undefined;
player.var_f22c83f5 = undefined;
player val::reset("stick_man", "takedamage");
player val::reset("stick_man", "ignoreme");
player enableweapons();
player allowcrouch(1);
player allowprone(1);
level flag::clear(#"stick_ready");
level flag::set(#"stick_hide");
exploder::stop_exploder("exp_lgt_hell_tunnel");
player thread function_614e461();
}
/*
Name: function_3b71b7a7
Namespace: namespace_b6ca3ccc
Checksum: 0xF5C3B1CC
Offset: 0x38D8
Size: 0xE0
Parameters: 0
Flags: Linked, Private
*/
function private function_3b71b7a7()
{
self endon(#"disconnect");
self setvisibletoall();
wait(0.25);
a_players = getplayers();
arrayremovevalue(a_players, self);
foreach(e_player in a_players)
{
self setinvisibletoplayer(e_player, 1);
}
}
/*
Name: function_25a79bc1
Namespace: namespace_b6ca3ccc
Checksum: 0xE02BC902
Offset: 0x39C0
Size: 0x154
Parameters: 0
Flags: Linked, Private
*/
function private function_25a79bc1()
{
level endon(#"stone_visible");
self endon(#"player_downed", #"death", #"hash_1544918b5f670dae");
while(true)
{
self waittill(#"fasttravel_over", #"hash_3e4335abc3d58a0b", #"hash_55489b8cb6c75352");
if(self !== level.stick_player)
{
return;
}
a_players = getplayers();
arrayremovevalue(a_players, self);
foreach(e_player in a_players)
{
self setinvisibletoplayer(e_player, 1);
}
}
}
/*
Name: function_3ce20299
Namespace: namespace_b6ca3ccc
Checksum: 0xE10B3BCC
Offset: 0x3B20
Size: 0xA0
Parameters: 0
Flags: Linked, Private
*/
function private function_3ce20299()
{
self endon(#"death");
self zm_vo::vo_say(#"hash_39bc8bd7eaa531d5", 1.5, 1, 9999, 1, 1, 1);
self zm_vo::vo_say(#"hash_7f6178afe0059ebf", 0, 1, 9999, 1, 1, 1);
level notify(#"hash_132b5b79b9aeaf9e");
}
/*
Name: function_eabb32ca
Namespace: namespace_b6ca3ccc
Checksum: 0x365A2AC7
Offset: 0x3BC8
Size: 0xA8
Parameters: 0
Flags: Linked, Private
*/
function private function_eabb32ca()
{
self endon(#"death");
n_char_index = self zm_characters::function_d35e4c92();
self.var_aa24164d = (#"hash_74d6f512c6c0b04c" + self.characterindex) + "_0";
self zm_vo::vo_say(self.var_aa24164d, 1.5, 1, 9999, 1, 1, 1);
level notify(#"hash_132b5b79b9aeaf9e");
}
/*
Name: function_9e01297e
Namespace: namespace_b6ca3ccc
Checksum: 0xB30B56EC
Offset: 0x3C78
Size: 0x228
Parameters: 0
Flags: Linked, Private
*/
function private function_9e01297e()
{
var_7e2d2356 = getent("stick_guide", "targetname");
while(!isdefined(level.e_guide))