forked from nmlgc/ReC98
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathth03_zunsp.asm
2119 lines (1765 loc) · 37.9 KB
/
th03_zunsp.asm
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
;
; +-------------------------------------------------------------------------+
; | This file has been generated by The Interactive Disassembler (IDA) |
; | Copyright (c) 2009 by Hex-Rays, <[email protected]> |
; +-------------------------------------------------------------------------+
;
; Input MD5 : 712EDD4642948A68F70365DC4DB06C62
; File Name : th04/ZUN.COM:ZUNSP (-4)
; Format : MS-DOS COM-file
; Base Address: 0h Range: 100h-1180h Loaded length: 1080h
; OS type : MS DOS
; Application type: Executable 16bit
.286 ; Force the .model directive to create 16-bit default segments...
.model tiny
.386 ; ... then switch to what we actually need.
; And yes, we can't move this to an include file for some reason.
include libs/master.lib/macros.inc
; ===========================================================================
; Segment type: Pure code
_TEXT segment use16
assume cs:_TEXT
org 100h
assume es:nothing, ss:nothing, ds:_TEXT, fs:nothing, gs:nothing
public start
start:
jmp short sub_10C
; ---------------------------------------------------------------------------
aSprite16 db 'SPRITE16',0
db 4
; =============== S U B R O U T I N E =======================================
; Attributes: noreturn
sub_10C proc near
cld
push offset aZunsp_comVersi ; "ZUNSP.COM Version 1.00 Copyright(C) "...
call sub_676
push es
mov ax, 0
mov es, ax
assume es:_TEXT
mov bx, word ptr es:start
mov es, word ptr es:aSprite16 ; "SPRITE16"
assume es:nothing
mov ax, es:[bx+2]
xchg al, ah
pop es
assume es:nothing
cmp ax, 'OK'
jnz short loc_137
mov word_F40, 1
jmp short loc_13D
; ---------------------------------------------------------------------------
loc_137:
mov word_F40, 0
loc_13D:
mov ax, 1180h
shr ax, 4
inc ax
mov word_F43, ax
mov sp, offset word_F38
push ds
pop es
assume es:_TEXT
mov bx, word_F43
mov ah, 4Ah
int 21h ; DOS - 2+ - ADJUST MEMORY BLOCK SIZE (SETBLOCK)
; ES = segment address of block to change
; BX = new size in paragraphs
jnb short loc_161
push offset aGbgvgkpkpmvOFs ; "メモリ縮小に失敗しました。\r\n"
call sub_676
mov ax, 4C01h
int 21h ; DOS - 2+ - QUIT WITH EXIT CODE (EXIT)
; AL = exit code
; ---------------------------------------------------------------------------
loc_161:
mov di, 81h
mov al, 0Dh
mov cx, 80h
repne scasb
mov byte ptr [di-1], 0
mov si, 81h
call sub_920
cmp word_1070, 0
jbe short loc_186
call sub_A36
mov ax, 4C00h
int 21h ; DOS - 2+ - QUIT WITH EXIT CODE (EXIT)
; AL = exit code
; ---------------------------------------------------------------------------
jmp short loc_191
; ---------------------------------------------------------------------------
loc_186:
push offset aUsageZunspZPat ; "Usage: ZUNSP -z (常駐)\r\n "...
call sub_676
mov ax, 4C01h
int 21h ; DOS - 2+ - QUIT WITH EXIT CODE (EXIT)
; AL = exit code
loc_191:
cmp cs:word_F40, 0
jz short locret_19B
int 40h ; Hard disk - Relocated Floppy Handler (original INT 13h)
locret_19B:
retn
sub_10C endp
; =============== S U B R O U T I N E =======================================
sub_19C proc near
mov bx, 1000
mov ah, 48h
int 21h ; DOS - 2+ - ALLOCATE MEMORY
; BX = number of 16-byte paragraphs desired
jnb short loc_1B0
push offset aGbgvgkvkslvsvV ; "メモリが足りません。\r\n"
call sub_676
mov ax, 4C01h
int 21h ; DOS - 2+ - QUIT WITH EXIT CODE (EXIT)
; AL = exit code
; ---------------------------------------------------------------------------
loc_1B0:
mov word_F3C, ax
add word_F43, 1000
mov bx, 1000
mov ah, 48h
int 21h ; DOS - 2+ - ALLOCATE MEMORY
; BX = number of 16-byte paragraphs desired
jnb short loc_1CD
push offset aGbgvgkvkslvsvV ; "メモリが足りません。\r\n"
call sub_676
mov ax, 4C01h
int 21h ; DOS - 2+ - QUIT WITH EXIT CODE (EXIT)
; AL = exit code
; ---------------------------------------------------------------------------
loc_1CD:
mov word_F3E, ax
add word_F43, 1000
retn
sub_19C endp
; =============== S U B R O U T I N E =======================================
sub_1D7 proc near
call sub_A0A
mov byte_F42, al
retn
sub_1D7 endp
; =============== S U B R O U T I N E =======================================
sub_1DE proc near
call sub_19C
call sub_520
call sub_540
call sub_610
push ds
push es
mov ds, word_F3C
xor si, si
mov ax, 0A800h
mov es, ax
assume es:nothing
xor di, di
mov cx, 1F40h
rep movsw
pop es
assume es:nothing
pop ds
retn
sub_1DE endp
; =============== S U B R O U T I N E =======================================
sub_201 proc near
call sub_19C
call sub_540
call sub_A0A
mov dx, ax
call sub_A0A
mov bx, ax
call sub_A0A
mov di, ax
call sub_A0A
push ax
call sub_A0A
mov cx, ax
pop ax
call sub_BD0
call sub_364
call sub_C10
retn
sub_201 endp
; =============== S U B R O U T I N E =======================================
sub_22A proc far
push bx
mov bl, ah
xor bh, bh
shl bx, 1
mov bx, cs:off_103E[bx]
mov cs:word_F45, bx
pop bx
sti
call cs:word_F45
iret
sub_22A endp
; =============== S U B R O U T I N E =======================================
sub_243 proc near
push es
xor ax, ax
mov es, ax
assume es:_TEXT
mov bl, byte_F42
xor bh, bh
shl bx, 2
mov es, word ptr es:[bx+2]
assume es:nothing
mov di, 102h
mov si, 102h
mov cx, 0Ah
repe cmpsb
pop es
jz short loc_2A6
call sub_19C
push es
xor ax, ax
mov es, ax
assume es:_TEXT
mov dx, cs
mov ax, offset sub_22A
mov bl, byte_F42
xor bh, bh
shl bx, 2
xchg dx, es:[bx+2]
xchg ax, es:[bx]
mov word_F38, dx
mov word_F3A, ax
pop es
assume es:nothing
movzx eax, byte_F42
push eax
mov bx, sp
mov dx, offset aPatuvVVVBbInt0 ; "常駐しました。(int %02Xh)\r\n"
call sub_640
add sp, 4
mov dx, word_F43
mov ax, 3100h
int 21h ; DOS - DOS 2+ - TERMINATE BUT STAY RESIDENT
; AL = exit code, DX = program size, in paragraphs
; ---------------------------------------------------------------------------
jmp short locret_2AC
; ---------------------------------------------------------------------------
loc_2A6:
push offset aVVVPatuvVVvvVB ; "すでに常駐しています。\r\n"
call sub_676
locret_2AC:
retn
sub_243 endp
; =============== S U B R O U T I N E =======================================
sub_2AD proc near
xor ax, ax
mov es, ax
assume es:_TEXT
mov bl, byte_F42
xor bh, bh
shl bx, 2
mov es, word ptr es:[bx+2]
assume es:nothing
mov di, 102h
mov si, 102h
mov cx, 0Ah
repe cmpsb
jnz short loc_339
mov dx, es:word_F38
mov ax, es:word_F3A
push es
xor ax, ax
mov es, ax
assume es:_TEXT
mov bl, byte_F42
xor bh, bh
shl bx, 2
mov es:[bx+2], dx
mov es:[bx], ax
pop es
assume es:nothing
push es
mov es, word ptr es:2Ch
mov ah, 49h
int 21h ; DOS - 2+ - FREE MEMORY
; ES = segment address of area to be freed
jnb short loc_2FC
push offset aKLlcIci ; "環境領域解放失敗\r\n"
call sub_676
loc_2FC:
pop es
push es
mov es, word ptr es:0F3Ch
mov ah, 49h
int 21h ; DOS - 2+ - FREE MEMORY
; ES = segment address of area to be freed
jnb short loc_30F
push offset aGGxgngfbGCIci ; "マスクデータ領域解放失敗\r\n"
call sub_676
loc_30F:
pop es
push es
mov es, word ptr es:0F3Eh
mov ah, 49h
int 21h ; DOS - 2+ - FREE MEMORY
; ES = segment address of area to be freed
jnb short loc_322
push offset aGxgGfbGCIci ; "ベタデータ領域解放失敗\r\n"
call sub_676
loc_322:
pop es
mov ah, 49h
int 21h ; DOS - 2+ - FREE MEMORY
; ES = segment address of area to be freed
jnb short loc_331
push offset aGrbGhcIci ; "コード領域解放失敗\r\n"
call sub_676
jmp short locret_33F
; ---------------------------------------------------------------------------
loc_331:
push offset aI ; "解放しました。\r\n"
call sub_676
jmp short locret_33F
; ---------------------------------------------------------------------------
loc_339:
push offset aPatuvVVvvVV ; "常駐していません。\r\n"
call sub_676
locret_33F:
retn
sub_2AD endp
; =============== S U B R O U T I N E =======================================
sub_340 proc near
mov cs:word_1064, dx
retn
sub_340 endp
; =============== S U B R O U T I N E =======================================
sub_346 proc near
mov cs:word_1066, dx
retn
sub_346 endp
; =============== S U B R O U T I N E =======================================
sub_34C proc near
mov cs:word_1068, dx
retn
sub_34C endp
; =============== S U B R O U T I N E =======================================
sub_352 proc near
mov cs:word_106E, dx
retn
sub_352 endp
; =============== S U B R O U T I N E =======================================
sub_358 proc near
mov cs:word_106A, dx
retn
sub_358 endp
; =============== S U B R O U T I N E =======================================
sub_35E proc near
mov cs:word_106C, dx
retn
sub_35E endp
; =============== S U B R O U T I N E =======================================
sub_364 proc near
push ax
push bx
push cx
push dx
push si
push di
push bp
push ds
push es
push cs
pop ds
xor ah, ah
mov word_105A, dx
mov word_105C, bx
mov word_105E, di
mov word_1060, ax
mov word_1062, cx
mov word_1054, 0
cmp word_105C, 0
jge short loc_3C1
mov ax, word_105C
add ax, word_1062
cmp ax, 0
jg short loc_3A1
jmp short loc_3F8
; ---------------------------------------------------------------------------
jmp short loc_3EE
; ---------------------------------------------------------------------------
loc_3A1:
mov ax, 0
sub ax, word_105C
mov word_1054, ax
shl ax, 4
mov dx, ax
shl ax, 2
add ax, dx
add word_105E, ax
mov word_105C, 0
jmp short loc_3EE
; ---------------------------------------------------------------------------
loc_3C1:
cmp word_105C, 0C8h
jb short loc_3CD
jmp short loc_3F8
; ---------------------------------------------------------------------------
jmp short loc_3EE
; ---------------------------------------------------------------------------
loc_3CD:
mov dx, word_105C
add dx, word_1062
cmp dx, 0C8h
jle short loc_3EE
mov ax, 0C8h
sub ax, word_105C
mov dx, word_1062
sub dx, ax
mov word_1054, dx
jmp short $+2
loc_3EE:
mov ax, word_1054
sub word_1062, ax
call sub_402
loc_3F8:
pop es
pop ds
pop bp
pop di
pop si
pop dx
pop cx
pop bx
pop ax
retn
sub_364 endp
; =============== S U B R O U T I N E =======================================
sub_402 proc near
mov si, word_105E
mov ax, word_105A
shr ax, 3
and ax, 0FFFEh
xor dx, dx
mov cx, word_105C
imul di, cx, 50h
add di, ax
mov ax, word_105A
and ax, 0Fh
mov word_1050, ax
mov dx, EGC_ADDRRESSREG
mov ax, word_1050
shl ax, 4
out dx, ax
mov word_1052, 0
xor ax, ax
cmp word_1050, 0
setnz al
mov word_1052, ax
mov ax, 0A800h
mov es, ax
assume es:nothing
mov dx, EGC_BITLENGTHREG
mov ax, word_1060
shl ax, 4
dec ax
out dx, ax
mov ax, word_1060
add ax, word_1052
mov word_1058, ax
mov ax, word_1058
shl ax, 1
mov dx, 50h
sub dx, ax
mov word_1056, dx
cmp cs:word_1064, 0
jz short loc_49C
outw EGC_READPLANEREG, 0FFh
outw EGC_MASKREG, cs:word_106C
outw EGC_READPLANEREG, 40FFh
outw EGC_MODE_ROP_REG, EGC_WS_ROP or EGC_SHIFT_CPU or 0ACh
outw EGC_FGCOLORREG, cs:word_1066
mov ds, cs:word_F3E
jmp short loc_4EB
; ---------------------------------------------------------------------------
loc_49C:
cmp cs:word_1068, 0
jz short loc_4CB
outw EGC_ACTIVEPLANEREG, 0FFF0h
outw EGC_READPLANEREG, 0FFh
outw EGC_MODE_ROP_REG, EGC_WS_ROP or EGC_SHIFT_CPU or 0C0h
outw EGC_MASKREG, cs:word_106C
mov ds, cs:word_F3C
call sub_4F8
jmp short loc_4DA
; ---------------------------------------------------------------------------
loc_4CB:
outw EGC_READPLANEREG, 0FFh
outw EGC_MASKREG, cs:word_106C
loc_4DA:
outw EGC_MODE_ROP_REG, cs:word_106A
mov ax, 0A800h
mov ds, ax
assume ds:nothing
add si, 3E80h
loc_4EB:
outw EGC_ACTIVEPLANEREG, cs:word_106E
call sub_4F8
retn
sub_402 endp
; ---------------------------------------------------------------------------
nop
; =============== S U B R O U T I N E =======================================
sub_4F8 proc near
push si
push di
mov bx, cs:word_1062
mov dx, cs:word_1058
mov ax, cs:word_1056
loc_508:
mov cx, dx
rep movsw
add si, ax
add di, ax
dec bx
jnz short loc_508
pop di
pop si
retn
sub_4F8 endp
; ---------------------------------------------------------------------------
db 10 dup(0)
; =============== S U B R O U T I N E =======================================
sub_520 proc near
push ds
push es
pusha
mov al, 1
out 6Ah, al ; PC-98 GDC (6a):
;
xor al, al
out 0A6h, al ; Interrupt Controller #2, 8259A
call sub_5D0
call sub_5F7
call sub_5A4
xor al, al
out 0A4h, al ; Interrupt Controller #2, 8259A
xor al, al
out 0A6h, al ; Interrupt Controller #2, 8259A
popa
pop es
assume es:nothing
pop ds
assume ds:_TEXT
retn
sub_520 endp
; =============== S U B R O U T I N E =======================================
sub_540 proc near
push ds
push es
pusha
call sub_C10
xor al, al
out 0A6h, al ; Interrupt Controller #2, 8259A
mov es, cs:word_F3E
xor di, di
xor ax, ax
mov cx, 1F40h
rep stosw
mov es, cs:word_F3E
mov ax, 0A800h
call sub_590
mov ax, 0B000h
call sub_590
mov ax, 0B800h
call sub_590
mov ax, 0E000h
call sub_590
mov ds, cs:word_F3E
mov es, cs:word_F3C
xor si, si
xor di, di
mov cx, 1F40h
loc_586:
lodsw
not ax
stosw
loop loc_586
popa
pop es
pop ds
retn
sub_540 endp
; =============== S U B R O U T I N E =======================================
sub_590 proc near
mov ds, ax
xor bx, bx
mov cx, 1F40h
loc_597:
mov ax, [bx+3E80h]
or es:[bx], ax
add bx, 2
loop loc_597
retn
sub_590 endp
; =============== S U B R O U T I N E =======================================
sub_5A4 proc near
push ds
push es
pusha
call sub_BD0
mov ax, 0A800h
mov ds, ax
assume ds:nothing
mov bl, 0
mov bh, 1
mov di, 3E80h
mov cx, 1F40h
loc_5B9:
mov al, bl
out 0A6h, al ; Interrupt Controller #2, 8259A
mov dx, [di]
mov al, bh
out 0A6h, al ; Interrupt Controller #2, 8259A
mov [di], dx
inc di
inc di
loop loc_5B9
call sub_C10
popa
pop es
pop ds
assume ds:_TEXT
retn
sub_5A4 endp
; =============== S U B R O U T I N E =======================================
sub_5D0 proc near
push ds
push es
pusha
call sub_BD0
mov ax, 0A800h
mov ds, ax
assume ds:nothing
mov es, ax
assume es:nothing
xor si, si
xor di, di
mov cx, 0C8h
loc_5E4:
push cx
mov cx, 28h
rep movsw
pop cx
add si, 50h
loop loc_5E4
call sub_C10
popa
pop es
assume es:nothing
pop ds
assume ds:_TEXT
retn
sub_5D0 endp
; =============== S U B R O U T I N E =======================================
sub_5F7 proc near
call sub_BD0
mov ax, 0A800h
mov ds, ax
assume ds:nothing
mov es, ax
assume es:nothing
mov si, 0
mov di, 3E80h
mov cx, 1F40h
rep movsw
call sub_C10
retn
sub_5F7 endp
; =============== S U B R O U T I N E =======================================
sub_610 proc near
push es
pusha
call sub_BD0
outw EGC_MODE_ROP_REG, 0
mov ax, 0A800h
mov es, ax
xor di, di
mov ax, 0
mov cx, 1F40h
rep stosw
call sub_C10
popa
pop es
assume es:nothing
retn
sub_610 endp
; ---------------------------------------------------------------------------
db 15 dup(0)
; =============== S U B R O U T I N E =======================================
; Attributes: bp-based frame
sub_640 proc near
var_D0 = byte ptr -0D0h
enter 0D0h, 0
push es
push di
push ss
pop es
lea di, [bp+var_D0]
call sub_6B0
push ds
push dx
push ss
pop ds
assume ds:_TEXT
lea dx, [bp+var_D0]
call sub_660
pop dx
pop ds
pop di
pop es
leave
retn
sub_640 endp
; =============== S U B R O U T I N E =======================================
sub_660 proc near
push ax
push dx
push si
mov si, dx
loc_665:
mov dl, [si]
or dl, dl
jz short loc_672
mov ah, 2
int 21h ; DOS - DISPLAY OUTPUT
; DL = character to send to standard output
inc si
jmp short loc_665
; ---------------------------------------------------------------------------
loc_672:
pop si
pop dx
pop ax
retn
sub_660 endp
; =============== S U B R O U T I N E =======================================
; Attributes: bp-based frame
sub_676 proc near
arg_0 = word ptr 4
push bp
mov bp, sp
push dx
push ds
mov dx, [bp+arg_0]
push ss
pop ds
call sub_660
pop ds
pop dx
pop bp
retn 2
sub_676 endp
; =============== S U B R O U T I N E =======================================
sub_689 proc near
cmp dl, 30h
jb short loc_692
cmp dl, 3Ah
retn
; ---------------------------------------------------------------------------
loc_692:
clc
retn
sub_689 endp
; =============== S U B R O U T I N E =======================================
sub_694 proc near
cmp al, 61h
jb short loc_69B
cmp al, 7Bh
retn
; ---------------------------------------------------------------------------
loc_69B:
clc
retn
sub_694 endp
; =============== S U B R O U T I N E =======================================
sub_69D proc near
call sub_694
jnb short locret_6A4
and al, 0DFh
locret_6A4:
retn
sub_69D endp
; ---------------------------------------------------------------------------
db 11 dup(0)
; =============== S U B R O U T I N E =======================================
; Attributes: bp-based frame
sub_6B0 proc near
var_50 = byte ptr -50h
var_18 = word ptr -18h
var_14 = dword ptr -14h
var_10 = word ptr -10h
var_C = word ptr -0Ch
var_8 = word ptr -8
var_4 = word ptr -4
enter 50h, 0
pusha
push ds
push es
mov si, dx
jmp loc_86D
; ---------------------------------------------------------------------------
loc_6BC:
cmp byte ptr [si], 25h
jnz loc_83F
mov [bp+var_4], 0
mov [bp+var_8], 0
mov [bp+var_C], 0
mov [bp+var_10], 0
inc si
cmp byte ptr [si], 2Dh
jnz short loc_6E3
inc si
mov [bp+var_C], 1
loc_6E3:
cmp byte ptr [si], 30h
jnz short loc_6EE
inc si
mov [bp+var_10], 1
loc_6EE:
xor ax, ax
xor dx, dx
jmp short loc_701