-
Notifications
You must be signed in to change notification settings - Fork 0
/
B_EX420.bdscript
20676 lines (20674 loc) · 371 KB
/
B_EX420.bdscript
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
---
WorkSize: 4512
StackSize: 512
TempSize: 512
Triggers:
- Key: 17
Addr: OBJ_ANMATR_CALLBACK
- Key: 11
Addr: REACTION_CALLBACK
- Key: 16
Addr: OBJ_ANMATR_EFFECT
- Key: 15
Addr: OBJ_ATTACK
- Key: 6
Addr: OBJ_DAMAGE
- Key: 13
Addr: OBJ_FALL
- Key: 1
Addr: OBJ_MAIN
- Key: 0
Addr: OBJ_INIT
Name: b_ex420
---
; codeLabels:
; codeRevealer: -l 687 -l 1245 -l 1430 -l 1662 -l 1695 -l 1706 -l 3172 -l 3584 -l 4111 -l 4772 -l 5760 -l 5948 -l 6748 -l 7785 -l 7786 -l 7852 -l 8130 -l 8744 -l 9322 -l 9404 -l 13575 -l 13822 -l 13883 -l 13884 -l 13902 -l 13908 -l 13923 -l 14005 -l 14202 -l 14261 -l 14278 -l 14388 -l 14401 -l 14533 -l 14782 -l 14875 -l 14935 -l 14955 -l 15056 -l 15057 -l 15136 -l 15215 -l 15223 -l 15231 -l 15239 -l 15247 -l 15429 -l 15441 -l 15601 -l 15618 -l 15635 -l 15652 -l 15922 -l 15996 -l 16194 -l 16301 -l 16451 -l 16465 -l 16540 -l 16615 -l 16763 -l 16764 -l 16792 -l 17131 -l 17142 -l 17207 -l 17342 -l 17407 -l 17444 -l 17779 -l 17790 -l 18092 -l 18133 -l 18140 -l 18155 -l 18170 -l 18389 -l 18401 -l 18505 -l 18587 -l 18679 -l 19103 -l 19187 -l 19611 -l 19612 -l 19653 -l 20259 -l 20323 -l 21062 -l 21806 -l 22306 -l 22364 -l 22608 -l 22797 -l 23040 -l 23283 -l 23566 -l 23762 -l 24050 -l 24558 -l 24640 -l 25059 -l 25300 -l 25333 -l 25363 -l 25455 -l 25548 -l 25621 -l 25723 -l 25802 -l 25812 -l 25996 -l 26006 -l 26122 -l 26230 -l 26295 -l 26667 -l 26900 -l 27114 -l 27328 -l 27571 -l 27811 -l 27871 -l 28096 -l 28135 -l 28325 -l 28539 -l 28693 -l 28764 -l 28943 -l 29020 -l 29028 -l 29070 -l 29112 -l 29150 -l 29229 -l 29473 -l 29494 -l 29511 -l 29790 -l 29901 -l 30061 -l 30074 -l 30122 -l 30170 -l 30218 -l 30266 -l 30314 -l 30362 -l 30410 -l 30458 -l 30506 -l 30559 -l 30612 -l 30665 -l 34702 -l 35626 -l 35696 -l 35766 -l 37153 -l 37299 -l 38389 -l 38625 -l 38699 -l 38773 -l 38782 -l 39373
section .text
OBJ_ANMATR_CALLBACK:
popToSp 0
popToSp 4
popToSp 8
pushFromFSp 4
pushFromPAi L39722 ; ___ai INT (L39722)
syscall 0, 0 ; trap_puti (2 in, 0 out)
pushFromFSp 4
dup
pushImm 10
sub
jz L65
jmp L72
L65:
pushFromPWp W32
gosub32 8, L116
jmp L114
L72:
dup
pushImm 20
sub
jz L81
jmp L94
L81:
pushFromPWp W32
pushImm 272
add
pushFromFSp 0
gosub32 8, L217
jmp L114
L94:
dup
pushImm 30
sub
jz L103
jmp L114
L103:
pushFromPWp W32
pushImm 272
add
gosub32 8, L236
jmp L114
L114:
drop
ret
L116:
popToSp 0
pushFromPSp 16
pushImm 2557
gosub32 16, L167
pushFromPSp 32
pushImmf -120
pushImmf 0
pushImmf 0
pushImmf 1
gosub32 16, L190
pushFromFSp 0
pushImm 176
pushFromPSp 32
syscall 1, 83 ; trap_obj_apply_bone_matrix (3 in, 1 out)
memcpyToSp 16, 48
pushFromPSp 48
memcpyToSp 16, 32
pushFromPSp 16
pushFromPSp 32
syscall 1, 148 ; trap_obj_set_pos (2 in, 0 out)
ret
L167:
popToSp 4
popToSp 0
pushFromFSp 0
pushFromFSp 4
syscall 1, 0 ; trap_sysobj_appear (1 in, 1 out)
gosub32 4, L181
ret
L181:
popToSp 4
popToSp 0
pushFromFSp 4
popToSpVal 4
ret
L190:
popToSp 4
popToSp 8
popToSp 12
popToSp 16
popToSp 0
pushFromFSp 16
popToSpVal 0
pushFromFSp 12
popToSpVal 4
pushFromFSp 8
popToSpVal 8
pushFromFSp 4
popToSpVal 12
ret
L217:
popToSp 4
popToSp 0
pushFromPSpVal 16
pushFromFSp 4
pushImm 1
pushImm 0
syscall 1, 87 ; trap_obj_effect_start_bind (4 in, 1 out)
popToSpVal 0
ret
L236:
popToSp 0
pushImm 1
popToSpVal 32
pushImm 1
popToSpVal 36
ret
REACTION_CALLBACK:
popToSp 0
popToSp 4
popToSp 8
pushFromFSp 4
dup
pushImm 722
sub
jz L266
jmp L283
L266:
pushFromFSp 0
gosub32 8, L299
memcpyToSp 16, 16
pushFromPSp 16
pushFromFSp 8
gosub32 12, L311
jmp L297
L283:
dup
pushImm 723
sub
jz L292
jmp L297
L292:
gosub32 8, L498
jmp L297
L297:
drop
ret
L299:
popToSp 0
pushFromPSp 16
pushFromFSpVal 0
gosub32 12, L181
pushFromPSp 16
ret
L311:
popToSp 0
popToSp 4
pushFromFSp 4
pushImm 2029
pushFromFWp W8
pushImm 0
syscall 2, 10 ; trap_attack_new (4 in, 1 out)
popToSp 8
pushFromFSp 8
pushFromFSp 0
gosub32 8, L415
memcpyToSp 16, 16
pushFromPSp 16
pushImmf 10
pushImmf 10
gosub32 12, L454
memcpyToSp 16, 32
pushFromPSp 32
syscall 0, 4 ; trap_vector_add (2 in, 1 out)
memcpyToSp 16, 48
pushFromPSp 48
syscall 2, 12 ; trap_attack_set_pos (2 in, 0 out)
pushFromFSp 0
syscall 1, 225 ; trap_obj_is_star (1 in, 1 out)
eqz
jz L401
pushFromFSp 4
pushImm 16
pushFromFSp 0
pushImm 1
pushImm 0
syscall 1, 149 ; trap_obj_effect_start_bind_other (5 in, 1 out)
drop
pushFromFSp 8
pushFromFSp 0
pushImm 0
pushImm 0
syscall 2, 17 ; trap_attack_strike (4 in, 0 out)
jmp L401
L401:
pushFromFSp 8
pushImmf 4
pushImmf 0
pushImmf 0
syscall 2, 62 ; trap_attack_set_time (4 in, 0 out)
ret
L415:
popToSp 0
pushFromPSp 16
pushImmf 0
pushImmf 0
pushImmf 0
pushImmf 1
gosub32 12, L190
pushFromFSp 0
pushImm 16385
pushFromPSp 16
syscall 1, 83 ; trap_obj_apply_bone_matrix (3 in, 1 out)
memcpyToSp 16, 32
pushFromPSp 32
memcpyToSp 16, 16
pushFromPSp 16
ret
L454:
popToSp 0
popToSp 4
pushFromPSp 16
pushFromFSp 4
pushFromFSp 0
syscall 0, 18 ; trap_random_range (2 in, 1 out)
pushImmf 0
pushImmf 0
pushImmf 0
gosub32 12, L190
pushFromPSp 16
pushImmf 6.283185
syscall 0, 17 ; trap_random_getf (1 in, 1 out)
syscall 0, 13 ; trap_vector_roty (2 in, 1 out)
memcpyToSp 16, 32
pushFromPSp 32
memcpyToSp 16, 16
pushFromPSp 16
ret
L498:
pushImm 21626
syscall 4, 4 ; trap_mission_information (1 in, 0 out)
pushImm 0
popToWp W4
ret
OBJ_ANMATR_EFFECT:
popToSp 0
popToSp 4
popToSp 8
pushFromFSp 4
dup
pushImm 7
sub
jz L526
jmp L606
L526:
pushFromFSp 8
syscall 1, 201 ; trap_obj_dir (1 in, 1 out)
memcpyToSp 16, 48
pushFromPSp 48
memcpyToSp 16, 16
pushFromPSp 32
pushImmf 1
gosub32 16, L635
pushFromPWp W32
pushImm 188
pushFromPSp 32
syscall 1, 83 ; trap_obj_apply_bone_matrix (3 in, 1 out)
memcpyToSp 16, 48
pushFromPSp 48
memcpyToSp 16, 32
pushFromPWp W32
syscall 2, 23 ; trap_btlobj_target (1 in, 1 out)
syscall 1, 120 ; trap_target_pos (1 in, 1 out)
memcpyToSp 16, 48
pushFromPSp 48
pushFromPSp 32
syscall 0, 5 ; trap_vector_sub (2 in, 1 out)
memcpyToSp 16, 64
pushFromPSp 64
memcpyToSp 16, 32
pushFromPSp 16
pushFromPSp 32
pushImmf 0.174533
syscall 0, 46 ; trap_vector_homing (3 in, 0 out)
pushFromFSp 8
pushFromPSp 16
pushFromFSp 0
gosub32 16, L656
jmp L624
L606:
dup
pushImm 13
sub
jz L615
jmp L624
L615:
pushFromFSp 8
pushFromFSp 0
gosub32 16, L3153
jmp L624
L624:
drop
pushFromFSp 8
pushFromFSp 4
pushFromFSp 0
gosub32 16, L3510
ret
L635:
popToSp 4
popToSp 0
pushFromFSp 0
pushImmf 0
pushImmf 0
pushImmf 0
pushFromFSp 4
gosub32 4, L190
ret
L656:
popToSp 0
popToSp 4
popToSp 8
pushImm 112
pushImm L687
pushFromFSp 8
pushFromFSp 0
gosub32 8, L3122
popToSp 12
pushFromFSp 12
pushImm 80
add
pushFromFSp 4
memcpy 16
ret
D687:
L687:
popToSp 0
pushFromFSp 0
gosub32 4, L705
pushFromFSp 0
gosub32 4, L757
pushFromFSp 0
gosub32 4, L3073
ret
L705:
popToSp 0
pushFromFSp 0
gosub32 4, L723
pushImm 0
popToSpVal 64
pushImm 0
popToSpVal 68
ret
L723:
popToSp 0
pushFromFSpVal 16
pushImm 0
sub
neqz
dup
jz L740
pushFromFSpVal 16
syscall 0, 50 ; trap_effect_is_active (1 in, 1 out)
eqzv
L740:
jz L756
pushFromFSpVal 16
syscall 0, 53 ; trap_effect_pos (1 in, 1 out)
memcpyToSp 16, 16
pushFromPSp 16
memcpyToSpVal 16, 32
jmp L756
L756:
ret
L757:
popToSp 0
pushFromPSp 16
pushImmf 0
pushImmf 0
pushImmf 0
pushImmf 200
pushImmf 0
gosub32 40, L1015
pushFromPSp 136
pushImmf 100
pushImmf 0
pushImmf 100
pushImmf 0
gosub32 40, L1202
pushFromPSp 128
pushImmf 10
gosub32 40, L1525
pushFromPSpVal 0
pushImm 8
pushImm 0
pushImm 0
syscall 1, 21 ; trap_obj_effect_start (4 in, 1 out)
popToSpVal 64
pushFromPSpVal 0
pushImm 1953
pushImm -1
pushImm 0
syscall 2, 10 ; trap_attack_new (4 in, 1 out)
popToSpVal 68
pushFromFSpVal 68
pushImmf 100
pushImmf 0
syscall 2, 11 ; trap_attack_set_radius (3 in, 0 out)
pushFromFSpVal 68
pushImm L1245
pushFromFSp 0
syscall 2, 38 ; trap_attack_set_hit_callback (3 in, 0 out)
pushFromPSp 16
pushFromFSp 0
fetchValue 48
pushImm 1
gosub32 40, L2407
pushFromPSp 16
pushFromPSpVal 80
gosub32 40, L2431
pushImm 1
popToSpVal 96
pushFromPSp 132
pushImmf 0
gosub32 40, L1525
L885:
pushFromFSpVal 64
syscall 0, 50 ; trap_effect_is_active (1 in, 1 out)
jz L1014
pushFromPSp 16
pushFromPSpVal 32
gosub32 40, L2446
pushFromPSpVal 32
pushFromPSp 16
pushImm 16
add
pushFromPSp 136
gosub32 40, L2958
syscall 0, 45 ; trap_vector_addf (3 in, 0 out)
pushFromFSp 0
pushFromPSpVal 32
gosub32 40, L2963
pushFromFSpVal 64
pushFromPSp 16
pushImm 16
add
syscall 0, 41 ; trap_effect_set_dir (2 in, 0 out)
halt
pushFromPSp 136
gosub32 40, L3007
pushFromPSp 128
gosub32 40, L2039
dup
jnz L959
pushFromFSpVal 68
pushImm 0
sub
neqz
dup
jz L958
pushFromFSpVal 96
eqz
eqzv
L958:
neqzv
L959:
jz L998
pushFromFSpVal 64
pushImmf -1
gosub32 40, L2268
pushFromFSpVal 96
jz L983
pushFromPSp 132
pushImmf 10
gosub32 40, L1525
jmp L988
L983:
pushFromFSp 0
gosub32 40, L3050
L988:
pushFromPSp 128
pushImmf -1
gosub32 40, L1525
jmp L998
L998:
pushFromPSp 132
gosub32 40, L2039
jz L1012
pushFromFSp 0
gosub32 40, L3050
jmp L1012
L1012:
jmp L885
L1014:
ret
L1015:
popToSp 4
popToSp 8
popToSp 12
popToSp 16
popToSp 20
popToSp 0
pushFromFSp 0
pushFromFSp 20
pushFromFSp 16
pushFromFSp 12
gosub32 8, L1113
pushFromFSp 0
pushFromFSp 4
gosub32 8, L1170
pushFromFSp 0
pushFromFSp 8
gosub32 8, L1193
pushFromPSpVal 48
pushImmf 1
gosub32 8, L635
pushFromFSp 8
popToSpVal 68
pushFromPSpVal 32
pushImmf 1
gosub32 8, L635
pushImm 0
popToSpVal 92
pushImm 0
popToSpVal 96
pushImm 0
popToSpVal 104
pushImm 0
popToSpVal 64
pushImm 0
popToSpVal 100
pushImmf 100000
popToSpVal 76
pushImmf 200
popToSpVal 80
pushImmf -1
popToSpVal 84
ret
L1113:
popToSp 4
popToSp 8
popToSp 12
popToSp 0
pushFromFSp 0
pushFromFSp 12
gosub32 8, L1143
pushFromFSp 0
pushFromFSp 8
gosub32 8, L1152
pushFromFSp 0
pushFromFSp 4
gosub32 8, L1161
ret
L1143:
popToSp 4
popToSp 0
pushFromFSp 4
popToSpVal 8
ret
L1152:
popToSp 4
popToSp 0
pushFromFSp 4
popToSpVal 4
ret
L1161:
popToSp 4
popToSp 0
pushFromFSp 4
popToSpVal 0
ret
L1170:
popToSp 4
popToSp 0
pushFromFSp 4
popToSpVal 72
pushFromFSp 0
pushImm 88
add
pushFromFSpVal 72
pushImmf 0
subf
infoezf
memcpy 0
ret
L1193:
popToSp 4
popToSp 0
pushFromFSp 4
popToSpVal 68
ret
L1202:
popToSp 4
popToSp 8
popToSp 12
popToSp 16
popToSp 0
pushFromFSp 0
pushFromFSp 16
pushFromFSp 12
pushFromFSp 8
gosub32 8, L1113
pushFromFSp 0
pushFromFSp 4
gosub32 8, L1231
ret
L1231:
popToSp 4
popToSp 0
pushFromFSp 0
pushImm 12
add
pushFromFSp 4
memcpy 0
ret
L1245:
popToSp 4
popToSp 8
popToSp 0
pushFromFSp 0
pushFromFSp 8
gosub32 8, L1283
jz L1282
gosub32 8, L1312
eqz
jz L1275
pushFromFSp 0
pushFromFSp 8
gosub32 8, L1315
jmp L1275
L1275:
pushImm 0
popToSpVal 96
jmp L1282
L1282:
ret
L1283:
popToSp 4
popToSp 0
pushFromFSp 4
fetchValue 4
syscall 1, 309 ; trap_sysobj_is_player (1 in, 1 out)
dup
jz L1302
pushFromFSp 4
syscall 1, 225 ; trap_obj_is_star (1 in, 1 out)
eqz
eqzv
L1302:
dup
jz L1311
pushFromFSp 4
syscall 1, 101 ; trap_obj_motion_is_capture (1 in, 1 out)
eqz
eqzv
L1311:
ret
L1312:
pushFromFWp W0
ret
L1315:
popToSp 4
popToSp 0
pushFromPSpVal 0
pushFromFSp 4
gosub32 4, L1327
ret
L1327:
popToSp 0
popToSp 4
pushFromFSp 4
syscall 1, 207 ; trap_camera_watch (1 in, 0 out)
pushFromFSp 4
pushFromFSp 0
pushImm 252
pushImmf 0
syscall 1, 29 ; trap_obj_motion_capture (4 in, 1 out)
drop
pushFromFSp 4
fetchValue 4
pushImm 212
pushImmf 0
syscall 1, 11 ; trap_sysobj_motion_start (3 in, 0 out)
pushFromFSp 4
pushFromPAi L40555 ; ___ai cap_arrow (L40555)
syscall 1, 8 ; trap_obj_act_start (2 in, 0 out)
pushFromFSp 0
syscall 1, 74 ; trap_obj_idle (1 in, 0 out)
pushFromFSp 0
pushFromFSp 0
syscall 1, 147 ; trap_obj_pos (1 in, 1 out)
memcpyToSp 16, 16
pushFromPSp 16
syscall 1, 153 ; trap_obj_reset_pos (2 in, 0 out)
pushFromFSp 0
fetchValue 4
pushImm 0
pushImmf 0
syscall 1, 13 ; trap_sysobj_motion_push (3 in, 0 out)
pushImm 128
pushImm L1430
pushFromFSp 4
gosub32 8, L2321
popToSp 8
pushFromFSp 8
pushFromFSp 0
gosub32 8, L2397
syscall 2, 67 ; trap_attack_new_combo_group (0 in, 1 out)
popToWp W8
pushImm 21625
syscall 4, 4 ; trap_mission_information (1 in, 0 out)
pushImm 1
popToWp W0
ret
L1430:
popToSp 0
pushFromFSp 0
gosub32 4, L1448
pushFromFSp 0
gosub32 4, L1534
pushFromFSp 0
gosub32 4, L2297
ret
L1448:
popToSp 0
pushFromFSp 0
gosub32 4, L723
pushImm 1
popToWp W4
pushImm 0
popToSp 4
pushImm 4
L1468:
dup
pushFromFSp 4
sub
info
jnz L1498
pushFromPSpVal 80
pushFromFSp 4
pushImm 4
mul
add
pushImm 103
memcpy 0
pushFromFSp 4
pushImm 1
add
popToSp 4
jmp L1468
L1498:
drop
pushImmf 3
popToSpVal 112
pushFromPSpVal 104
pushFromFSpVal 112
gosub32 4, L1525
pushFromPSpVal 108
pushImmf 60
gosub32 4, L1525
pushImmf 0
popToSpVal 100
ret
L1525:
popToSp 4
popToSp 0
pushFromFSp 4
popToSpVal 0
ret
L1534:
popToSp 0
pushImm 0
pushImm L1706
pushImm 0
pushFromFSp 0
syscall 0, 9 ; trap_thread_start (4 in, 1 out)
drop
pushFromFSpVal 48
pushFromPSpVal 64
pushFromPSpVal 0
syscall 1, 147 ; trap_obj_pos (1 in, 1 out)
memcpyToSp 16, 16
pushFromPSp 16
syscall 6, 11 ; trap_target_searcher_search_obj (3 in, 0 out)
pushImmf 100
gosub32 4, L1748
pushFromFSp 0
pushImm 15
pushFromFSpVal 48
gosub32 4, L299
memcpyToSp 16, 16
pushFromPSp 16
pushImm 1
pushImm 0
syscall 1, 149 ; trap_obj_effect_start_bind_other (5 in, 1 out)
popToSp 4
pushFromFSp 0
gosub32 4, L1770
L1601:
pushFromFSp 0
gosub32 4, L1832
pushFromFSp 0
gosub32 4, L2074
halt
pushFromFSpVal 48
syscall 1, 140 ; trap_target_is_exist (1 in, 1 out)
dup
jz L1634
pushFromFSpVal 48
gosub32 4, L299
memcpyToSp 16, 16
pushFromPSp 16
fetchValue 4
syscall 1, 94 ; trap_sysobj_is_exist (1 in, 1 out)
eqzv
L1634:
dup
jz L1650
pushFromFSpVal 48
gosub32 12, L299
memcpyToSp 16, 32
pushFromPSp 32
syscall 1, 272 ; trap_obj_is_dead (1 in, 1 out)
eqzv
L1650:
jz L1664
pushFromFSp 4
pushImmf -1
gosub32 4, L2268
jmp L1699
L1662:
jmp L1664
L1664:
pushFromFWp W4
eqz
jz L1697
pushFromFSp 4
pushImmf -1
gosub32 4, L2268
pushFromFSp 0
pushImm 17
pushFromPSpVal 64
pushImm 1
pushImm 0
syscall 1, 149 ; trap_obj_effect_start_bind_other (5 in, 1 out)
drop
jmp L1699
L1695:
jmp L1697
L1697:
jmp L1601
L1699:
pushImm 0
popToWp W4
halt
ret
L1706:
popToSp 0
L1708:
pushFromFWp W4
jz L1747
pushFromPSpVal 80
fetchValue 0
pushFromPSpVal 80
pushImm 4
add
fetchValue 0
pushFromPSpVal 80
pushImm 8
add
fetchValue 0
pushFromPSpVal 80
pushImm 12
add
fetchValue 0
pushFromPSpVal 0
syscall 1, 237 ; trap_command_override_top (5 in, 0 out)
halt
jmp L1708
L1747:
ret
L1748:
popToSp 0
L1750:
pushFromFSp 0
pushImmf 0
subf
supzf
jz L1769
pushFromFSp 0
syscall 0, 3 ; trap_frametime (0 in, 1 out)
subf
popToSp 0
halt
jmp L1750
L1769:
ret
L1770:
popToSp 0
pushImm 0
popToSp 4
pushImm 4
L1780:
dup
pushFromFSp 4
sub
info
jnz L1810
pushFromPSpVal 80
pushFromFSp 4
pushImm 4
mul
add
pushImm 722
memcpy 0
pushFromFSp 4
pushImm 1
add
popToSp 4
jmp L1780
L1810:
drop
pushImm 4
syscall 0, 16 ; trap_random_get (1 in, 1 out)
popToSpVal 96
pushFromPSpVal 80
pushFromFSpVal 96
pushImm 4
mul
add
pushImm 723
memcpy 0
ret
L1832:
popToSp 0
pushFromPSpVal 104
gosub32 8, L2008
jz L1995
pushFromPSpVal 108
gosub32 8, L2008
jz L1868
pushFromFSpVal 112
pushImmf 4
addf
popToSpVal 112
pushFromFSpVal 112
pushImmf 180
gosub32 8, L2018
popToSpVal 112
jmp L1868
L1868:
pushFromPSpVal 104
pushFromFSpVal 112
gosub32 8, L1525
pushFromPSpVal 80
pushFromFSpVal 96
pushImm 4
mul
add
pushImm 722
memcpy 0
pushImm 0
popToSp 16
pushImm 0
popToSp 20
pushImm 4
L1901:
dup
pushFromFSp 20
sub
info
jnz L1948
pushFromFSp 20
pushFromFSpVal 96
sub
neqz
jz L1938
pushFromPSp 4