2014-06-29 22:52:27 +00:00
|
|
|
|
;
|
|
|
|
|
; +-------------------------------------------------------------------------+
|
|
|
|
|
; | This file has been generated by The Interactive Disassembler (IDA) |
|
|
|
|
|
; | Copyright (c) 2009 by Hex-Rays, <support@hex-rays.com> |
|
|
|
|
|
; +-------------------------------------------------------------------------+
|
|
|
|
|
;
|
|
|
|
|
; Input MD5 : 661F4F8FFAF1F3274F503D154133DEF0
|
|
|
|
|
|
|
|
|
|
; File Name : th03/OP.EXE
|
|
|
|
|
; Format : MS-DOS executable (EXE)
|
|
|
|
|
; Base Address: 0h Range: 0h-FD80h Loaded length: E97Ah
|
|
|
|
|
; Entry Point : 0:0
|
|
|
|
|
; OS type : MS DOS
|
|
|
|
|
; Application type: Executable 16bit
|
|
|
|
|
|
2021-03-29 17:16:49 +00:00
|
|
|
|
.386
|
2021-12-23 01:26:27 +00:00
|
|
|
|
.model use16 large _TEXT
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-22 15:06:33 +00:00
|
|
|
|
include ReC98.inc
|
2019-09-20 19:02:20 +00:00
|
|
|
|
include th03/th03.inc
|
2020-10-26 13:30:35 +00:00
|
|
|
|
include th01/hardware/grppsafx.inc
|
2022-03-12 20:31:36 +00:00
|
|
|
|
include th02/op/music.inc
|
2021-12-21 13:14:28 +00:00
|
|
|
|
include th03/sprites/regi.inc
|
|
|
|
|
include th03/formats/scoredat.inc
|
Include RULES.ASI from every executable's dump file.
Having thought this over for a while, I've decided to stay with the "include
slice" model for now, due to various bugs and other reasons.
We need to compile for the 386 CPU, but this causes TASM to automatically
default every segment to 32-bit mode, which of course is not what we want (and
no, .MODEL USE16 sadly does not help either). Appending USE16 to every segment
declaration in all included files seems to work, but for some reason, this
messes up certain jump instructions. WTF? And even if it did work, we would
still have to do this for every single file we include.
The alternative would be to build proper libraries and let the linker merge
all the code. This would add a lot of unwarranted complexity to the build
process. Not to mention all the EXTERN statements we'd have to maintain.
Ultimately, all of the C runtime ASM code is going to vanish anyway once we've
completed the reduction step. Once we're there, we can simply link to the
original version of the library. These initial dumps are not pretty, and I see
no point in wasting time on making intermediary stages of development look
pretty.
Since including RULES.ASI from every slice seems a bit inefficient (and even
potentiall harmful, considering the age of the development tools we have to
work with), we'll only include it once at the top of every main dump file.
[Binary change] Relocations in TH01's REIIDEN.EXE, again.
2014-08-14 06:01:36 +00:00
|
|
|
|
|
2015-02-19 06:46:36 +00:00
|
|
|
|
extern _execl:proc
|
|
|
|
|
extern _getch:proc
|
|
|
|
|
|
2021-12-25 14:53:17 +00:00
|
|
|
|
group_01 group op_01_TEXT, op_02_TEXT, SCOREDAT_TEXT, op_03_TEXT
|
2021-12-20 17:16:11 +00:00
|
|
|
|
|
2014-06-29 22:52:27 +00:00
|
|
|
|
; ===========================================================================
|
|
|
|
|
|
|
|
|
|
; Segment type: Pure code
|
2015-02-18 11:07:37 +00:00
|
|
|
|
_TEXT segment word public 'CODE' use16
|
|
|
|
|
assume cs:_TEXT
|
2015-02-19 06:46:36 +00:00
|
|
|
|
assume es:nothing, ds:_DATA, fs:nothing, gs:nothing
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-23 09:51:14 +00:00
|
|
|
|
include libs/master.lib/bfnt_entry_pat.asm
|
2014-08-23 10:23:03 +00:00
|
|
|
|
include libs/master.lib/bfnt_extend_header_skip.asm
|
2014-08-23 10:08:48 +00:00
|
|
|
|
include libs/master.lib/bfnt_header_read.asm
|
2014-08-23 11:18:32 +00:00
|
|
|
|
include libs/master.lib/bfnt_header_analysis.asm
|
2014-08-26 18:54:57 +00:00
|
|
|
|
include libs/master.lib/bcloser.asm
|
2014-08-10 09:47:36 +00:00
|
|
|
|
include libs/master.lib/bfill.asm
|
2014-08-23 14:56:01 +00:00
|
|
|
|
include libs/master.lib/bfnt_palette_set.asm
|
2014-08-26 19:23:54 +00:00
|
|
|
|
include libs/master.lib/bgetc.asm
|
2014-08-26 22:33:43 +00:00
|
|
|
|
include libs/master.lib/palette_black_out.asm
|
2014-08-27 00:54:57 +00:00
|
|
|
|
include libs/master.lib/bopenr.asm
|
2014-08-26 19:34:06 +00:00
|
|
|
|
include libs/master.lib/bread.asm
|
2014-08-26 20:04:11 +00:00
|
|
|
|
include libs/master.lib/bseek.asm
|
2014-08-26 20:15:00 +00:00
|
|
|
|
include libs/master.lib/bseek_.asm
|
2014-08-23 01:03:17 +00:00
|
|
|
|
include libs/master.lib/dos_axdx.asm
|
2014-08-23 01:02:18 +00:00
|
|
|
|
include libs/master.lib/dos_keyclear.asm
|
2014-08-22 23:48:16 +00:00
|
|
|
|
include libs/master.lib/dos_puts2.asm
|
2014-08-22 23:38:22 +00:00
|
|
|
|
include libs/master.lib/dos_setvect.asm
|
2014-08-20 20:24:05 +00:00
|
|
|
|
include libs/master.lib/egc.asm
|
2014-08-27 02:57:37 +00:00
|
|
|
|
include libs/master.lib/egc_shift_left_all.asm
|
2014-08-30 05:58:36 +00:00
|
|
|
|
include libs/master.lib/file_append.asm
|
2014-08-30 06:15:42 +00:00
|
|
|
|
include libs/master.lib/file_close.asm
|
2014-08-30 06:32:10 +00:00
|
|
|
|
include libs/master.lib/file_create.asm
|
2014-08-30 06:46:38 +00:00
|
|
|
|
include libs/master.lib/file_exist.asm
|
2014-08-30 07:00:31 +00:00
|
|
|
|
include libs/master.lib/file_read.asm
|
2014-08-30 07:12:17 +00:00
|
|
|
|
include libs/master.lib/file_ropen.asm
|
2014-08-30 07:21:44 +00:00
|
|
|
|
include libs/master.lib/file_seek.asm
|
2014-08-30 07:38:09 +00:00
|
|
|
|
include libs/master.lib/file_write.asm
|
2014-08-22 22:46:33 +00:00
|
|
|
|
include libs/master.lib/dos_close.asm
|
2014-08-21 20:07:58 +00:00
|
|
|
|
include libs/master.lib/dos_ropen.asm
|
2014-08-28 03:31:57 +00:00
|
|
|
|
include libs/master.lib/grcg_boxfill.asm
|
2014-08-27 21:20:37 +00:00
|
|
|
|
include libs/master.lib/grcg_byteboxfill_x.asm
|
2014-09-01 04:52:28 +00:00
|
|
|
|
include libs/master.lib/grcg_polygon_c.asm
|
2014-08-28 03:48:32 +00:00
|
|
|
|
include libs/master.lib/grcg_pset.asm
|
2014-08-27 04:52:58 +00:00
|
|
|
|
include libs/master.lib/grcg_setcolor.asm
|
2014-08-31 08:23:41 +00:00
|
|
|
|
include libs/master.lib/gaiji_backup.asm
|
2014-08-31 08:08:09 +00:00
|
|
|
|
include libs/master.lib/gaiji_entry_bfnt.asm
|
2014-08-31 03:05:48 +00:00
|
|
|
|
include libs/master.lib/gaiji_putsa.asm
|
2014-08-31 07:40:28 +00:00
|
|
|
|
include libs/master.lib/gaiji_read.asm
|
2014-08-31 07:50:38 +00:00
|
|
|
|
include libs/master.lib/gaiji_write.asm
|
2014-08-27 22:58:40 +00:00
|
|
|
|
include libs/master.lib/graph_400line.asm
|
2014-08-27 04:03:08 +00:00
|
|
|
|
include libs/master.lib/graph_clear.asm
|
2014-08-27 04:13:48 +00:00
|
|
|
|
include libs/master.lib/graph_copy_page.asm
|
2014-08-15 14:11:51 +00:00
|
|
|
|
include libs/master.lib/graph_extmode.asm
|
2014-09-15 01:03:52 +00:00
|
|
|
|
include libs/master.lib/graph_gaiji_puts.asm
|
2014-08-21 23:39:42 +00:00
|
|
|
|
include libs/master.lib/graph_pi_free.asm
|
2014-08-22 19:15:44 +00:00
|
|
|
|
include libs/master.lib/graph_pi_load_pack.asm
|
2014-08-31 05:26:45 +00:00
|
|
|
|
include libs/master.lib/graph_pack_put_8.asm
|
2014-08-27 03:18:17 +00:00
|
|
|
|
include libs/master.lib/graph_show.asm
|
2014-08-27 23:16:54 +00:00
|
|
|
|
include libs/master.lib/graph_start.asm
|
2014-08-23 11:46:31 +00:00
|
|
|
|
include libs/master.lib/js_end.asm
|
2014-08-23 12:01:53 +00:00
|
|
|
|
include libs/master.lib/keybeep.asm
|
2014-08-27 03:05:30 +00:00
|
|
|
|
include libs/master.lib/make_linework.asm
|
2014-08-23 14:18:30 +00:00
|
|
|
|
include libs/master.lib/palette_init.asm
|
2014-08-23 14:11:16 +00:00
|
|
|
|
include libs/master.lib/palette_show.asm
|
2014-08-27 01:11:13 +00:00
|
|
|
|
include libs/master.lib/pfclose.asm
|
2014-09-07 13:07:36 +00:00
|
|
|
|
include libs/master.lib/pfgetc.asm
|
2014-08-30 10:50:48 +00:00
|
|
|
|
include libs/master.lib/pfread.asm
|
2014-08-30 10:33:48 +00:00
|
|
|
|
include libs/master.lib/pfrewind.asm
|
2014-08-30 10:26:02 +00:00
|
|
|
|
include libs/master.lib/pfseek.asm
|
2014-08-30 10:13:04 +00:00
|
|
|
|
include libs/master.lib/random.asm
|
2014-08-31 03:14:54 +00:00
|
|
|
|
include libs/master.lib/palette_entry_rgb.asm
|
2014-08-23 01:15:17 +00:00
|
|
|
|
include libs/master.lib/rottbl.asm
|
2014-08-21 22:59:18 +00:00
|
|
|
|
include libs/master.lib/smem_release.asm
|
2014-08-21 23:04:46 +00:00
|
|
|
|
include libs/master.lib/smem_wget.asm
|
2014-08-31 04:27:47 +00:00
|
|
|
|
include libs/master.lib/soundio.asm
|
2014-10-20 15:20:04 +00:00
|
|
|
|
include libs/master.lib/text_clear.asm
|
|
|
|
|
include libs/master.lib/txesc.asm
|
2014-08-31 03:52:43 +00:00
|
|
|
|
include libs/master.lib/text_putsa.asm
|
2014-08-26 21:58:08 +00:00
|
|
|
|
include libs/master.lib/vsync.asm
|
2014-08-26 22:11:29 +00:00
|
|
|
|
include libs/master.lib/vsync_wait.asm
|
2014-08-26 22:52:29 +00:00
|
|
|
|
include libs/master.lib/palette_white_in.asm
|
2014-08-21 23:19:52 +00:00
|
|
|
|
include libs/master.lib/hmem_lallocate.asm
|
2014-08-21 21:30:20 +00:00
|
|
|
|
include libs/master.lib/mem_assign_dos.asm
|
2014-08-21 21:05:54 +00:00
|
|
|
|
include libs/master.lib/mem_assign.asm
|
2014-08-21 22:17:53 +00:00
|
|
|
|
include libs/master.lib/memheap.asm
|
2014-09-08 18:30:15 +00:00
|
|
|
|
include libs/master.lib/mem_unassign.asm
|
2014-08-22 21:45:21 +00:00
|
|
|
|
include libs/master.lib/super_free.asm
|
2014-08-22 22:17:59 +00:00
|
|
|
|
include libs/master.lib/super_entry_pat.asm
|
2014-08-22 21:56:33 +00:00
|
|
|
|
include libs/master.lib/super_entry_at.asm
|
2014-08-23 16:07:02 +00:00
|
|
|
|
include libs/master.lib/super_entry_bfnt.asm
|
2014-08-22 21:33:18 +00:00
|
|
|
|
include libs/master.lib/super_cancel_pat.asm
|
2014-08-28 00:13:13 +00:00
|
|
|
|
include libs/master.lib/super_put.asm
|
2014-09-03 13:23:51 +00:00
|
|
|
|
include libs/master.lib/respal_exist.asm
|
2014-09-03 13:41:25 +00:00
|
|
|
|
include libs/master.lib/respal_free.asm
|
2014-11-16 03:00:41 +00:00
|
|
|
|
include libs/master.lib/pfint21.asm
|
2014-06-29 22:52:27 +00:00
|
|
|
|
db 0
|
2018-04-15 12:51:57 +00:00
|
|
|
|
include libs/master.lib/js_start.asm
|
2018-04-15 21:31:38 +00:00
|
|
|
|
include libs/master.lib/js_sense.asm
|
2014-06-29 22:52:27 +00:00
|
|
|
|
db 0
|
2014-08-31 16:08:50 +00:00
|
|
|
|
include libs/master.lib/draw_trapezoid.asm
|
2014-11-17 03:54:40 +00:00
|
|
|
|
include th03/formats/pfopen.asm
|
|
|
|
|
include libs/master.lib/pf_str_ieq.asm
|
2015-02-18 11:07:37 +00:00
|
|
|
|
_TEXT ends
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
; ===========================================================================
|
|
|
|
|
|
|
|
|
|
; Segment type: Pure code
|
2015-02-21 11:47:24 +00:00
|
|
|
|
op_01_TEXT segment byte public 'CODE' use16
|
2021-12-20 17:16:11 +00:00
|
|
|
|
assume cs:group_01
|
2014-06-29 22:52:27 +00:00
|
|
|
|
;org 8
|
2015-02-18 11:07:37 +00:00
|
|
|
|
assume es:nothing, ss:nothing, ds:_DATA, fs:nothing, gs:nothing
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2020-09-06 17:28:52 +00:00
|
|
|
|
CFG_LOAD procdesc pascal near
|
|
|
|
|
CFG_SAVE procdesc pascal near
|
|
|
|
|
CFG_SAVE_EXIT procdesc pascal near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
2019-12-08 05:32:01 +00:00
|
|
|
|
public START_GAME
|
|
|
|
|
start_game proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
var_4 = word ptr -4
|
|
|
|
|
var_2 = word ptr -2
|
|
|
|
|
|
|
|
|
|
enter 4, 0
|
|
|
|
|
push si
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.demo_num], 0
|
|
|
|
|
mov es:[bx+resident_t.pid_winner], 0
|
|
|
|
|
mov es:[bx+resident_t.story_stage], 0
|
|
|
|
|
mov es:[bx+resident_t.RESIDENT_is_cpu][0], 0
|
|
|
|
|
mov es:[bx+resident_t.RESIDENT_is_cpu][1], 1
|
|
|
|
|
mov es:[bx+resident_t.game_mode], GM_STORY
|
|
|
|
|
mov es:[bx+resident_t.story_lives], CREDIT_LIVES
|
|
|
|
|
mov es:[bx+resident_t.show_score_menu], 0
|
|
|
|
|
mov es:[bx+resident_t.RESIDENT_playchar_paletted][1], -1
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_BD9A
|
|
|
|
|
or al, al
|
|
|
|
|
jz short loc_9A59
|
|
|
|
|
mov al, 1
|
|
|
|
|
jmp loc_9B9A
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9A59:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, es:[bx+resident_t.RESIDENT_playchar_paletted][0]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
dec ax
|
|
|
|
|
cwd
|
|
|
|
|
sub ax, dx
|
|
|
|
|
mov bx, ax
|
|
|
|
|
sar bx, 1
|
|
|
|
|
mov al, [bx+0A0h]
|
|
|
|
|
mov ah, 0
|
|
|
|
|
mov [bp+var_4], ax
|
2019-12-30 14:48:17 +00:00
|
|
|
|
mov bx, word ptr _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov eax, es:[bx+resident_t.rand]
|
2014-08-30 10:13:04 +00:00
|
|
|
|
mov random_seed, eax
|
2014-06-29 22:52:27 +00:00
|
|
|
|
xor si, si
|
|
|
|
|
jmp short loc_9ADB
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9A85:
|
2014-08-30 10:13:04 +00:00
|
|
|
|
call IRand
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov bx, 7
|
|
|
|
|
cwd
|
|
|
|
|
idiv bx
|
|
|
|
|
mov [bp+var_2], dx
|
|
|
|
|
mov bx, [bp+var_2]
|
|
|
|
|
cmp byte ptr [bx+99h], 0
|
|
|
|
|
jnz short loc_9A85
|
|
|
|
|
mov ax, [bp+var_4]
|
|
|
|
|
cmp ax, [bp+var_2]
|
|
|
|
|
jz short loc_9A85
|
|
|
|
|
mov byte ptr [bx+99h], 1
|
|
|
|
|
mov ax, [bp+var_2]
|
|
|
|
|
add ax, ax
|
|
|
|
|
inc ax
|
|
|
|
|
mov [bp+var_2], ax
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2014-06-29 22:52:27 +00:00
|
|
|
|
add bx, si
|
|
|
|
|
mov al, byte ptr [bp+var_2]
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.story_opponents], al
|
2019-12-30 14:48:17 +00:00
|
|
|
|
mov bx, word ptr _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, es:[bx+resident_t.RESIDENT_playchar_paletted][0]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
cmp ax, [bp+var_2]
|
|
|
|
|
jnz short loc_9ADA
|
|
|
|
|
add bx, si
|
|
|
|
|
mov al, byte ptr [bp+var_2]
|
|
|
|
|
inc al
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.story_opponents], al
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9ADA:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc si
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9ADB:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp si, 6
|
|
|
|
|
jl short loc_9A85
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, es:[bx+resident_t.story_opponents]
|
|
|
|
|
mov es:[bx+resident_t.RESIDENT_playchar_paletted][1], al
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, byte ptr [bp+var_4]
|
|
|
|
|
add al, al
|
|
|
|
|
inc al
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.story_opponents][6], al
|
|
|
|
|
mov es:[bx+resident_t.story_opponents][7], (1 + (PLAYCHAR_CHIYURI * 2))
|
|
|
|
|
cmp es:[bx+resident_t.RESIDENT_playchar_paletted][0], (1 + (PLAYCHAR_CHIYURI * 2))
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_9B07
|
2020-02-19 16:45:19 +00:00
|
|
|
|
inc es:[bx+resident_t.story_opponents][7]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9B07:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.story_opponents][8], (1 + (PLAYCHAR_YUMEMI * 2))
|
|
|
|
|
cmp es:[bx+resident_t.RESIDENT_playchar_paletted][0], (1 + (PLAYCHAR_YUMEMI * 2))
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_9B1B
|
2020-02-19 16:45:19 +00:00
|
|
|
|
inc es:[bx+resident_t.story_opponents][8]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9B1B:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
xor si, si
|
|
|
|
|
jmp short loc_9B39
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9B1F:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2014-06-29 22:52:27 +00:00
|
|
|
|
add bx, si
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, es:[bx+resident_t.story_opponents]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
dec ax
|
|
|
|
|
cwd
|
|
|
|
|
sub ax, dx
|
|
|
|
|
sar ax, 1
|
|
|
|
|
cmp ax, 9
|
|
|
|
|
jge loc_9A59
|
|
|
|
|
inc si
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9B39:
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp si, STAGE_COUNT
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jl short loc_9B1F
|
|
|
|
|
xor si, si
|
|
|
|
|
jmp short loc_9B4E
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9B42:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2014-06-29 22:52:27 +00:00
|
|
|
|
add bx, si
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.score_last], 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc si
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9B4E:
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp si, (PLAYER_COUNT * SCORE_DIGITS)
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jl short loc_9B42
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.rem_credits], 3
|
|
|
|
|
mov es:[bx+resident_t.op_skip_animation], 0
|
|
|
|
|
mov al, es:[bx+resident_t.rank]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
2020-02-19 16:45:19 +00:00
|
|
|
|
imul ax, 25
|
|
|
|
|
add al, 70
|
|
|
|
|
mov es:[bx+resident_t.skill], al
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call cfg_save
|
2014-08-31 08:23:41 +00:00
|
|
|
|
call gaiji_restore
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_STOP
|
2020-09-06 18:38:59 +00:00
|
|
|
|
call _game_exit
|
2014-11-19 11:09:22 +00:00
|
|
|
|
pushd 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
|
|
|
|
push offset path ; "mainl"
|
|
|
|
|
push ds
|
|
|
|
|
push offset path ; "mainl"
|
|
|
|
|
call _execl
|
|
|
|
|
add sp, 0Ch
|
|
|
|
|
mov al, 0
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9B9A:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop si
|
|
|
|
|
leave
|
|
|
|
|
retn
|
2019-12-08 05:32:01 +00:00
|
|
|
|
start_game endp
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_9B9D proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
arg_0 = word ptr 4
|
|
|
|
|
arg_2 = word ptr 6
|
|
|
|
|
|
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
|
|
|
|
push di
|
|
|
|
|
mov di, [bp+arg_2]
|
|
|
|
|
mov si, [bp+arg_0]
|
|
|
|
|
or di, di
|
|
|
|
|
jnz short loc_9BB8
|
2014-11-19 11:09:22 +00:00
|
|
|
|
push 1B0012h
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gp1P_VS_CPU
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_9BD3
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9BB8:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp di, 1
|
|
|
|
|
jnz short loc_9BC9
|
2014-11-19 11:09:22 +00:00
|
|
|
|
push 1B0013h
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gp1P_VS_2P
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_9BD3
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9BC9:
|
2014-11-19 11:09:22 +00:00
|
|
|
|
push 1B0014h
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gpCPU_VS_CPU
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9BD3:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push si
|
2014-08-31 03:05:48 +00:00
|
|
|
|
call gaiji_putsa
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop di
|
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retn 4
|
|
|
|
|
sub_9B9D endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
2019-12-08 05:32:01 +00:00
|
|
|
|
public START_VS
|
|
|
|
|
start_vs proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
var_2 = word ptr -2
|
|
|
|
|
|
|
|
|
|
enter 2, 0
|
|
|
|
|
push si
|
|
|
|
|
xor si, si
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp es:[bx+resident_t.game_mode], GM_VS
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnb loc_9C8B
|
2014-08-20 14:45:24 +00:00
|
|
|
|
call text_clear
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_B0AF
|
|
|
|
|
mov [bp+var_2], 0
|
2014-11-19 11:09:22 +00:00
|
|
|
|
pushd 0E1h
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_9B9D
|
2014-11-19 11:09:22 +00:00
|
|
|
|
push 10001h
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_9B9D
|
2014-11-19 11:09:22 +00:00
|
|
|
|
push 20001h
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_9B9D
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9C1B:
|
2019-11-30 14:48:36 +00:00
|
|
|
|
call input_mode_interface
|
2014-06-29 22:52:27 +00:00
|
|
|
|
or si, si
|
|
|
|
|
jnz short loc_9C7E
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.lo, low INPUT_UP
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_9C4A
|
|
|
|
|
push [bp+var_2]
|
|
|
|
|
push 1
|
|
|
|
|
call sub_9B9D
|
|
|
|
|
dec [bp+var_2]
|
|
|
|
|
cmp [bp+var_2], 0
|
|
|
|
|
jge short loc_9C41
|
|
|
|
|
mov [bp+var_2], 2
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9C41:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push [bp+var_2]
|
2014-09-18 15:20:12 +00:00
|
|
|
|
push 0E1h
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_9B9D
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9C4A:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.lo, low INPUT_DOWN
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_9C70
|
|
|
|
|
push [bp+var_2]
|
|
|
|
|
push 1
|
|
|
|
|
call sub_9B9D
|
|
|
|
|
inc [bp+var_2]
|
|
|
|
|
cmp [bp+var_2], 2
|
|
|
|
|
jle short loc_9C67
|
|
|
|
|
mov [bp+var_2], 0
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9C67:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push [bp+var_2]
|
2014-09-18 15:20:12 +00:00
|
|
|
|
push 0E1h
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_9B9D
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9C70:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.lo, low INPUT_SHOT
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_9C9B
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.hi, high INPUT_OK
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_9C9B
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9C7E:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
mov si, _input_sp
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 1
|
2014-11-23 21:25:22 +00:00
|
|
|
|
call frame_delay
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_9C1B
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9C8B:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, es:[bx+resident_t.game_mode]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
2020-02-19 16:45:19 +00:00
|
|
|
|
add ax, -GM_VS
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov [bp+var_2], ax
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9C9B:
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp [bp+var_2], VS_CPU_CPU
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_9CA5
|
|
|
|
|
mov al, 1
|
|
|
|
|
jmp short loc_9CA7
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9CA5:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, 0
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9CA7:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.RESIDENT_is_cpu][0], al
|
|
|
|
|
cmp [bp+var_2], VS_1P_2P
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_9CB9
|
|
|
|
|
mov al, 1
|
|
|
|
|
jmp short loc_9CBB
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9CB9:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, 0
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9CBB:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.RESIDENT_is_cpu][1], al
|
|
|
|
|
mov es:[bx+resident_t.demo_num], 0
|
|
|
|
|
mov es:[bx+resident_t.pid_winner], 0
|
|
|
|
|
mov es:[bx+resident_t.story_stage], 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, byte ptr [bp+var_2]
|
2020-02-19 16:45:19 +00:00
|
|
|
|
add al, GM_VS
|
|
|
|
|
mov es:[bx+resident_t.game_mode], al
|
|
|
|
|
mov es:[bx+resident_t.show_score_menu], 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp [bp+var_2], 1
|
|
|
|
|
jnz short loc_9CEF
|
|
|
|
|
call sub_BA88
|
|
|
|
|
or al, al
|
|
|
|
|
jz short loc_9D03
|
|
|
|
|
jmp short loc_9CF6
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9CEF:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_BC1F
|
|
|
|
|
or al, al
|
|
|
|
|
jz short loc_9D03
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9CF6:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.game_mode], GM_NONE
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, 1
|
|
|
|
|
jmp short loc_9D49
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9D03:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov [bp+var_2], 0
|
|
|
|
|
jmp short loc_9D19
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9D0A:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2014-06-29 22:52:27 +00:00
|
|
|
|
add bx, [bp+var_2]
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.score_last], 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc [bp+var_2]
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9D19:
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp [bp+var_2], (PLAYER_COUNT * SCORE_DIGITS)
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jl short loc_9D0A
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call cfg_save
|
2014-08-31 08:23:41 +00:00
|
|
|
|
call gaiji_restore
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_STOP
|
2020-09-06 18:38:59 +00:00
|
|
|
|
call _game_exit
|
2014-11-19 11:09:22 +00:00
|
|
|
|
pushd 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
|
|
|
|
push offset path ; "mainl"
|
|
|
|
|
push ds
|
|
|
|
|
push offset path ; "mainl"
|
|
|
|
|
call _execl
|
|
|
|
|
add sp, 0Ch
|
|
|
|
|
mov al, 0
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9D49:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop si
|
|
|
|
|
leave
|
|
|
|
|
retn
|
2019-12-08 05:32:01 +00:00
|
|
|
|
start_vs endp
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2020-02-21 14:08:10 +00:00
|
|
|
|
include th03/start.asm
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_9E16 proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
2018-09-11 17:34:19 +00:00
|
|
|
|
mov _input_sp, INPUT_NONE
|
2014-06-29 22:52:27 +00:00
|
|
|
|
xor si, si
|
|
|
|
|
jmp short loc_9E43
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9E24:
|
2019-11-30 14:48:36 +00:00
|
|
|
|
call input_mode_interface
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
inc es:[bx+resident_t.rand]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc si
|
|
|
|
|
cmp si, 208h
|
|
|
|
|
jle short loc_9E3C
|
2020-02-21 14:08:10 +00:00
|
|
|
|
call start_demo
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9E3C:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 1
|
2014-11-23 21:25:22 +00:00
|
|
|
|
call frame_delay
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9E43:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
cmp _input_sp, INPUT_NONE
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_9E24
|
2019-12-22 13:04:34 +00:00
|
|
|
|
call super_put pascal, large (160 shl 16) or 256, 0
|
|
|
|
|
mov si, 176
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_9E76
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9E5C:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push si
|
|
|
|
|
call sub_B10A
|
2019-12-22 13:04:34 +00:00
|
|
|
|
call super_put pascal, si, large (256 shl 16) or 2
|
|
|
|
|
call frame_delay pascal, 1
|
2014-06-29 22:52:27 +00:00
|
|
|
|
add si, 8
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9E76:
|
2019-12-22 13:04:34 +00:00
|
|
|
|
cmp si, 288
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jl short loc_9E5C
|
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retn
|
|
|
|
|
sub_9E16 endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
2019-12-07 10:37:53 +00:00
|
|
|
|
public SCORE_MENU
|
|
|
|
|
score_menu proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.story_stage], STAGE_NONE
|
|
|
|
|
mov es:[bx+resident_t.show_score_menu], 1
|
|
|
|
|
mov es:[bx+resident_t.game_mode], GM_NONE
|
2014-06-29 22:52:27 +00:00
|
|
|
|
xor si, si
|
|
|
|
|
jmp short loc_9EA6
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9E9A:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2014-06-29 22:52:27 +00:00
|
|
|
|
add bx, si
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.score_last], 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc si
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9EA6:
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp si, (PLAYER_COUNT * SCORE_DIGITS)
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jl short loc_9E9A
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call cfg_save
|
2014-08-31 08:23:41 +00:00
|
|
|
|
call gaiji_restore
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_STOP
|
2014-08-22 21:45:21 +00:00
|
|
|
|
call super_free
|
2020-09-06 18:38:59 +00:00
|
|
|
|
call _game_exit
|
2014-11-19 11:09:22 +00:00
|
|
|
|
pushd 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
|
|
|
|
push offset path ; "mainl"
|
|
|
|
|
push ds
|
|
|
|
|
push offset path ; "mainl"
|
|
|
|
|
call _execl
|
|
|
|
|
add sp, 0Ch
|
|
|
|
|
mov al, 0
|
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retn
|
2019-12-07 10:37:53 +00:00
|
|
|
|
score_menu endp
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
2019-12-08 05:32:01 +00:00
|
|
|
|
public MAIN_PUT
|
|
|
|
|
main_put proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
arg_0 = word ptr 4
|
|
|
|
|
arg_2 = word ptr 6
|
|
|
|
|
|
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
|
|
|
|
push di
|
|
|
|
|
mov si, [bp+arg_2]
|
|
|
|
|
mov di, [bp+arg_0]
|
|
|
|
|
or si, si
|
|
|
|
|
jnz short loc_9EF8
|
2014-12-20 21:14:58 +00:00
|
|
|
|
push (25 shl 16) + 17
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gpSTART
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_9F4B
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9EF8:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp si, 1
|
|
|
|
|
jnz short loc_9F09
|
2014-12-20 21:14:58 +00:00
|
|
|
|
push (23 shl 16) + 18
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gpVS_START
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_9F4B
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9F09:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp si, 2
|
|
|
|
|
jnz short loc_9F1A
|
2014-12-20 21:14:58 +00:00
|
|
|
|
push (22 shl 16) + 19
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gpMUSIC_ROOM
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_9F4B
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9F1A:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp si, 3
|
|
|
|
|
jnz short loc_9F2B
|
2014-12-20 21:14:58 +00:00
|
|
|
|
push (24 shl 16) + 20
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gpHISCORE
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_9F4B
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9F2B:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp si, 4
|
|
|
|
|
jnz short loc_9F3C
|
2014-12-20 21:14:58 +00:00
|
|
|
|
push (25 shl 16) + 21
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gpOPTION
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_9F4B
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9F3C:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp si, 5
|
|
|
|
|
jnz short loc_9F51
|
2014-12-20 21:14:58 +00:00
|
|
|
|
push (26 shl 16) + 22
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gpQUIT
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9F4B:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push di
|
2014-08-31 03:05:48 +00:00
|
|
|
|
call gaiji_putsa
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9F51:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop di
|
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retn 4
|
2019-12-08 05:32:01 +00:00
|
|
|
|
main_put endp
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
2019-12-08 05:32:01 +00:00
|
|
|
|
public OPTION_PUT
|
|
|
|
|
option_put proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
arg_0 = word ptr 4
|
|
|
|
|
arg_2 = word ptr 6
|
|
|
|
|
|
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
|
|
|
|
push di
|
|
|
|
|
mov di, [bp+arg_2]
|
|
|
|
|
mov si, [bp+arg_0]
|
|
|
|
|
or di, di
|
|
|
|
|
jnz short loc_9FD6
|
2014-12-20 21:14:58 +00:00
|
|
|
|
call gaiji_putsa pascal, (25 shl 16) + 17, ds offset gpRANK, si
|
|
|
|
|
call text_putsa pascal, (37 shl 16) + 17, ds, offset asc_D965, TX_WHITE
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, es:[bx+resident_t.rank]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
mov bx, ax
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp bx, RANK_LUNATIC
|
2014-06-29 22:52:27 +00:00
|
|
|
|
ja loc_A092
|
|
|
|
|
add bx, bx
|
|
|
|
|
jmp cs:off_A099[bx]
|
|
|
|
|
|
2020-02-19 16:45:19 +00:00
|
|
|
|
@@easy:
|
2014-12-20 21:14:58 +00:00
|
|
|
|
push (38 shl 16) + 17
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gpEASY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp loc_A08C
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2020-02-19 16:45:19 +00:00
|
|
|
|
@@normal:
|
2014-12-20 21:14:58 +00:00
|
|
|
|
push (37 shl 16) + 17
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gpNORMAL
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp loc_A08C
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2020-02-19 16:45:19 +00:00
|
|
|
|
@@hard:
|
2014-12-20 21:14:58 +00:00
|
|
|
|
push (38 shl 16) + 17
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gpHARD
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp loc_A08C
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2020-02-19 16:45:19 +00:00
|
|
|
|
@@lunatic:
|
2014-12-20 21:14:58 +00:00
|
|
|
|
push (37 shl 16) + 17
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gpLUNATIC
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp loc_A08C
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_9FD6:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp di, 1
|
|
|
|
|
jnz short loc_A02A
|
2014-12-20 21:14:58 +00:00
|
|
|
|
call gaiji_putsa pascal, (25 shl 16) + 19, ds, offset gpMUSIC, si
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, es:[bx+resident_t.bgm_mode]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
or ax, ax
|
|
|
|
|
jz short loc_A006
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp ax, SND_BGM_FM
|
|
|
|
|
jz short @@fm
|
|
|
|
|
cmp ax, SND_BGM_MIDI
|
|
|
|
|
jz short @@midi
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp loc_A092
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A006:
|
2014-12-20 21:14:58 +00:00
|
|
|
|
push (35 shl 16) + 19
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gpOFF
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A08C
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2020-02-19 16:45:19 +00:00
|
|
|
|
@@fm:
|
2014-12-20 21:14:58 +00:00
|
|
|
|
push (35 shl 16) + 19
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gpFM_86
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A08C
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2020-02-19 16:45:19 +00:00
|
|
|
|
@@midi:
|
2014-12-20 21:14:58 +00:00
|
|
|
|
push (35 shl 16) + 19
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gpMIDI_SC88
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A08C
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A02A:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp di, 2
|
|
|
|
|
jnz short loc_A07D
|
2014-12-20 21:14:58 +00:00
|
|
|
|
call gaiji_putsa pascal, (23 shl 16) + 21, ds, offset gpKEYCONFIG, si
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, es:[bx+resident_t.key_mode]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
or ax, ax
|
2020-02-19 16:45:19 +00:00
|
|
|
|
jz short @@key_vs_key
|
|
|
|
|
cmp ax, KM_JOY_KEY
|
|
|
|
|
jz short @@joy_vs_key
|
|
|
|
|
cmp ax, KM_KEY_JOY
|
|
|
|
|
jz short @@key_vs_joy
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A092
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2020-02-19 16:45:19 +00:00
|
|
|
|
@@key_vs_key:
|
2014-12-20 21:14:58 +00:00
|
|
|
|
push (37 shl 16) + 21
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gpKEY_VS_KEY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A08C
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2020-02-19 16:45:19 +00:00
|
|
|
|
@@joy_vs_key:
|
2014-12-20 21:14:58 +00:00
|
|
|
|
push (37 shl 16) + 21
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gpJOY_VS_KEY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A08C
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2020-02-19 16:45:19 +00:00
|
|
|
|
@@key_vs_joy:
|
2014-12-20 21:14:58 +00:00
|
|
|
|
push (37 shl 16) + 21
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gpKEY_VS_JOY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A08C
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A07D:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp di, 3
|
|
|
|
|
jnz short loc_A092
|
2014-12-20 21:14:58 +00:00
|
|
|
|
push (32 shl 16) + 22
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-13 10:24:35 +00:00
|
|
|
|
push offset gpQUIT
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A08C:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push si
|
2014-08-31 03:05:48 +00:00
|
|
|
|
call gaiji_putsa
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A092:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop di
|
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retn 4
|
|
|
|
|
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
db 0
|
2020-02-19 16:45:19 +00:00
|
|
|
|
off_A099 dw offset @@easy
|
|
|
|
|
dw offset @@normal
|
|
|
|
|
dw offset @@hard
|
|
|
|
|
dw offset @@lunatic
|
|
|
|
|
option_put endp
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
2019-12-08 05:32:01 +00:00
|
|
|
|
public MENU_SEL_MOVE
|
|
|
|
|
menu_sel_move proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
arg_0 = byte ptr 4
|
|
|
|
|
arg_2 = byte ptr 6
|
|
|
|
|
|
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov al, _menu_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
|
|
|
|
push ax
|
|
|
|
|
push 1
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call _putfunc
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, [bp+arg_0]
|
2019-12-08 05:32:01 +00:00
|
|
|
|
add _menu_sel, al
|
|
|
|
|
cmp _menu_sel, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jge short loc_A0C3
|
|
|
|
|
mov al, [bp+arg_2]
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov _menu_sel, al
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A0C3:
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov al, _menu_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp al, [bp+arg_2]
|
|
|
|
|
jle short loc_A0D0
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov _menu_sel, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A0D0:
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov al, _menu_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
|
|
|
|
push ax
|
2014-09-18 15:20:12 +00:00
|
|
|
|
push 0E1h
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call _putfunc
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop bp
|
|
|
|
|
retn 4
|
2019-12-08 05:32:01 +00:00
|
|
|
|
menu_sel_move endp
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
2019-12-08 05:32:01 +00:00
|
|
|
|
public MAIN_UPDATE_AND_RENDER
|
|
|
|
|
main_update_and_render proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
2019-12-08 05:32:01 +00:00
|
|
|
|
cmp _main_menu_initialized, 0
|
|
|
|
|
jnz short @@main_initialized
|
2014-08-20 14:45:24 +00:00
|
|
|
|
call text_clear
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp byte_D953, 0
|
|
|
|
|
jnz short loc_A0FA
|
|
|
|
|
call sub_B0DB
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A0FA:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov byte_D953, 0
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov _main_input_allowed, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
xor si, si
|
|
|
|
|
jmp short loc_A11E
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A108:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push si
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov al, _menu_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
|
|
|
|
cmp ax, si
|
|
|
|
|
jnz short loc_A116
|
2014-09-18 15:20:12 +00:00
|
|
|
|
mov ax, 0E1h
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A119
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A116:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ax, 1
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A119:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call main_put
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc si
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A11E:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp si, 6
|
|
|
|
|
jl short loc_A108
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov _putfunc, offset main_put
|
|
|
|
|
mov _main_menu_initialized, 1
|
|
|
|
|
mov _main_input_allowed, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2019-12-08 05:32:01 +00:00
|
|
|
|
@@main_initialized:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
cmp _input_sp, INPUT_NONE
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_A13F
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov _main_input_allowed, 1
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A13F:
|
2019-12-08 05:32:01 +00:00
|
|
|
|
cmp _main_input_allowed, 0
|
|
|
|
|
jz @@no_main_input_allowed
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.lo, low INPUT_UP
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_A156
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call menu_sel_move pascal, 5, -1
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A156:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.lo, low INPUT_DOWN
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_A164
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call menu_sel_move pascal, 5, 1
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A164:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.hi, high INPUT_OK
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_A172
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.lo, low INPUT_SHOT
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_A1DB
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A172:
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov al, _menu_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
|
|
|
|
mov bx, ax
|
|
|
|
|
cmp bx, 5
|
|
|
|
|
ja short loc_A1DB
|
|
|
|
|
add bx, bx
|
|
|
|
|
jmp cs:off_A1F7[bx]
|
|
|
|
|
|
2019-12-08 05:32:01 +00:00
|
|
|
|
menu_sel_start:
|
|
|
|
|
call start_game
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A19A
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2019-12-08 05:32:01 +00:00
|
|
|
|
menu_sel_vs_start:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.RESIDENT_playchar_paletted][0], (1 + (PLAYCHAR_REIMU * 2))
|
|
|
|
|
mov es:[bx+resident_t.RESIDENT_playchar_paletted][1], (1 + (PLAYCHAR_REIMU * 2))
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call start_vs
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A19A:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_B008
|
|
|
|
|
call sub_9E16
|
|
|
|
|
call sub_B3C3
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov _main_menu_initialized, 0
|
|
|
|
|
mov _main_input_allowed, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov byte_D953, 1
|
2019-12-08 05:32:01 +00:00
|
|
|
|
jmp short @@no_main_input_allowed
|
2014-06-29 22:52:27 +00:00
|
|
|
|
; ---------------------------------------------------------------------------
|
2014-11-12 22:11:16 +00:00
|
|
|
|
|
2019-12-08 05:32:01 +00:00
|
|
|
|
menu_sel_musicroom:
|
2019-11-25 11:09:11 +00:00
|
|
|
|
nopcall musicroom
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A19A
|
|
|
|
|
; ---------------------------------------------------------------------------
|
2014-11-12 22:11:16 +00:00
|
|
|
|
|
2019-12-08 05:32:01 +00:00
|
|
|
|
menu_sel_hiscore:
|
2019-12-07 10:37:53 +00:00
|
|
|
|
call score_menu
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A1DB
|
|
|
|
|
; ---------------------------------------------------------------------------
|
2014-11-12 22:11:16 +00:00
|
|
|
|
|
2019-12-08 05:32:01 +00:00
|
|
|
|
menu_sel_option:
|
|
|
|
|
mov _main_menu_initialized, 0
|
|
|
|
|
mov _in_option, 1
|
|
|
|
|
mov _menu_sel, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A1DB
|
|
|
|
|
; ---------------------------------------------------------------------------
|
2014-11-12 22:11:16 +00:00
|
|
|
|
|
2019-12-08 05:32:01 +00:00
|
|
|
|
menu_sel_quit:
|
|
|
|
|
mov _main_menu_initialized, 0
|
|
|
|
|
mov _quit, 1
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A1DB:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.hi, high INPUT_CANCEL
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_A1E7
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov _quit, 1
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A1E7:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
cmp _input_sp, INPUT_NONE
|
2019-12-08 05:32:01 +00:00
|
|
|
|
jz short @@no_main_input_allowed
|
|
|
|
|
mov _main_input_allowed, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2019-12-08 05:32:01 +00:00
|
|
|
|
@@no_main_input_allowed:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retn
|
2019-12-08 05:32:01 +00:00
|
|
|
|
main_update_and_render endp
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
db 0
|
2019-12-08 05:32:01 +00:00
|
|
|
|
off_A1F7 dw offset menu_sel_start
|
|
|
|
|
dw offset menu_sel_vs_start
|
|
|
|
|
dw offset menu_sel_musicroom
|
|
|
|
|
dw offset menu_sel_hiscore
|
|
|
|
|
dw offset menu_sel_option
|
|
|
|
|
dw offset menu_sel_quit
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
2019-12-08 05:32:01 +00:00
|
|
|
|
public OPTION_UPDATE_AND_RENDER
|
|
|
|
|
option_update_and_render proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
2019-12-08 05:32:01 +00:00
|
|
|
|
cmp _option_initialized, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_A24A
|
2014-08-20 14:45:24 +00:00
|
|
|
|
call text_clear
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_B0AF
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov _option_input_allowed, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
xor si, si
|
|
|
|
|
jmp short loc_A235
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A21F:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push si
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov al, _menu_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
|
|
|
|
cmp ax, si
|
|
|
|
|
jnz short loc_A22D
|
2014-12-20 21:14:58 +00:00
|
|
|
|
mov ax, TX_WHITE
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A230
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A22D:
|
2014-12-20 21:14:58 +00:00
|
|
|
|
mov ax, TX_BLACK
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A230:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call option_put
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc si
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A235:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp si, 4
|
|
|
|
|
jl short loc_A21F
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov _putfunc, offset option_put
|
|
|
|
|
mov _option_initialized, 1
|
|
|
|
|
mov _option_input_allowed, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A24A:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
cmp _input_sp, INPUT_NONE
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_A256
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov _option_input_allowed, 1
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A256:
|
2019-12-08 05:32:01 +00:00
|
|
|
|
cmp _option_input_allowed, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz loc_A414
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.lo, low INPUT_UP
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_A26D
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call menu_sel_move pascal, 3, -1
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A26D:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.lo, low INPUT_DOWN
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_A27B
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call menu_sel_move pascal, 3, 1
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A27B:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.lo, low INPUT_RIGHT
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz loc_A31D
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov al, _menu_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
|
|
|
|
or ax, ax
|
|
|
|
|
jz short loc_A298
|
|
|
|
|
cmp ax, 1
|
|
|
|
|
jz short loc_A2AE
|
|
|
|
|
cmp ax, 2
|
|
|
|
|
jz short loc_A2FE
|
|
|
|
|
jmp short loc_A312
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A298:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
inc es:[bx+resident_t.rank]
|
|
|
|
|
cmp es:[bx+resident_t.rank], RANK_LUNATIC
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jbe short loc_A312
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.rank], RANK_EASY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A312
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A2AE:
|
2020-02-22 11:55:34 +00:00
|
|
|
|
cmp _snd_sel_disabled, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_A312
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp es:[bx+resident_t.bgm_mode], SND_BGM_OFF
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_A2DB
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.bgm_mode], SND_BGM_FM
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_STOP
|
2020-09-06 16:13:07 +00:00
|
|
|
|
call _snd_determine_mode
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_PLAY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A2F1
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A2DB:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.bgm_mode], SND_BGM_OFF
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_STOP
|
2015-02-23 10:47:22 +00:00
|
|
|
|
mov _snd_active, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A2F1:
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov al, _menu_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
|
|
|
|
push ax
|
2014-09-18 15:20:12 +00:00
|
|
|
|
push 0E1h
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call option_put
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A312
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A2FE:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
inc es:[bx+resident_t.key_mode]
|
|
|
|
|
cmp es:[bx+resident_t.key_mode], KM_KEY_JOY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jbe short loc_A312
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.key_mode], KM_KEY_KEY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A312:
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov al, _menu_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
|
|
|
|
push ax
|
2014-09-18 15:20:12 +00:00
|
|
|
|
push 0E1h
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call option_put
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A31D:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.lo, low INPUT_LEFT
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz loc_A3CC
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov al, _menu_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
|
|
|
|
or ax, ax
|
|
|
|
|
jz short loc_A33B
|
|
|
|
|
cmp ax, 1
|
|
|
|
|
jz short loc_A357
|
|
|
|
|
cmp ax, 2
|
|
|
|
|
jz short loc_A3A7
|
|
|
|
|
jmp loc_A3C1
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A33B:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp es:[bx+resident_t.rank], RANK_EASY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_A34D
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.rank], RANK_LUNATIC
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A3C1
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A34D:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
dec es:[bx+resident_t.rank]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A3C1
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A357:
|
2020-02-22 11:55:34 +00:00
|
|
|
|
cmp _snd_sel_disabled, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_A3C1
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp es:[bx+resident_t.bgm_mode], SND_BGM_OFF
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_A384
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.bgm_mode], SND_BGM_FM
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_STOP
|
2020-09-06 16:13:07 +00:00
|
|
|
|
call _snd_determine_mode
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_PLAY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A39A
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A384:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.bgm_mode], SND_BGM_OFF
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_STOP
|
2015-02-23 10:47:22 +00:00
|
|
|
|
mov _snd_active, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A39A:
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov al, _menu_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
|
|
|
|
push ax
|
2014-09-18 15:20:12 +00:00
|
|
|
|
push 0E1h
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call option_put
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A3C1
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A3A7:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp es:[bx+resident_t.key_mode], KM_KEY_KEY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_A3B9
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.key_mode], KM_KEY_JOY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A3C1
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A3B9:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
dec es:[bx+resident_t.key_mode]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A3C1:
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov al, _menu_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
|
|
|
|
push ax
|
2014-09-18 15:20:12 +00:00
|
|
|
|
push 0E1h
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call option_put
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A3CC:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.hi, high INPUT_OK
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_A3DA
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.lo, low INPUT_SHOT
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_A3F2
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A3DA:
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov al, _menu_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
|
|
|
|
cmp ax, 3
|
|
|
|
|
jnz short loc_A3F2
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov _option_initialized, 0
|
|
|
|
|
mov _menu_sel, 4
|
|
|
|
|
mov _in_option, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A3F2:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.hi, high INPUT_CANCEL
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_A408
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov _option_initialized, 0
|
|
|
|
|
mov _menu_sel, 4
|
|
|
|
|
mov _in_option, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A408:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
cmp _input_sp, INPUT_NONE
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_A414
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov _option_input_allowed, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A414:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retn
|
2019-12-08 05:32:01 +00:00
|
|
|
|
option_update_and_render endp
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
|
|
|
|
; int __cdecl main(int argc, const char **argv, const char **envp)
|
2015-02-19 06:46:36 +00:00
|
|
|
|
public _main
|
2014-08-10 01:44:54 +00:00
|
|
|
|
_main proc far
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
_argc = word ptr 6
|
|
|
|
|
_argv = dword ptr 8
|
|
|
|
|
_envp = dword ptr 0Ch
|
|
|
|
|
|
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
2014-08-27 22:58:40 +00:00
|
|
|
|
call graph_400line
|
2014-08-20 14:45:24 +00:00
|
|
|
|
call text_clear
|
2014-09-03 13:23:51 +00:00
|
|
|
|
call respal_create
|
2014-08-27 03:42:48 +00:00
|
|
|
|
cmp graph_VramZoom, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_A452
|
|
|
|
|
push ds
|
2014-09-18 15:20:12 +00:00
|
|
|
|
push offset aVfvcvbgngngbgn
|
2014-08-22 23:48:16 +00:00
|
|
|
|
call dos_puts2
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-18 15:20:12 +00:00
|
|
|
|
push offset aUmx
|
2014-08-22 23:48:16 +00:00
|
|
|
|
call dos_puts2
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
2014-09-18 15:20:12 +00:00
|
|
|
|
push offset aViosrfvVVkvqbd
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A446:
|
2014-08-22 23:48:16 +00:00
|
|
|
|
call dos_puts2
|
2015-02-19 06:46:36 +00:00
|
|
|
|
call _getch
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop bp
|
|
|
|
|
retf
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A452:
|
2019-11-19 14:26:47 +00:00
|
|
|
|
call _game_init_op c, offset aCOul, ds
|
2014-06-29 22:52:27 +00:00
|
|
|
|
or ax, ax
|
|
|
|
|
jz short loc_A468
|
|
|
|
|
push ds
|
|
|
|
|
push offset aGbgvgkxsslvVBb ; "\n<><6E><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>ł<EFBFBD><C582>B<EFBFBD><42><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>𑝂₵<F0919D82>Ă<EFBFBD>"...
|
|
|
|
|
jmp short loc_A446
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A468:
|
2014-08-31 08:23:41 +00:00
|
|
|
|
call gaiji_backup
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
|
|
|
|
push offset aMikoft_bft ; "MIKOFT.bft"
|
2014-08-31 08:08:09 +00:00
|
|
|
|
call gaiji_entry_bfnt
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call cfg_load
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp es:[bx+resident_t.game_mode], GM_VS
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jb short loc_A497
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp es:[bx+resident_t.demo_num], 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_A497
|
|
|
|
|
call sub_B38D
|
|
|
|
|
call sub_B3EF
|
|
|
|
|
call sub_B3C3
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call start_vs
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A497:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp es:[bx+resident_t.op_skip_animation], 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_A4B0
|
|
|
|
|
call sub_ADE2
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.op_skip_animation], 1
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A4BC
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A4B0:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.op_skip_animation], 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_B008
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A4BC:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_9E16
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov _in_option, 0
|
2018-09-11 17:34:19 +00:00
|
|
|
|
mov _input_sp, INPUT_NONE
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call main_update_and_render
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_B3C3
|
|
|
|
|
jmp short loc_A4FE
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A4D2:
|
2019-11-30 14:48:36 +00:00
|
|
|
|
call input_mode_interface
|
2019-12-08 05:32:01 +00:00
|
|
|
|
mov al, _in_option
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
|
|
|
|
or ax, ax
|
2019-12-08 05:32:01 +00:00
|
|
|
|
jz short @@not_in_option
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp ax, 1
|
2019-12-08 05:32:01 +00:00
|
|
|
|
jz short @@in_option
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A4EE
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2019-12-08 05:32:01 +00:00
|
|
|
|
@@not_in_option:
|
|
|
|
|
call main_update_and_render
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_A4EE
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2019-12-08 05:32:01 +00:00
|
|
|
|
@@in_option:
|
|
|
|
|
call option_update_and_render
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A4EE:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
inc es:[bx+resident_t.rand]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 1
|
2014-11-23 21:25:22 +00:00
|
|
|
|
call frame_delay
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A4FE:
|
2019-12-08 05:32:01 +00:00
|
|
|
|
cmp _quit, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_A4D2
|
2019-12-08 05:32:01 +00:00
|
|
|
|
call cfg_save_exit
|
2014-08-31 08:23:41 +00:00
|
|
|
|
call gaiji_restore
|
2014-08-20 14:45:24 +00:00
|
|
|
|
call text_clear
|
2020-09-06 18:38:59 +00:00
|
|
|
|
call _game_exit_to_dos
|
2014-09-03 13:41:25 +00:00
|
|
|
|
call respal_free
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop bp
|
|
|
|
|
retf
|
|
|
|
|
_main endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
2019-11-25 11:09:11 +00:00
|
|
|
|
public DRAW_TRACK
|
|
|
|
|
draw_track proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2019-11-25 11:09:11 +00:00
|
|
|
|
var_1 = byte ptr -1
|
|
|
|
|
@@color = byte ptr 4
|
|
|
|
|
@@sel = byte ptr 6
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
enter 2, 0
|
|
|
|
|
mov al, 1
|
2019-11-25 11:09:11 +00:00
|
|
|
|
sub al, _music_page
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov [bp+var_1], al
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage al
|
2019-12-21 17:08:24 +00:00
|
|
|
|
push 16
|
2019-11-25 11:09:11 +00:00
|
|
|
|
mov al, [bp+@@sel]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
shl ax, 4
|
2019-12-21 17:08:24 +00:00
|
|
|
|
add ax, 40
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2019-11-25 11:09:11 +00:00
|
|
|
|
mov al, [bp+@@color]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
2020-10-26 13:30:35 +00:00
|
|
|
|
or ax, FX_WEIGHT_BOLD
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2019-11-25 11:09:11 +00:00
|
|
|
|
mov al, [bp+@@sel]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
shl ax, 2
|
|
|
|
|
mov bx, ax
|
2019-12-05 02:53:01 +00:00
|
|
|
|
pushd _MUSIC_TITLES[bx]
|
2019-11-20 04:08:50 +00:00
|
|
|
|
call graph_putsa_fx
|
2019-11-25 11:09:11 +00:00
|
|
|
|
graph_accesspage _music_page
|
2019-12-21 17:08:24 +00:00
|
|
|
|
push 16
|
2019-11-25 11:09:11 +00:00
|
|
|
|
mov al, [bp+@@sel]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
shl ax, 4
|
2019-12-21 17:08:24 +00:00
|
|
|
|
add ax, 40
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2019-11-25 11:09:11 +00:00
|
|
|
|
mov al, [bp+@@color]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
2020-10-26 13:30:35 +00:00
|
|
|
|
or ax, FX_WEIGHT_BOLD
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2019-11-25 11:09:11 +00:00
|
|
|
|
mov al, [bp+@@sel]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
shl ax, 2
|
|
|
|
|
mov bx, ax
|
2019-12-05 02:53:01 +00:00
|
|
|
|
pushd _MUSIC_TITLES[bx]
|
2019-11-20 04:08:50 +00:00
|
|
|
|
call graph_putsa_fx
|
2014-06-29 22:52:27 +00:00
|
|
|
|
leave
|
|
|
|
|
retn 4
|
2019-11-25 11:09:11 +00:00
|
|
|
|
draw_track endp
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
2019-11-25 11:09:11 +00:00
|
|
|
|
public DRAW_TRACKS
|
|
|
|
|
draw_tracks proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2019-11-25 11:09:11 +00:00
|
|
|
|
@@sel = byte ptr 4
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
|
|
|
|
xor si, si
|
|
|
|
|
jmp short loc_A5AD
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A598:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push si
|
2019-11-25 11:09:11 +00:00
|
|
|
|
mov al, [bp+@@sel]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
cmp ax, si
|
|
|
|
|
jnz short loc_A5A6
|
|
|
|
|
mov al, 0Fh
|
|
|
|
|
jmp short loc_A5A8
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A5A6:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, 3
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A5A8:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2019-11-25 11:09:11 +00:00
|
|
|
|
call draw_track
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc si
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_A5AD:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp si, 15h
|
|
|
|
|
jl short loc_A598
|
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retn 2
|
2019-11-25 11:09:11 +00:00
|
|
|
|
draw_tracks endp
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2022-03-12 20:31:36 +00:00
|
|
|
|
include th02/op/music.asm
|
|
|
|
|
include th03/op/cmt_back_snap.asm
|
|
|
|
|
include th02/op/music_cmt_load.asm
|
|
|
|
|
include th03/op/cmt_back_free_put.asm
|
|
|
|
|
include th03/op/draw_cmt.asm
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
2019-11-25 11:09:11 +00:00
|
|
|
|
public MUSICROOM
|
|
|
|
|
musicroom proc far
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
|
|
|
|
xor si, si
|
|
|
|
|
jmp short loc_AC15
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AC0E:
|
2019-09-15 14:22:36 +00:00
|
|
|
|
call cdg_free pascal, si
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc si
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AC15:
|
2017-01-12 18:54:26 +00:00
|
|
|
|
cmp si, CDG_SLOT_COUNT
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jl short loc_AC0E
|
2014-08-22 21:45:21 +00:00
|
|
|
|
call super_free
|
2014-08-20 14:45:24 +00:00
|
|
|
|
call text_clear
|
2019-11-25 11:09:11 +00:00
|
|
|
|
mov _music_page, 1
|
2014-08-23 13:47:05 +00:00
|
|
|
|
mov PaletteTone, 0
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_showpage 0
|
|
|
|
|
graph_accesspage al
|
2014-08-27 04:03:08 +00:00
|
|
|
|
call graph_clear
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage 1
|
2017-01-11 15:12:39 +00:00
|
|
|
|
call pi_load pascal, 0, ds, offset aOp3_pi
|
|
|
|
|
call pi_palette_apply pascal, 0
|
2020-10-23 17:27:10 +00:00
|
|
|
|
call pi_put_8 pascal, large 0, 0
|
2014-11-18 16:56:13 +00:00
|
|
|
|
freePISlotLarge 0
|
2017-01-09 20:10:33 +00:00
|
|
|
|
mov al, music_track_playing
|
2019-11-25 11:09:11 +00:00
|
|
|
|
mov _music_sel, al
|
2019-11-25 11:09:11 +00:00
|
|
|
|
call draw_tracks pascal, word ptr _music_sel
|
2019-12-28 21:05:25 +00:00
|
|
|
|
call graph_copy_page pascal, 0
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage 1
|
|
|
|
|
graph_showpage 0
|
2019-11-25 11:09:11 +00:00
|
|
|
|
call screen_back_B_snap
|
2019-11-25 11:09:11 +00:00
|
|
|
|
call cmt_back_snap
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage 1
|
2017-01-09 20:10:33 +00:00
|
|
|
|
mov al, music_track_playing
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
2019-11-25 11:09:11 +00:00
|
|
|
|
call draw_cmt pascal, ax
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage 0
|
2017-01-09 20:10:33 +00:00
|
|
|
|
mov al, music_track_playing
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
2019-11-25 11:09:11 +00:00
|
|
|
|
call draw_cmt pascal, ax
|
2019-12-28 22:45:48 +00:00
|
|
|
|
mov PaletteTone, 100
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_ACC2:
|
2019-11-30 14:48:36 +00:00
|
|
|
|
call input_mode_interface
|
2018-09-11 17:34:19 +00:00
|
|
|
|
cmp _input_sp, INPUT_NONE
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_ACD3
|
2019-11-25 11:09:11 +00:00
|
|
|
|
call music_flip
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_ACC2
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_ACD3:
|
2019-11-30 14:48:36 +00:00
|
|
|
|
call input_mode_interface
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.lo, low INPUT_UP
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_AD0E
|
2019-11-25 11:09:11 +00:00
|
|
|
|
call draw_track pascal, word ptr _music_sel, 3
|
2019-11-25 11:09:11 +00:00
|
|
|
|
cmp _music_sel, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jbe short loc_ACF5
|
2019-11-25 11:09:11 +00:00
|
|
|
|
dec _music_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_ACFA
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_ACF5:
|
2019-11-25 11:09:11 +00:00
|
|
|
|
mov _music_sel, 14h
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_ACFA:
|
2019-11-25 11:09:11 +00:00
|
|
|
|
cmp _music_sel, 13h
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_AD05
|
2019-11-25 11:09:11 +00:00
|
|
|
|
dec _music_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AD05:
|
2019-11-25 11:09:11 +00:00
|
|
|
|
call draw_track pascal, word ptr _music_sel, 15
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AD0E:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.lo, low INPUT_DOWN
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_AD44
|
2019-11-25 11:09:11 +00:00
|
|
|
|
call draw_track pascal, word ptr _music_sel, 3
|
2019-11-25 11:09:11 +00:00
|
|
|
|
cmp _music_sel, 14h
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnb short loc_AD2B
|
2019-11-25 11:09:11 +00:00
|
|
|
|
inc _music_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_AD30
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AD2B:
|
2019-11-25 11:09:11 +00:00
|
|
|
|
mov _music_sel, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AD30:
|
2019-11-25 11:09:11 +00:00
|
|
|
|
cmp _music_sel, 13h
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_AD3B
|
2019-11-25 11:09:11 +00:00
|
|
|
|
inc _music_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AD3B:
|
2019-11-25 11:09:11 +00:00
|
|
|
|
call draw_track pascal, word ptr _music_sel, 15
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AD44:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.lo, low INPUT_SHOT
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_AD52
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.hi, high INPUT_OK
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_AD9A
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AD52:
|
2019-11-25 11:09:11 +00:00
|
|
|
|
cmp _music_sel, 14h
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_ADB0
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_STOP
|
2014-11-29 23:18:40 +00:00
|
|
|
|
push SND_LOAD_SONG
|
2019-11-25 11:09:11 +00:00
|
|
|
|
mov al, _music_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
shl ax, 2
|
|
|
|
|
mov bx, ax
|
2019-12-05 02:53:01 +00:00
|
|
|
|
pushd _MUSIC_FILES[bx]
|
2021-04-07 10:23:11 +00:00
|
|
|
|
call _snd_load
|
2014-06-29 22:52:27 +00:00
|
|
|
|
add sp, 6
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_PLAY
|
2019-11-25 11:09:11 +00:00
|
|
|
|
mov al, _music_sel
|
2017-01-09 20:10:33 +00:00
|
|
|
|
mov music_track_playing, al
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
2019-11-25 11:09:11 +00:00
|
|
|
|
call draw_cmt pascal, ax
|
2019-11-25 11:09:11 +00:00
|
|
|
|
call music_flip
|
|
|
|
|
mov al, _music_sel
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
2019-11-25 11:09:11 +00:00
|
|
|
|
call draw_cmt pascal, ax
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AD9A:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.hi, high INPUT_CANCEL
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_ADB0
|
2018-09-11 17:34:19 +00:00
|
|
|
|
cmp _input_sp, INPUT_NONE
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz loc_ACC2
|
2019-11-25 11:09:11 +00:00
|
|
|
|
call music_flip
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp loc_ACD3
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_ADB0:
|
2019-11-30 14:48:36 +00:00
|
|
|
|
call input_mode_interface
|
2018-09-11 17:34:19 +00:00
|
|
|
|
cmp _input_sp, INPUT_NONE
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_ADC1
|
2019-11-25 11:09:11 +00:00
|
|
|
|
call music_flip
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_ADB0
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_ADC1:
|
2019-11-25 11:09:11 +00:00
|
|
|
|
call screen_back_B_free
|
2019-11-25 11:09:11 +00:00
|
|
|
|
call cmt_back_free
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_showpage 0
|
|
|
|
|
graph_accesspage al
|
2014-08-27 04:03:08 +00:00
|
|
|
|
call graph_clear
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage 1
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, 0
|
2014-09-18 15:20:12 +00:00
|
|
|
|
out dx, al
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retf
|
2019-11-25 11:09:11 +00:00
|
|
|
|
musicroom endp
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_ADE2 proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2018-12-29 19:08:52 +00:00
|
|
|
|
@@page = byte ptr -3
|
2014-06-29 22:52:27 +00:00
|
|
|
|
var_2 = word ptr -2
|
|
|
|
|
|
|
|
|
|
enter 4, 0
|
|
|
|
|
push si
|
|
|
|
|
mov [bp+var_2], 0
|
2018-12-29 19:08:52 +00:00
|
|
|
|
mov [bp+@@page], 0
|
2019-12-22 13:04:34 +00:00
|
|
|
|
call super_entry_bfnt pascal, ds, offset aOpwin_bft ; "opwin.bft"
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_STOP
|
2021-04-07 10:23:11 +00:00
|
|
|
|
call _snd_load c, offset aOp_m, ds, SND_LOAD_SONG
|
2017-01-11 15:12:39 +00:00
|
|
|
|
call pi_load pascal, 0, ds, offset aTl01_pi
|
2014-08-23 13:47:05 +00:00
|
|
|
|
mov PaletteTone, 0
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage 1
|
2020-10-23 17:27:10 +00:00
|
|
|
|
call pi_put_8 pascal, large 0, 0
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage 0
|
2017-01-11 15:12:39 +00:00
|
|
|
|
call pi_palette_apply pascal, 0
|
2020-10-23 17:27:10 +00:00
|
|
|
|
call pi_put_8 pascal, large 0, 0
|
2019-11-16 20:59:23 +00:00
|
|
|
|
call egc_shift_left_all pascal, 2
|
2020-09-13 19:20:13 +00:00
|
|
|
|
mov Palettes[15 * size rgb_t].r, 0
|
|
|
|
|
mov Palettes[15 * size rgb_t].g, 0
|
|
|
|
|
mov Palettes[15 * size rgb_t].b, 0
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2020-09-13 19:20:13 +00:00
|
|
|
|
mov Palettes[11 * size rgb_t].r, 0
|
|
|
|
|
mov Palettes[11 * size rgb_t].g, 0
|
|
|
|
|
mov Palettes[11 * size rgb_t].b, 0
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2014-11-18 16:56:13 +00:00
|
|
|
|
freePISlotLarge 0
|
2017-01-11 15:12:39 +00:00
|
|
|
|
call pi_load pascal, 0, ds, offset aTl02_pi
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_showpage 1
|
2014-09-18 15:20:12 +00:00
|
|
|
|
mov si, 0A0h
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_AF02
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AEA0:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 1
|
2014-11-23 21:25:22 +00:00
|
|
|
|
call frame_delay
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, byte ptr [bp+var_2]
|
2020-09-13 19:20:13 +00:00
|
|
|
|
mov Palettes[15 * size rgb_t].r, al
|
|
|
|
|
mov Palettes[15 * size rgb_t].g, al
|
|
|
|
|
mov Palettes[15 * size rgb_t].b, al
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2020-09-13 19:20:13 +00:00
|
|
|
|
cmp [bp+var_2], 128
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jg short loc_AECB
|
|
|
|
|
mov al, byte ptr [bp+var_2]
|
2020-09-13 19:20:13 +00:00
|
|
|
|
mov Palettes[11 * size rgb_t].r, al
|
|
|
|
|
mov Palettes[11 * size rgb_t].g, al
|
|
|
|
|
mov Palettes[11 * size rgb_t].b, al
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AECB:
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2019-12-28 22:45:48 +00:00
|
|
|
|
cmp [bp+var_2], 100
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jg short loc_AEE1
|
|
|
|
|
mov ax, [bp+var_2]
|
2014-08-23 13:47:05 +00:00
|
|
|
|
mov PaletteTone, ax
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AEE1:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
add [bp+var_2], 2
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_showpage [bp+@@page]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, 1
|
2018-12-29 19:08:52 +00:00
|
|
|
|
sub al, [bp+@@page]
|
|
|
|
|
mov [bp+@@page], al
|
|
|
|
|
graph_accesspage al
|
2019-11-16 20:59:23 +00:00
|
|
|
|
call egc_shift_left_all pascal, 4
|
2014-06-29 22:52:27 +00:00
|
|
|
|
sub si, 2
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AF02:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp si, 11h
|
|
|
|
|
jg short loc_AEA0
|
|
|
|
|
jmp short loc_AF25
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AF09:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, byte ptr [bp+var_2]
|
2020-09-13 19:20:13 +00:00
|
|
|
|
mov Palettes[15 * size rgb_t].r, al
|
|
|
|
|
mov Palettes[15 * size rgb_t].g, al
|
|
|
|
|
mov Palettes[15 * size rgb_t].b, al
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2014-06-29 22:52:27 +00:00
|
|
|
|
add [bp+var_2], 2
|
|
|
|
|
push 1
|
2014-11-23 21:25:22 +00:00
|
|
|
|
call frame_delay
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AF25:
|
2020-09-13 19:20:13 +00:00
|
|
|
|
cmp [bp+var_2], 255
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jl short loc_AF09
|
2014-08-26 20:52:26 +00:00
|
|
|
|
mov vsync_Count1, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_B3EF
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AF35:
|
2014-08-26 20:52:26 +00:00
|
|
|
|
cmp vsync_Count1, 10h
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jb short loc_AF35
|
|
|
|
|
xor si, si
|
|
|
|
|
jmp short loc_AF65
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AF40:
|
2019-12-28 22:45:48 +00:00
|
|
|
|
mov PaletteTone, 200
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 1
|
2014-11-23 21:25:22 +00:00
|
|
|
|
call frame_delay
|
2019-12-28 22:45:48 +00:00
|
|
|
|
mov PaletteTone, 100
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 1
|
2014-11-23 21:25:22 +00:00
|
|
|
|
call frame_delay
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc si
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AF65:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp si, 8
|
|
|
|
|
jl short loc_AF40
|
2019-12-28 22:45:48 +00:00
|
|
|
|
mov PaletteTone, 200
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_PLAY
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_showpage 0
|
|
|
|
|
graph_accesspage al
|
2017-01-11 15:12:39 +00:00
|
|
|
|
call pi_palette_apply pascal, 0
|
2020-10-23 17:27:10 +00:00
|
|
|
|
call pi_put_8 pascal, large 0, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 1
|
2014-11-23 21:25:22 +00:00
|
|
|
|
call frame_delay
|
2019-12-28 22:45:48 +00:00
|
|
|
|
mov PaletteTone, 100
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 1
|
2014-11-23 21:25:22 +00:00
|
|
|
|
call frame_delay
|
2014-06-29 22:52:27 +00:00
|
|
|
|
xor si, si
|
|
|
|
|
jmp short loc_AFD9
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AFB4:
|
2019-12-28 22:45:48 +00:00
|
|
|
|
mov PaletteTone, 200
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 1
|
2014-11-23 21:25:22 +00:00
|
|
|
|
call frame_delay
|
2019-12-28 22:45:48 +00:00
|
|
|
|
mov PaletteTone, 100
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 1
|
2014-11-23 21:25:22 +00:00
|
|
|
|
call frame_delay
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc si
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_AFD9:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp si, 8
|
|
|
|
|
jl short loc_AFB4
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage 1
|
2020-10-23 17:27:10 +00:00
|
|
|
|
call pi_put_8 pascal, large 0, 0
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage 0
|
2014-11-18 16:56:13 +00:00
|
|
|
|
freePISlotLarge 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_B38D
|
|
|
|
|
pop si
|
|
|
|
|
leave
|
|
|
|
|
retn
|
|
|
|
|
sub_ADE2 endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_B008 proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
2019-12-22 13:04:34 +00:00
|
|
|
|
call super_entry_bfnt pascal, ds, offset aOpwin_bft ; "opwin.bft"
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_STOP
|
2021-04-07 10:23:11 +00:00
|
|
|
|
call _snd_load c, offset aOp_m, ds, SND_LOAD_SONG
|
2014-08-23 13:47:05 +00:00
|
|
|
|
mov PaletteTone, 0
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2017-01-11 15:12:39 +00:00
|
|
|
|
call pi_load pascal, 0, ds, offset aTl02_pi
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_showpage 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_B3EF
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage 1
|
2020-10-23 17:27:10 +00:00
|
|
|
|
call pi_put_8 pascal, large 0, 0
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage 0
|
2017-01-11 15:12:39 +00:00
|
|
|
|
call pi_palette_apply pascal, 0
|
2020-10-23 17:27:10 +00:00
|
|
|
|
call pi_put_8 pascal, large 0, 0
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage 0
|
2014-11-18 16:56:13 +00:00
|
|
|
|
freePISlotLarge 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_B38D
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_PLAY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
xor si, si
|
|
|
|
|
jmp short loc_B0A7
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B094:
|
2014-08-23 13:47:05 +00:00
|
|
|
|
mov PaletteTone, si
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 1
|
2014-11-23 21:25:22 +00:00
|
|
|
|
call frame_delay
|
2014-06-29 22:52:27 +00:00
|
|
|
|
add si, 4
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B0A7:
|
2019-12-28 22:45:48 +00:00
|
|
|
|
cmp si, 100
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jle short loc_B094
|
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retn
|
|
|
|
|
sub_B008 endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_B0AF proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
2019-12-22 13:04:34 +00:00
|
|
|
|
mov si, 288
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_B0D2
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B0B8:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push si
|
|
|
|
|
call sub_B10A
|
2019-12-22 13:04:34 +00:00
|
|
|
|
call super_put pascal, si, large (256 shl 16) or 2
|
|
|
|
|
call frame_delay pascal, 1
|
2014-06-29 22:52:27 +00:00
|
|
|
|
add si, 8
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B0D2:
|
2019-12-22 13:04:34 +00:00
|
|
|
|
cmp si, 392
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jl short loc_B0B8
|
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retn
|
|
|
|
|
sub_B0AF endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_B0DB proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
2019-12-22 13:04:34 +00:00
|
|
|
|
mov si, 384
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_B101
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B0E4:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
lea ax, [si+8]
|
|
|
|
|
push ax
|
|
|
|
|
call sub_B10A
|
2019-12-22 13:04:34 +00:00
|
|
|
|
call super_put pascal, si, large (256 shl 16) or 2
|
|
|
|
|
call frame_delay pascal, 1
|
2014-06-29 22:52:27 +00:00
|
|
|
|
sub si, 8
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B101:
|
2019-12-22 13:04:34 +00:00
|
|
|
|
cmp si, 280
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jge short loc_B0E4
|
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retn
|
|
|
|
|
sub_B0DB endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_B10A proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
arg_0 = word ptr 4
|
|
|
|
|
|
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
|
|
|
|
push di
|
|
|
|
|
mov ax, [bp+arg_0]
|
|
|
|
|
shr ax, 3
|
|
|
|
|
mov di, 77B0h
|
|
|
|
|
add di, ax
|
|
|
|
|
mov ax, 0AD00h
|
|
|
|
|
mov es, ax
|
|
|
|
|
assume es:nothing
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B11F:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, 1
|
2014-09-18 15:20:12 +00:00
|
|
|
|
out 0A6h, al
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov dx, es:[di]
|
|
|
|
|
mov ax, 0B500h
|
|
|
|
|
mov es, ax
|
|
|
|
|
assume es:nothing
|
|
|
|
|
mov cx, es:[di]
|
|
|
|
|
mov ax, 0BD00h
|
|
|
|
|
mov es, ax
|
|
|
|
|
assume es:nothing
|
|
|
|
|
mov bx, es:[di]
|
|
|
|
|
mov ax, 0E500h
|
|
|
|
|
mov es, ax
|
|
|
|
|
assume es:nothing
|
|
|
|
|
mov si, es:[di]
|
|
|
|
|
xor al, al
|
2014-09-18 15:20:12 +00:00
|
|
|
|
out 0A6h, al
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov es:[di], si
|
|
|
|
|
mov ax, 0BD00h
|
|
|
|
|
mov es, ax
|
|
|
|
|
assume es:nothing
|
|
|
|
|
mov es:[di], bx
|
|
|
|
|
mov ax, 0B500h
|
|
|
|
|
mov es, ax
|
|
|
|
|
assume es:nothing
|
|
|
|
|
mov es:[di], cx
|
|
|
|
|
mov ax, 0AD00h
|
|
|
|
|
mov es, ax
|
|
|
|
|
assume es:nothing
|
|
|
|
|
mov es:[di], dx
|
|
|
|
|
sub di, 50h ; 'P'
|
|
|
|
|
jnb short loc_B11F
|
|
|
|
|
pop di
|
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retn 2
|
|
|
|
|
sub_B10A endp
|
2021-12-23 01:26:27 +00:00
|
|
|
|
op_01_TEXT ends
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2021-12-25 14:53:17 +00:00
|
|
|
|
op_02_TEXT segment byte public 'CODE' use16
|
|
|
|
|
op_02_TEXT ends
|
|
|
|
|
|
2021-12-23 01:26:27 +00:00
|
|
|
|
SCOREDAT_TEXT segment byte public 'CODE' use16
|
|
|
|
|
SCOREDAT_TEXT ends
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2021-12-25 14:53:17 +00:00
|
|
|
|
op_03_TEXT segment byte public 'CODE' use16
|
2021-12-25 18:35:50 +00:00
|
|
|
|
@SCOREDAT_LOAD_AND_DECODE$Q6RANK_T procdesc pascal near \
|
|
|
|
|
rank:word
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_B35D proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
var_1 = byte ptr -1
|
|
|
|
|
|
|
|
|
|
enter 2, 0
|
|
|
|
|
push si
|
|
|
|
|
mov [bp+var_1], 7
|
|
|
|
|
xor si, si
|
|
|
|
|
jmp short loc_B382
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B36A:
|
2021-12-25 18:35:50 +00:00
|
|
|
|
call @scoredat_load_and_decode$q6rank_t pascal, si
|
2014-06-29 22:52:27 +00:00
|
|
|
|
or ax, ax
|
|
|
|
|
jz short loc_B376
|
|
|
|
|
mov al, 7
|
|
|
|
|
jmp short loc_B38A
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B376:
|
2021-12-21 13:14:28 +00:00
|
|
|
|
cmp _hi.SDS_score.SD_cleared, SCOREDAT_CLEARED
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_B381
|
|
|
|
|
mov [bp+var_1], 9
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B381:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc si
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B382:
|
2021-12-25 18:35:50 +00:00
|
|
|
|
cmp si, (RANK_LUNATIC + 1)
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jl short loc_B36A
|
|
|
|
|
mov al, [bp+var_1]
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B38A:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop si
|
|
|
|
|
leave
|
|
|
|
|
retn
|
|
|
|
|
sub_B35D endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_B38D proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
2020-09-05 17:03:48 +00:00
|
|
|
|
call _hflip_lut_generate
|
2014-06-29 22:52:27 +00:00
|
|
|
|
xor si, si
|
|
|
|
|
jmp short loc_B3B0
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B39A:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
lea ax, [si+2]
|
|
|
|
|
push ax
|
|
|
|
|
mov bx, si
|
|
|
|
|
shl bx, 2
|
2014-11-19 11:09:22 +00:00
|
|
|
|
pushd dword ptr [bx+0A0Eh]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 0
|
2020-09-05 15:52:09 +00:00
|
|
|
|
call cdg_load_single
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc si
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B3B0:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp si, 3
|
|
|
|
|
jl short loc_B39A
|
2019-09-15 14:22:36 +00:00
|
|
|
|
call cdg_load_all_noalpha pascal, 13, ds, offset aSlex_cd2
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retn
|
|
|
|
|
sub_B38D endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_B3C3 proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
2020-09-05 15:52:09 +00:00
|
|
|
|
call cdg_load_single pascal, 1, ds, offset a99sl_cdg, 0
|
2019-09-15 14:22:36 +00:00
|
|
|
|
call cdg_load_single_noalpha pascal, 11, ds, offset aSlwin_cdg , 0
|
|
|
|
|
call cdg_load_single_noalpha pascal, 12, ds, offset aSlex_cdg, 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop bp
|
|
|
|
|
retn
|
|
|
|
|
sub_B3C3 endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_B3EF proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
2020-09-05 15:52:09 +00:00
|
|
|
|
call cdg_load_single pascal, 0, [off_E1FE], 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov si, 3
|
|
|
|
|
jmp short loc_B41C
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B406:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
lea ax, [si+2]
|
|
|
|
|
push ax
|
|
|
|
|
mov bx, si
|
|
|
|
|
shl bx, 2
|
2014-11-19 11:09:22 +00:00
|
|
|
|
pushd dword ptr [bx+0A0Eh]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 0
|
2020-09-05 15:52:09 +00:00
|
|
|
|
call cdg_load_single
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc si
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B41C:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp si, 6
|
|
|
|
|
jl short loc_B406
|
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retn
|
|
|
|
|
sub_B3EF endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_B424 proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
2014-08-26 20:52:26 +00:00
|
|
|
|
mov vsync_Count1, 0
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_STOP
|
2021-04-07 10:23:11 +00:00
|
|
|
|
call _snd_load c, offset aSelect_m, ds, SND_LOAD_SONG
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_PLAY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov word_FC64, 0C8h ; '<27>'
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2014-06-29 22:52:27 +00:00
|
|
|
|
assume es:nothing
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov eax, es:[bx+resident_t.rand]
|
2014-08-30 10:13:04 +00:00
|
|
|
|
mov random_seed, eax
|
2014-08-20 14:45:24 +00:00
|
|
|
|
call text_clear
|
2014-08-22 21:45:21 +00:00
|
|
|
|
call super_free
|
2019-12-22 13:04:34 +00:00
|
|
|
|
call super_entry_bfnt pascal, ds, offset aChname_bft ; "chname.bft"
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage 0
|
2014-08-27 04:03:08 +00:00
|
|
|
|
call graph_clear
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage 1
|
2014-08-27 04:03:08 +00:00
|
|
|
|
call graph_clear
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_showpage 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov byte_FC5C, 0
|
|
|
|
|
push ds
|
|
|
|
|
push offset aTlsl_rgb ; "TLSL.RGB"
|
2014-08-31 03:14:54 +00:00
|
|
|
|
call palette_entry_rgb
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov si, 6
|
|
|
|
|
jmp short loc_B4BC
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B4A6:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
lea ax, [si+2]
|
|
|
|
|
push ax
|
|
|
|
|
mov bx, si
|
|
|
|
|
shl bx, 2
|
2014-11-19 11:09:22 +00:00
|
|
|
|
pushd dword ptr [bx+0A0Eh]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 0
|
2020-09-05 15:52:09 +00:00
|
|
|
|
call cdg_load_single
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc si
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B4BC:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp si, 9
|
|
|
|
|
jl short loc_B4A6
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B4C1:
|
2014-08-26 20:52:26 +00:00
|
|
|
|
cmp vsync_Count1, 1Eh
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jb short loc_B4C1
|
|
|
|
|
mov word_FC66, 8
|
|
|
|
|
call sub_B35D
|
|
|
|
|
mov byte_FC68, al
|
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retn
|
|
|
|
|
sub_B424 endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_B4D7 proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
|
|
|
|
xor si, si
|
|
|
|
|
jmp short loc_B4E6
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B4DF:
|
2019-09-15 14:22:36 +00:00
|
|
|
|
call cdg_free pascal, si
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc si
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B4E6:
|
2017-01-12 18:54:26 +00:00
|
|
|
|
cmp si, 22
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jl short loc_B4DF
|
2014-08-22 21:45:21 +00:00
|
|
|
|
call super_free
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retn
|
|
|
|
|
sub_B4D7 endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_B4F3 proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
2017-01-13 20:12:25 +00:00
|
|
|
|
push (32 shl 16) or 96
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp byte_FC5A, 0
|
|
|
|
|
jnz short loc_B50C
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, _playchars[0]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
|
|
|
|
add ax, 2
|
|
|
|
|
jmp short loc_B50E
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B50C:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
xor ax, ax
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B50E:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2020-09-19 16:41:48 +00:00
|
|
|
|
call cdg_put_8
|
2017-01-15 20:34:32 +00:00
|
|
|
|
push (416 shl 16) or 96
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp byte_FC5B, 0
|
|
|
|
|
jnz short loc_B52A
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, _playchars[1]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
|
|
|
|
add ax, 2
|
|
|
|
|
jmp short loc_B52D
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B52A:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ax, 1
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B52D:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2020-09-19 16:41:48 +00:00
|
|
|
|
call cdg_put_hflip_8
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop bp
|
|
|
|
|
retn
|
|
|
|
|
sub_B4F3 endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_B535 proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
2017-01-13 20:12:25 +00:00
|
|
|
|
push (32 shl 16) or 96
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp byte_FC5A, 0
|
|
|
|
|
jnz short loc_B54E
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, _playchars[0]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
|
|
|
|
add ax, 2
|
|
|
|
|
jmp short loc_B550
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B54E:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
xor ax, ax
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B550:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2020-09-19 16:41:48 +00:00
|
|
|
|
call cdg_put_8
|
|
|
|
|
call cdg_put_8 pascal, large (416 shl 16) or 96, 1
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop bp
|
|
|
|
|
retn
|
|
|
|
|
sub_B535 endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_B565 proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
var_4 = word ptr -4
|
|
|
|
|
var_2 = word ptr -2
|
|
|
|
|
|
|
|
|
|
enter 4, 0
|
|
|
|
|
push si
|
|
|
|
|
push di
|
2020-09-19 16:41:48 +00:00
|
|
|
|
call cdg_put_noalpha_8 pascal, large (32 shl 16) or 304, 11
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp es:[bx+resident_t.game_mode], GM_STORY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_B590
|
2020-09-19 16:41:48 +00:00
|
|
|
|
call cdg_put_noalpha_8 pascal, large (416 shl 16) or 304, 11
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B590:
|
2015-01-12 21:48:13 +00:00
|
|
|
|
call grcg_setcolor pascal, (GC_RMW shl 16) + 14
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov [bp+var_2], 0
|
|
|
|
|
mov [bp+var_4], 13Bh
|
|
|
|
|
jmp short loc_B625
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B5A7:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov di, 5
|
2014-09-18 15:20:12 +00:00
|
|
|
|
mov si, 8Ch ; '<27>E
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_B5C7
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B5AF:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push si
|
|
|
|
|
push [bp+var_4]
|
|
|
|
|
lea ax, [si+8]
|
|
|
|
|
push ax
|
|
|
|
|
mov ax, [bp+var_4]
|
2019-11-10 23:18:22 +00:00
|
|
|
|
add ax, 15
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2014-08-28 03:31:57 +00:00
|
|
|
|
call grcg_boxfill
|
2014-06-29 22:52:27 +00:00
|
|
|
|
dec di
|
|
|
|
|
sub si, 0Bh
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B5C7:
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, _playchars[0]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
|
|
|
|
imul ax, 3
|
|
|
|
|
add ax, [bp+var_2]
|
|
|
|
|
mov bx, ax
|
|
|
|
|
mov al, [bx+0A32h]
|
|
|
|
|
mov ah, 0
|
|
|
|
|
cmp ax, di
|
|
|
|
|
jl short loc_B5AF
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp es:[bx+resident_t.game_mode], GM_STORY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_B61E
|
|
|
|
|
mov di, 5
|
|
|
|
|
mov si, 20Ch
|
|
|
|
|
jmp short loc_B608
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B5F0:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push si
|
|
|
|
|
push [bp+var_4]
|
|
|
|
|
lea ax, [si+8]
|
|
|
|
|
push ax
|
|
|
|
|
mov ax, [bp+var_4]
|
2019-11-10 23:18:22 +00:00
|
|
|
|
add ax, 15
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2014-08-28 03:31:57 +00:00
|
|
|
|
call grcg_boxfill
|
2014-06-29 22:52:27 +00:00
|
|
|
|
dec di
|
|
|
|
|
sub si, 0Bh
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B608:
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, _playchars[1]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
|
|
|
|
imul ax, 3
|
|
|
|
|
add ax, [bp+var_2]
|
|
|
|
|
mov bx, ax
|
|
|
|
|
mov al, [bx+0A32h]
|
|
|
|
|
mov ah, 0
|
|
|
|
|
cmp ax, di
|
|
|
|
|
jl short loc_B5F0
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B61E:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc [bp+var_2]
|
|
|
|
|
add [bp+var_4], 10h
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B625:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp [bp+var_2], 3
|
|
|
|
|
jl loc_B5A7
|
2014-08-27 04:52:58 +00:00
|
|
|
|
call grcg_off
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop di
|
|
|
|
|
pop si
|
|
|
|
|
leave
|
|
|
|
|
retn
|
|
|
|
|
sub_B565 endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_B636 proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
|
|
|
|
push di
|
2019-12-22 13:04:34 +00:00
|
|
|
|
mov di, 136
|
2014-06-29 22:52:27 +00:00
|
|
|
|
xor si, si
|
|
|
|
|
jmp short loc_B663
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B642:
|
2019-12-22 13:04:34 +00:00
|
|
|
|
push 256
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push di
|
|
|
|
|
mov ax, si
|
|
|
|
|
add ax, ax
|
|
|
|
|
push ax
|
2014-08-28 00:13:13 +00:00
|
|
|
|
call super_put
|
2019-12-22 13:04:34 +00:00
|
|
|
|
push 320
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push di
|
|
|
|
|
mov ax, si
|
|
|
|
|
add ax, ax
|
|
|
|
|
inc ax
|
|
|
|
|
push ax
|
2014-08-28 00:13:13 +00:00
|
|
|
|
call super_put
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc si
|
2019-12-22 13:04:34 +00:00
|
|
|
|
add di, 20
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B663:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, byte_FC68
|
|
|
|
|
mov ah, 0
|
|
|
|
|
cmp ax, si
|
|
|
|
|
jg short loc_B642
|
|
|
|
|
pop di
|
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retn
|
|
|
|
|
sub_B636 endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_B670 proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
2020-09-19 16:41:48 +00:00
|
|
|
|
call cdg_put_noalpha_8 pascal, large (160 shl 16) or 304, 12
|
2017-01-14 12:24:49 +00:00
|
|
|
|
push (176 shl 16) or 316
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, _playchars[0]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
2017-01-14 12:24:49 +00:00
|
|
|
|
add ax, 13
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2020-09-19 16:41:48 +00:00
|
|
|
|
call cdg_put_noalpha_8
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp es:[bx+resident_t.game_mode], GM_STORY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_B6BE
|
2020-09-19 16:41:48 +00:00
|
|
|
|
call cdg_put_noalpha_8 pascal, large (544 shl 16) or 304, 12
|
2017-01-14 12:24:49 +00:00
|
|
|
|
push (560 shl 16) or 316
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, _playchars[1]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cbw
|
2017-01-14 12:24:49 +00:00
|
|
|
|
add ax, 13
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2020-09-19 16:41:48 +00:00
|
|
|
|
call cdg_put_noalpha_8
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B6BE:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop bp
|
|
|
|
|
retn
|
|
|
|
|
sub_B670 endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_B6C0 proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2020-07-13 18:41:08 +00:00
|
|
|
|
@@angle = byte ptr -7
|
2014-06-29 22:52:27 +00:00
|
|
|
|
var_6 = word ptr -6
|
|
|
|
|
var_4 = word ptr -4
|
|
|
|
|
var_2 = word ptr -2
|
|
|
|
|
arg_0 = word ptr 4
|
|
|
|
|
arg_2 = word ptr 6
|
|
|
|
|
arg_4 = word ptr 8
|
|
|
|
|
arg_6 = byte ptr 0Ah
|
|
|
|
|
arg_8 = byte ptr 0Ch
|
|
|
|
|
|
|
|
|
|
enter 8, 0
|
|
|
|
|
push si
|
|
|
|
|
mov si, [bp+arg_4]
|
|
|
|
|
mov [bp+var_6], 0
|
|
|
|
|
jmp short loc_B73B
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B6CF:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, byte ptr [bp+var_6]
|
|
|
|
|
add al, [bp+arg_8]
|
2020-07-13 18:41:08 +00:00
|
|
|
|
mov [bp+@@angle], al
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
imul [bp+arg_2]
|
2020-07-13 18:41:08 +00:00
|
|
|
|
mov bx, 256
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cwd
|
|
|
|
|
idiv bx
|
2020-07-13 18:41:08 +00:00
|
|
|
|
mov [bp+@@angle], al
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
add ax, ax
|
|
|
|
|
mov bx, ax
|
2020-06-26 10:19:15 +00:00
|
|
|
|
call _vector1_at c, (RES_X / 2), si, _CosTable8[bx]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov [bp+var_2], ax
|
|
|
|
|
mov al, byte ptr [bp+var_6]
|
|
|
|
|
add al, [bp+arg_6]
|
2020-07-13 18:41:08 +00:00
|
|
|
|
mov [bp+@@angle], al
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
imul [bp+arg_0]
|
2020-07-13 18:41:08 +00:00
|
|
|
|
mov bx, 256
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cwd
|
|
|
|
|
idiv bx
|
2020-07-13 18:41:08 +00:00
|
|
|
|
mov [bp+@@angle], al
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
add ax, ax
|
|
|
|
|
mov bx, ax
|
2020-06-26 10:19:15 +00:00
|
|
|
|
call _vector1_at c, (RES_Y / 2), si, _SinTable8[bx]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov [bp+var_4], ax
|
|
|
|
|
push [bp+var_2]
|
|
|
|
|
push ax
|
2014-08-28 03:48:32 +00:00
|
|
|
|
call grcg_pset
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc [bp+var_6]
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B73B:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp [bp+var_6], 100h
|
|
|
|
|
jb short loc_B6CF
|
|
|
|
|
pop si
|
|
|
|
|
leave
|
|
|
|
|
retn 0Ah
|
|
|
|
|
sub_B6C0 endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_B747 proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
var_6 = word ptr -6
|
|
|
|
|
var_4 = word ptr -4
|
|
|
|
|
var_2 = word ptr -2
|
|
|
|
|
|
|
|
|
|
enter 6, 0
|
|
|
|
|
push si
|
|
|
|
|
push di
|
|
|
|
|
mov al, byte ptr word_FC52
|
|
|
|
|
mov ah, 0
|
|
|
|
|
mov si, ax
|
2014-09-18 15:20:12 +00:00
|
|
|
|
cmp si, 80h
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jl short loc_B761
|
|
|
|
|
mov ax, 100h
|
|
|
|
|
sub ax, si
|
|
|
|
|
mov si, ax
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B761:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ax, si
|
|
|
|
|
add ax, si
|
|
|
|
|
add ax, 100h
|
|
|
|
|
mov [bp+var_4], ax
|
|
|
|
|
add si, 100h
|
|
|
|
|
mov ax, si
|
|
|
|
|
add ax, si
|
|
|
|
|
mov [bp+var_2], ax
|
2015-01-12 21:48:13 +00:00
|
|
|
|
call grcg_setcolor pascal, (GC_RMW shl 16) + 6
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push word_FC52
|
|
|
|
|
mov al, byte ptr word_FC52
|
|
|
|
|
add al, al
|
|
|
|
|
push ax
|
|
|
|
|
push 0DCh ; '<27>'
|
|
|
|
|
push si
|
|
|
|
|
push [bp+var_2]
|
|
|
|
|
call sub_B6C0
|
|
|
|
|
mov al, 0
|
|
|
|
|
sub al, byte ptr word_FC52
|
|
|
|
|
push ax
|
|
|
|
|
mov al, byte ptr word_FC52
|
|
|
|
|
mov ah, 0
|
|
|
|
|
cwd
|
|
|
|
|
sub ax, dx
|
|
|
|
|
sar ax, 1
|
|
|
|
|
push ax
|
|
|
|
|
push 78h ; 'x'
|
|
|
|
|
push [bp+var_4]
|
|
|
|
|
push si
|
|
|
|
|
call sub_B6C0
|
2015-01-12 21:48:13 +00:00
|
|
|
|
call grcg_setcolor pascal, (GC_RMW shl 16) + 5
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ax, word_FC66
|
|
|
|
|
cwd
|
|
|
|
|
sub ax, dx
|
|
|
|
|
sar ax, 1
|
|
|
|
|
mov di, ax
|
|
|
|
|
test byte ptr word_FC66, 1
|
|
|
|
|
jz short loc_B7CD
|
|
|
|
|
inc di
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B7CD:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov [bp+var_6], 1
|
|
|
|
|
jmp short loc_B824
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B7D4:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, byte ptr [bp+var_6]
|
|
|
|
|
add al, al
|
|
|
|
|
mov dl, byte ptr word_FC52
|
|
|
|
|
sub dl, al
|
|
|
|
|
push dx
|
|
|
|
|
mov al, byte ptr word_FC52
|
|
|
|
|
add al, al
|
|
|
|
|
mov dl, byte ptr [bp+var_6]
|
|
|
|
|
shl dl, 2
|
|
|
|
|
sub al, dl
|
|
|
|
|
push ax
|
|
|
|
|
push 0DCh ; '<27>'
|
|
|
|
|
push si
|
|
|
|
|
push [bp+var_2]
|
|
|
|
|
call sub_B6C0
|
|
|
|
|
mov al, 0
|
|
|
|
|
sub al, byte ptr word_FC52
|
|
|
|
|
mov dl, byte ptr [bp+var_6]
|
|
|
|
|
add dl, dl
|
|
|
|
|
add al, dl
|
|
|
|
|
push ax
|
|
|
|
|
mov al, byte ptr word_FC52
|
|
|
|
|
mov ah, 0
|
|
|
|
|
mov dx, [bp+var_6]
|
|
|
|
|
add dx, dx
|
|
|
|
|
sub ax, dx
|
|
|
|
|
cwd
|
|
|
|
|
sub ax, dx
|
|
|
|
|
sar ax, 1
|
|
|
|
|
push ax
|
|
|
|
|
push 78h ; 'x'
|
|
|
|
|
push [bp+var_4]
|
|
|
|
|
push si
|
|
|
|
|
call sub_B6C0
|
|
|
|
|
inc [bp+var_6]
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B824:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp [bp+var_6], di
|
|
|
|
|
jle short loc_B7D4
|
2015-01-12 21:48:13 +00:00
|
|
|
|
call grcg_setcolor pascal, (GC_RMW shl 16) + 1
|
2014-06-29 22:52:27 +00:00
|
|
|
|
lea ax, [di+1]
|
|
|
|
|
mov [bp+var_6], ax
|
|
|
|
|
jmp short loc_B88C
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B83C:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, byte ptr [bp+var_6]
|
|
|
|
|
add al, al
|
|
|
|
|
mov dl, byte ptr word_FC52
|
|
|
|
|
sub dl, al
|
|
|
|
|
push dx
|
|
|
|
|
mov al, byte ptr word_FC52
|
|
|
|
|
add al, al
|
|
|
|
|
mov dl, byte ptr [bp+var_6]
|
|
|
|
|
shl dl, 2
|
|
|
|
|
sub al, dl
|
|
|
|
|
push ax
|
|
|
|
|
push 0DCh ; '<27>'
|
|
|
|
|
push si
|
|
|
|
|
push [bp+var_2]
|
|
|
|
|
call sub_B6C0
|
|
|
|
|
mov al, 0
|
|
|
|
|
sub al, byte ptr word_FC52
|
|
|
|
|
mov dl, byte ptr [bp+var_6]
|
|
|
|
|
add dl, dl
|
|
|
|
|
add al, dl
|
|
|
|
|
push ax
|
|
|
|
|
mov al, byte ptr word_FC52
|
|
|
|
|
mov ah, 0
|
|
|
|
|
mov dx, [bp+var_6]
|
|
|
|
|
add dx, dx
|
|
|
|
|
sub ax, dx
|
|
|
|
|
cwd
|
|
|
|
|
sub ax, dx
|
|
|
|
|
sar ax, 1
|
|
|
|
|
push ax
|
|
|
|
|
push 78h ; 'x'
|
|
|
|
|
push [bp+var_4]
|
|
|
|
|
push si
|
|
|
|
|
call sub_B6C0
|
|
|
|
|
inc [bp+var_6]
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B88C:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ax, [bp+var_6]
|
|
|
|
|
cmp ax, word_FC66
|
|
|
|
|
jle short loc_B83C
|
2014-08-27 04:52:58 +00:00
|
|
|
|
call grcg_off
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, byte ptr word_FC52
|
|
|
|
|
add al, 2
|
|
|
|
|
mov byte ptr word_FC52, al
|
|
|
|
|
pop di
|
|
|
|
|
pop si
|
|
|
|
|
leave
|
|
|
|
|
retn
|
|
|
|
|
sub_B747 endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
2019-12-28 20:20:48 +00:00
|
|
|
|
public P_CURSOR_PUT
|
|
|
|
|
p_cursor_put proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2019-12-28 20:20:48 +00:00
|
|
|
|
@@y = word ptr -2
|
|
|
|
|
@@col = byte ptr 4
|
2014-06-29 22:52:27 +00:00
|
|
|
|
arg_2 = word ptr 6
|
|
|
|
|
|
|
|
|
|
enter 2, 0
|
|
|
|
|
push si
|
|
|
|
|
push di
|
|
|
|
|
mov si, [bp+arg_2]
|
|
|
|
|
mov ax, si
|
|
|
|
|
shl ax, 4
|
|
|
|
|
shl ax, 3
|
2019-12-28 20:20:48 +00:00
|
|
|
|
add ax, 240
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov di, ax
|
|
|
|
|
mov al, [si+2468h]
|
|
|
|
|
cbw
|
2019-12-28 20:20:48 +00:00
|
|
|
|
imul ax, 20
|
|
|
|
|
add ax, 128
|
|
|
|
|
mov [bp+@@y], ax
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push di
|
|
|
|
|
push ax
|
2019-12-28 20:20:48 +00:00
|
|
|
|
push GAIJI_W
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
|
|
|
|
mov ax, si
|
2019-12-28 20:20:48 +00:00
|
|
|
|
imul ax, (gc_GAIJI_W + 1)
|
|
|
|
|
add ax, offset _P_CURSOR_TOP
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2019-12-28 20:20:48 +00:00
|
|
|
|
mov al, [bp+@@col]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
push ax
|
2014-09-15 01:03:52 +00:00
|
|
|
|
call graph_gaiji_puts
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push di
|
2019-12-28 20:20:48 +00:00
|
|
|
|
mov ax, [bp+@@y]
|
2020-01-13 21:52:19 +00:00
|
|
|
|
add ax, GLYPH_H
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2019-12-28 20:20:48 +00:00
|
|
|
|
push GAIJI_W
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ds
|
|
|
|
|
mov ax, si
|
2019-12-28 20:20:48 +00:00
|
|
|
|
imul ax, (gc_GAIJI_W + 1)
|
|
|
|
|
add ax, offset _P_CURSOR_BOTTOM
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2019-12-28 20:20:48 +00:00
|
|
|
|
mov al, [bp+@@col]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
push ax
|
2014-09-15 01:03:52 +00:00
|
|
|
|
call graph_gaiji_puts
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop di
|
|
|
|
|
pop si
|
|
|
|
|
leave
|
|
|
|
|
retn 4
|
2019-12-28 20:20:48 +00:00
|
|
|
|
p_cursor_put endp
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_B908 proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
var_2 = word ptr -2
|
|
|
|
|
arg_0 = word ptr 4
|
|
|
|
|
arg_2 = word ptr 6
|
|
|
|
|
|
|
|
|
|
enter 2, 0
|
|
|
|
|
push si
|
|
|
|
|
push di
|
|
|
|
|
mov di, [bp+arg_2]
|
|
|
|
|
mov si, [bp+arg_0]
|
|
|
|
|
cmp byte ptr [si+246Ah], 0
|
|
|
|
|
jnz loc_BA82
|
|
|
|
|
cmp byte ptr [si+0A59h], 0
|
|
|
|
|
jz short loc_B932
|
|
|
|
|
or di, di
|
|
|
|
|
jnz loc_BA82
|
|
|
|
|
mov byte ptr [si+0A59h], 0
|
|
|
|
|
jmp loc_BA82
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B932:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
test di, 1
|
|
|
|
|
jz short loc_B951
|
|
|
|
|
dec byte ptr [si+2468h]
|
|
|
|
|
cmp byte ptr [si+2468h], 0
|
|
|
|
|
jge short loc_B94C
|
|
|
|
|
mov al, byte_FC68
|
|
|
|
|
dec al
|
|
|
|
|
mov [si+2468h], al
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B94C:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov byte ptr [si+0A59h], 1
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B951:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
test di, 2
|
|
|
|
|
jz short loc_B974
|
|
|
|
|
inc byte ptr [si+2468h]
|
|
|
|
|
mov al, [si+2468h]
|
|
|
|
|
cbw
|
|
|
|
|
mov dl, byte_FC68
|
|
|
|
|
mov dh, 0
|
|
|
|
|
cmp ax, dx
|
|
|
|
|
jl short loc_B96F
|
|
|
|
|
mov byte ptr [si+2468h], 0
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B96F:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov byte ptr [si+0A59h], 1
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B974:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
test di, 20h
|
|
|
|
|
; Hack
|
|
|
|
|
db 00fh
|
|
|
|
|
db 084h
|
|
|
|
|
db 07fh
|
|
|
|
|
db 000h
|
|
|
|
|
mov al, [si+2468h]
|
|
|
|
|
cbw
|
|
|
|
|
mov [bp+var_2], ax
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2014-06-29 22:52:27 +00:00
|
|
|
|
add bx, si
|
|
|
|
|
mov al, byte ptr [bp+var_2]
|
|
|
|
|
add al, al
|
|
|
|
|
inc al
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.RESIDENT_playchar_paletted], al
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 1
|
2014-08-26 22:52:29 +00:00
|
|
|
|
call palette_white_in
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov bx, 1
|
|
|
|
|
sub bx, si
|
|
|
|
|
cmp byte ptr [bx+246Ah], 0
|
|
|
|
|
jz short loc_B9CC
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, es:[bx+resident_t.RESIDENT_playchar_paletted][0]
|
|
|
|
|
cmp al, es:[bx+resident_t.RESIDENT_playchar_paletted][1]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_B9CC
|
|
|
|
|
add bx, si
|
2020-02-19 16:45:19 +00:00
|
|
|
|
inc es:[bx+resident_t.RESIDENT_playchar_paletted]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push si
|
|
|
|
|
mov bx, [bp+var_2]
|
|
|
|
|
shl bx, 2
|
2014-11-19 11:09:22 +00:00
|
|
|
|
pushd dword ptr [bx+0A0Eh]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 1
|
|
|
|
|
jmp short loc_B9DA
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B9CC:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push si
|
|
|
|
|
mov bx, [bp+var_2]
|
|
|
|
|
shl bx, 2
|
2014-11-19 11:09:22 +00:00
|
|
|
|
pushd dword ptr [bx+0A0Eh]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 0
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B9DA:
|
2020-09-05 15:52:09 +00:00
|
|
|
|
call cdg_load_single
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov bx, 1
|
|
|
|
|
sub bx, si
|
|
|
|
|
cmp byte ptr [bx+246Ah], 0
|
|
|
|
|
jz short loc_B9F1
|
|
|
|
|
mov word_FC62, 0
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B9F1:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov byte ptr [si+246Ah], 1
|
|
|
|
|
mov byte ptr [si+0A59h], 1
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_B9FB:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
test di, 10h
|
|
|
|
|
; Hack
|
|
|
|
|
db 00fh
|
|
|
|
|
db 084h
|
|
|
|
|
db 07fh
|
|
|
|
|
db 000h
|
|
|
|
|
mov al, [si+2468h]
|
|
|
|
|
cbw
|
|
|
|
|
mov [bp+var_2], ax
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2014-06-29 22:52:27 +00:00
|
|
|
|
add bx, si
|
|
|
|
|
mov al, byte ptr [bp+var_2]
|
|
|
|
|
add al, al
|
|
|
|
|
add al, 2
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov es:[bx+resident_t.RESIDENT_playchar_paletted], al
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 1
|
2014-08-26 22:52:29 +00:00
|
|
|
|
call palette_white_in
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov bx, 1
|
|
|
|
|
sub bx, si
|
|
|
|
|
cmp byte ptr [bx+246Ah], 0
|
|
|
|
|
jz short loc_BA53
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, es:[bx+resident_t.RESIDENT_playchar_paletted][0]
|
|
|
|
|
cmp al, es:[bx+resident_t.RESIDENT_playchar_paletted][1]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_BA53
|
|
|
|
|
add bx, si
|
2020-02-19 16:45:19 +00:00
|
|
|
|
dec es:[bx+resident_t.RESIDENT_playchar_paletted]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push si
|
|
|
|
|
mov bx, [bp+var_2]
|
|
|
|
|
shl bx, 2
|
2014-11-19 11:09:22 +00:00
|
|
|
|
pushd dword ptr [bx+0A0Eh]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 0
|
|
|
|
|
jmp short loc_BA61
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BA53:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push si
|
|
|
|
|
mov bx, [bp+var_2]
|
|
|
|
|
shl bx, 2
|
2014-11-19 11:09:22 +00:00
|
|
|
|
pushd dword ptr [bx+0A0Eh]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 1
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BA61:
|
2020-09-05 15:52:09 +00:00
|
|
|
|
call cdg_load_single
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov bx, 1
|
|
|
|
|
sub bx, si
|
|
|
|
|
cmp byte ptr [bx+246Ah], 0
|
|
|
|
|
jz short loc_BA78
|
|
|
|
|
mov word_FC62, 0
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BA78:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov byte ptr [si+246Ah], 1
|
|
|
|
|
mov byte ptr [si+0A59h], 1
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BA82:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop di
|
|
|
|
|
pop si
|
|
|
|
|
leave
|
|
|
|
|
retn 4
|
|
|
|
|
sub_B908 endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_BA88 proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
call sub_B424
|
2014-08-20 14:45:24 +00:00
|
|
|
|
call text_clear
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, es:[bx+resident_t.RESIDENT_playchar_paletted][0]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
dec ax
|
|
|
|
|
cwd
|
|
|
|
|
sub ax, dx
|
|
|
|
|
sar ax, 1
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov _playchars[0], al
|
|
|
|
|
mov al, es:[bx+resident_t.RESIDENT_playchar_paletted][1]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
dec ax
|
|
|
|
|
cwd
|
|
|
|
|
sub ax, dx
|
|
|
|
|
sar ax, 1
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov _playchars[1], al
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov byte_FC5A, 0
|
|
|
|
|
mov byte_FC5B, 0
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp es:[bx+resident_t.key_mode], KM_KEY_KEY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_BAD4
|
2019-11-30 14:48:36 +00:00
|
|
|
|
setfarfp _input_mode, input_mode_key_vs_key
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_BAF9
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BAD4:
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
cmp es:[bx+resident_t.key_mode], KM_JOY_KEY
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jnz short loc_BAED
|
2019-11-30 14:48:36 +00:00
|
|
|
|
setfarfp _input_mode, input_mode_joy_vs_key
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp short loc_BAF9
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BAED:
|
2019-11-30 14:48:36 +00:00
|
|
|
|
setfarfp _input_mode, input_mode_key_vs_joy
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BAF9:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 10h
|
2014-11-23 21:25:22 +00:00
|
|
|
|
call frame_delay
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov word_FC62, 0
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BB06:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_B747
|
|
|
|
|
call sub_B4F3
|
|
|
|
|
call sub_B565
|
|
|
|
|
call sub_B636
|
|
|
|
|
call sub_B670
|
|
|
|
|
push 0
|
|
|
|
|
cmp byte_FC5A, 0
|
|
|
|
|
jz short loc_BB22
|
|
|
|
|
mov al, 0Fh
|
|
|
|
|
jmp short loc_BB24
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BB22:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, 8
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BB24:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2019-12-28 20:20:48 +00:00
|
|
|
|
call p_cursor_put
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 1
|
|
|
|
|
cmp byte_FC5B, 0
|
|
|
|
|
jz short loc_BB35
|
|
|
|
|
mov al, 0Fh
|
|
|
|
|
jmp short loc_BB37
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BB35:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, 0Ah
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BB37:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2019-12-28 20:20:48 +00:00
|
|
|
|
call p_cursor_put
|
2018-09-11 17:34:19 +00:00
|
|
|
|
call _input_reset_sense_key_held
|
2019-11-30 14:48:36 +00:00
|
|
|
|
call _input_mode
|
2018-09-11 17:34:19 +00:00
|
|
|
|
push _input_mp_p1
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 0
|
|
|
|
|
call sub_B908
|
2018-09-11 17:34:19 +00:00
|
|
|
|
push _input_mp_p2
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 1
|
|
|
|
|
call sub_B908
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.hi, high INPUT_CANCEL
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_BB82
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage 0
|
2014-08-27 04:03:08 +00:00
|
|
|
|
call graph_clear
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_showpage 0
|
2014-08-20 14:45:24 +00:00
|
|
|
|
call text_clear
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_B4D7
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_STOP
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, 1
|
|
|
|
|
pop bp
|
|
|
|
|
retn
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BB82:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp byte_FC5A, 0
|
|
|
|
|
jz short loc_BBB7
|
|
|
|
|
cmp byte_FC5B, 0
|
|
|
|
|
jz short loc_BBB7
|
2014-08-20 14:45:24 +00:00
|
|
|
|
call text_clear
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp word_FC62, 10h
|
|
|
|
|
jb short loc_BBB0
|
|
|
|
|
mov ax, word_FC62
|
|
|
|
|
imul ax, 6
|
2019-12-28 22:45:48 +00:00
|
|
|
|
mov dx, 200
|
2014-06-29 22:52:27 +00:00
|
|
|
|
sub dx, ax
|
2014-08-23 13:47:05 +00:00
|
|
|
|
mov PaletteTone, dx
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BBB0:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp word_FC62, 20h ; ' '
|
|
|
|
|
ja short loc_BC18
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BBB7:
|
2014-08-26 20:52:26 +00:00
|
|
|
|
cmp vsync_Count1, 3
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jb short loc_BBB7
|
2014-08-26 20:52:26 +00:00
|
|
|
|
cmp vsync_Count1, 4
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jbe short loc_BBD0
|
|
|
|
|
cmp word_FC66, 1
|
|
|
|
|
jle short loc_BBD0
|
|
|
|
|
dec word_FC66
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BBD0:
|
2014-08-26 20:52:26 +00:00
|
|
|
|
mov vsync_Count1, 0
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage byte_FC5C
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, 1
|
|
|
|
|
sub al, byte_FC5C
|
|
|
|
|
mov byte_FC5C, al
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_showpage al
|
2015-01-12 21:48:13 +00:00
|
|
|
|
call grcg_setcolor pascal, (GC_RMW shl 16) + 0
|
2019-11-10 23:18:22 +00:00
|
|
|
|
call grcg_byteboxfill_x pascal, large 0, (((RES_X - 1) / 8) shl 16) or (RES_Y - 1)
|
2014-08-27 04:52:58 +00:00
|
|
|
|
call grcg_off
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc word_FC62
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
inc es:[bx+resident_t.rand]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp loc_BB06
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BC18:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_B4D7
|
|
|
|
|
mov al, 0
|
|
|
|
|
pop bp
|
|
|
|
|
retn
|
|
|
|
|
sub_BA88 endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_BC1F proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
push si
|
|
|
|
|
call sub_B424
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov al, es:[bx+resident_t.RESIDENT_playchar_paletted][0]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
dec ax
|
|
|
|
|
cwd
|
|
|
|
|
sub ax, dx
|
|
|
|
|
sar ax, 1
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov _playchars[0], al
|
|
|
|
|
mov al, es:[bx+resident_t.RESIDENT_playchar_paletted][1]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov ah, 0
|
|
|
|
|
dec ax
|
|
|
|
|
cwd
|
|
|
|
|
sub ax, dx
|
|
|
|
|
sar ax, 1
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov _playchars[1], al
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov byte_FC5A, 0
|
|
|
|
|
mov byte_FC5B, 0
|
2019-11-30 14:48:36 +00:00
|
|
|
|
setfarfp _input_mode, input_mode_interface
|
2014-06-29 22:52:27 +00:00
|
|
|
|
xor si, si
|
|
|
|
|
jmp loc_BD8B
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BC63:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov word_FC62, 0
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BC69:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_B747
|
|
|
|
|
call sub_B4F3
|
|
|
|
|
call sub_B565
|
|
|
|
|
call sub_B636
|
|
|
|
|
call sub_B670
|
2018-09-11 17:34:19 +00:00
|
|
|
|
call _input_reset_sense_key_held
|
2019-11-30 14:48:36 +00:00
|
|
|
|
call _input_mode
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 0
|
|
|
|
|
cmp byte_FC5A, 0
|
|
|
|
|
jz short loc_BC8E
|
|
|
|
|
mov al, 0Fh
|
|
|
|
|
jmp short loc_BC90
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BC8E:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, 8
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BC90:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2019-12-28 20:20:48 +00:00
|
|
|
|
call p_cursor_put
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp byte_FC5A, 0
|
|
|
|
|
jz short loc_BCAE
|
|
|
|
|
push 1
|
|
|
|
|
cmp byte_FC5B, 0
|
|
|
|
|
jz short loc_BCA8
|
|
|
|
|
mov al, 0Fh
|
|
|
|
|
jmp short loc_BCAA
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BCA8:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, 0Ah
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BCAA:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2019-12-28 20:20:48 +00:00
|
|
|
|
call p_cursor_put
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BCAE:
|
2018-09-11 17:34:19 +00:00
|
|
|
|
push _input_sp
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push si
|
|
|
|
|
call sub_B908
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.hi, high INPUT_CANCEL
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_BCE3
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage 0
|
2014-08-27 04:03:08 +00:00
|
|
|
|
call graph_clear
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_showpage 0
|
2014-08-20 14:45:24 +00:00
|
|
|
|
call text_clear
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_B4D7
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_STOP
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, 1
|
|
|
|
|
jmp loc_BD97
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BCE3:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
or si, si
|
|
|
|
|
jnz short loc_BCF7
|
|
|
|
|
cmp byte_FC5A, 0
|
|
|
|
|
jz short loc_BCF7
|
|
|
|
|
cmp word_FC62, 0Ch
|
|
|
|
|
ja loc_BD8A
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BCF7:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
or si, si
|
|
|
|
|
jz short loc_BD29
|
|
|
|
|
cmp byte_FC5B, 0
|
|
|
|
|
jz short loc_BD29
|
2014-08-20 14:45:24 +00:00
|
|
|
|
call text_clear
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp word_FC62, 10h
|
|
|
|
|
jb short loc_BD22
|
|
|
|
|
mov ax, word_FC62
|
|
|
|
|
imul ax, 6
|
2019-12-28 22:45:48 +00:00
|
|
|
|
mov dx, 200
|
2014-06-29 22:52:27 +00:00
|
|
|
|
sub dx, ax
|
2014-08-23 13:47:05 +00:00
|
|
|
|
mov PaletteTone, dx
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BD22:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp word_FC62, 20h ; ' '
|
|
|
|
|
ja short loc_BD8A
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BD29:
|
2014-08-26 20:52:26 +00:00
|
|
|
|
cmp vsync_Count1, 3
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jb short loc_BD29
|
2014-08-26 20:52:26 +00:00
|
|
|
|
cmp vsync_Count1, 4
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jbe short loc_BD42
|
|
|
|
|
cmp word_FC66, 1
|
|
|
|
|
jle short loc_BD42
|
|
|
|
|
dec word_FC66
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BD42:
|
2014-08-26 20:52:26 +00:00
|
|
|
|
mov vsync_Count1, 0
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage byte_FC5C
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, 1
|
|
|
|
|
sub al, byte_FC5C
|
|
|
|
|
mov byte_FC5C, al
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_showpage al
|
2015-01-12 21:48:13 +00:00
|
|
|
|
call grcg_setcolor pascal, (GC_RMW shl 16) + 0
|
2019-11-10 23:18:22 +00:00
|
|
|
|
call grcg_byteboxfill_x pascal, large 0, (((RES_X - 1) / 8) shl 16) or (RES_Y - 1)
|
2014-08-27 04:52:58 +00:00
|
|
|
|
call grcg_off
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc word_FC62
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
inc es:[bx+resident_t.rand]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp loc_BC69
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BD8A:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc si
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BD8B:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp si, 2
|
|
|
|
|
jl loc_BC63
|
|
|
|
|
call sub_B4D7
|
|
|
|
|
mov al, 0
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BD97:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
pop si
|
|
|
|
|
pop bp
|
|
|
|
|
retn
|
|
|
|
|
sub_BC1F endp
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
; =============== S U B R O U T I N E =======================================
|
|
|
|
|
|
|
|
|
|
; Attributes: bp-based frame
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
sub_BD9A proc near
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push bp
|
|
|
|
|
mov bp, sp
|
|
|
|
|
call sub_B424
|
2020-02-19 16:45:19 +00:00
|
|
|
|
mov _playchars[0], 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov byte_FC5A, 0
|
|
|
|
|
mov byte_FC5B, 1
|
2019-11-30 14:48:36 +00:00
|
|
|
|
setfarfp _input_mode, input_mode_interface
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov word_FC62, 0
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BDC1:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_B747
|
|
|
|
|
call sub_B535
|
|
|
|
|
call sub_B565
|
|
|
|
|
call sub_B636
|
|
|
|
|
call sub_B670
|
|
|
|
|
push 0
|
|
|
|
|
cmp byte_FC5A, 0
|
|
|
|
|
jz short loc_BDDD
|
|
|
|
|
mov al, 0Fh
|
|
|
|
|
jmp short loc_BDDF
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BDDD:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, 8
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BDDF:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push ax
|
2019-12-28 20:20:48 +00:00
|
|
|
|
call p_cursor_put
|
2018-09-11 17:34:19 +00:00
|
|
|
|
call _input_reset_sense_key_held
|
2019-11-30 14:48:36 +00:00
|
|
|
|
call _input_mode
|
2018-09-11 17:34:19 +00:00
|
|
|
|
push _input_sp
|
2014-06-29 22:52:27 +00:00
|
|
|
|
push 0
|
|
|
|
|
call sub_B908
|
2018-09-11 17:34:19 +00:00
|
|
|
|
test _input_sp.hi, high INPUT_CANCEL
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jz short loc_BE21
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage 0
|
2014-08-27 04:03:08 +00:00
|
|
|
|
call graph_clear
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_showpage 0
|
2014-08-20 14:45:24 +00:00
|
|
|
|
call text_clear
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_B4D7
|
2014-11-27 18:35:54 +00:00
|
|
|
|
kajacall KAJA_SONG_STOP
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, 1
|
|
|
|
|
pop bp
|
|
|
|
|
retn
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BE21:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp byte_FC5A, 0
|
|
|
|
|
jz short loc_BE4F
|
2014-08-20 14:45:24 +00:00
|
|
|
|
call text_clear
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp word_FC62, 10h
|
|
|
|
|
jb short loc_BE48
|
|
|
|
|
mov ax, word_FC62
|
|
|
|
|
imul ax, 6
|
2019-12-28 22:45:48 +00:00
|
|
|
|
mov dx, 200
|
2014-06-29 22:52:27 +00:00
|
|
|
|
sub dx, ax
|
2014-08-23 13:47:05 +00:00
|
|
|
|
mov PaletteTone, dx
|
2014-08-23 14:11:16 +00:00
|
|
|
|
call far ptr palette_show
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BE48:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
cmp word_FC62, 20h ; ' '
|
|
|
|
|
ja short loc_BEB0
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BE4F:
|
2014-08-26 20:52:26 +00:00
|
|
|
|
cmp vsync_Count1, 3
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jb short loc_BE4F
|
2014-08-26 20:52:26 +00:00
|
|
|
|
cmp vsync_Count1, 4
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jbe short loc_BE68
|
|
|
|
|
cmp word_FC66, 1
|
|
|
|
|
jle short loc_BE68
|
|
|
|
|
dec word_FC66
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BE68:
|
2014-08-26 20:52:26 +00:00
|
|
|
|
mov vsync_Count1, 0
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_accesspage byte_FC5C
|
2014-06-29 22:52:27 +00:00
|
|
|
|
mov al, 1
|
|
|
|
|
sub al, byte_FC5C
|
|
|
|
|
mov byte_FC5C, al
|
2018-12-29 19:08:52 +00:00
|
|
|
|
graph_showpage al
|
2015-01-12 21:48:13 +00:00
|
|
|
|
call grcg_setcolor pascal, (GC_RMW shl 16) + 0
|
2019-11-10 23:18:22 +00:00
|
|
|
|
call grcg_byteboxfill_x pascal, large 0, (((RES_X - 1) / 8) shl 16) or (RES_Y - 1)
|
2014-08-27 04:52:58 +00:00
|
|
|
|
call grcg_off
|
2014-06-29 22:52:27 +00:00
|
|
|
|
inc word_FC62
|
2019-12-30 14:48:17 +00:00
|
|
|
|
les bx, _resident
|
2020-02-19 16:45:19 +00:00
|
|
|
|
inc es:[bx+resident_t.rand]
|
2014-06-29 22:52:27 +00:00
|
|
|
|
jmp loc_BDC1
|
|
|
|
|
; ---------------------------------------------------------------------------
|
|
|
|
|
|
2014-08-10 01:44:54 +00:00
|
|
|
|
loc_BEB0:
|
2014-06-29 22:52:27 +00:00
|
|
|
|
call sub_B4D7
|
|
|
|
|
mov al, 0
|
|
|
|
|
pop bp
|
|
|
|
|
retn
|
|
|
|
|
sub_BD9A endp
|
2014-11-22 08:29:09 +00:00
|
|
|
|
db 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2021-12-25 14:53:17 +00:00
|
|
|
|
op_03_TEXT ends
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
|
|
|
|
; ===========================================================================
|
|
|
|
|
|
2020-11-03 15:25:41 +00:00
|
|
|
|
SHARED segment word public 'CODE' use16
|
2021-05-03 06:38:40 +00:00
|
|
|
|
extern _game_exit_to_dos:proc
|
2021-04-10 15:56:06 +00:00
|
|
|
|
extern _snd_determine_mode:proc
|
2021-04-07 10:23:11 +00:00
|
|
|
|
extern _snd_load:proc
|
2021-03-31 11:26:43 +00:00
|
|
|
|
extern _game_exit:proc
|
2021-03-30 16:06:45 +00:00
|
|
|
|
extern _vector1_at:proc
|
2021-03-28 13:03:42 +00:00
|
|
|
|
extern CDG_PUT_8:proc
|
|
|
|
|
extern CDG_PUT_HFLIP_8:proc
|
2021-03-26 12:38:17 +00:00
|
|
|
|
extern FRAME_DELAY:proc
|
2021-03-23 15:43:06 +00:00
|
|
|
|
extern _input_reset_sense_key_held:proc
|
2021-03-18 17:47:00 +00:00
|
|
|
|
extern PI_PALETTE_APPLY:proc
|
|
|
|
|
extern PI_PUT_8:proc
|
2021-03-03 16:48:45 +00:00
|
|
|
|
extern SND_KAJA_INTERRUPT:proc
|
2021-01-30 16:14:14 +00:00
|
|
|
|
extern _game_init_op:proc
|
2021-01-05 18:16:19 +00:00
|
|
|
|
extern CDG_LOAD_SINGLE:proc
|
|
|
|
|
extern CDG_LOAD_SINGLE_NOALPHA:proc
|
|
|
|
|
extern CDG_LOAD_ALL_NOALPHA:proc
|
|
|
|
|
extern CDG_FREE:proc
|
2021-01-01 14:40:28 +00:00
|
|
|
|
extern GRAPH_PUTSA_FX:proc
|
2020-12-28 16:30:30 +00:00
|
|
|
|
extern PI_LOAD:proc
|
2020-09-06 19:55:48 +00:00
|
|
|
|
extern INPUT_MODE_INTERFACE:proc
|
|
|
|
|
extern INPUT_MODE_KEY_VS_KEY:proc
|
|
|
|
|
extern INPUT_MODE_JOY_VS_KEY:proc
|
|
|
|
|
extern INPUT_MODE_KEY_VS_JOY:proc
|
2020-09-19 16:41:48 +00:00
|
|
|
|
extern CDG_PUT_NOALPHA_8:proc
|
2020-09-05 17:03:48 +00:00
|
|
|
|
extern _hflip_lut_generate:proc
|
2015-03-03 09:20:20 +00:00
|
|
|
|
extern FRAME_DELAY_2:proc
|
2020-11-03 15:25:41 +00:00
|
|
|
|
SHARED ends
|
2014-06-29 22:52:27 +00:00
|
|
|
|
|
2015-02-18 11:07:37 +00:00
|
|
|
|
.data
|
2014-08-19 20:33:43 +00:00
|
|
|
|
|
2020-09-06 17:28:52 +00:00
|
|
|
|
extern _snd_sel_disabled:byte
|
2014-06-29 22:52:27 +00:00
|
|
|
|
db 0
|
|
|
|
|
db 0
|
|
|
|
|
db 0
|
|
|
|
|
db 0
|
|
|
|
|
db 0
|
|
|
|
|
db 0
|
|
|
|
|
db 1
|
|
|
|
|
db 0
|
|
|
|
|
db 0
|
|
|
|
|
db 2
|
|
|
|
|
db 0
|
|
|
|
|
db 3
|
|
|
|
|
db 5
|
|
|
|
|
db 4
|
|
|
|
|
db 6
|
2014-09-13 10:24:35 +00:00
|
|
|
|
gp1P_VS_CPU db 88h, 89h, 8Ah, 8Bh, 8Ch, 8Dh, 8Eh, 8Fh, 0
|
|
|
|
|
gp1P_VS_2P db 88h, 89h, 8Ah, 8Bh, 96h, 97h, 98h, 99h, 0
|
|
|
|
|
gpCPU_VS_CPU db 92h, 93h, 94h, 95h, 8Ch, 8Dh, 8Eh, 8Fh, 0
|
2020-02-21 14:08:10 +00:00
|
|
|
|
include th03/start[data].asm
|
2014-09-13 10:24:35 +00:00
|
|
|
|
gpSTART db 30h, 31h, 32h, 0
|
|
|
|
|
gpVS_START db 33h, 34h, 35h, 36h, 37h, 38h, 0
|
|
|
|
|
gpMUSIC_ROOM db 41h, 42h, 43h, 44h, 45h, 46h, 47h, 0
|
|
|
|
|
gpHISCORE db 82h, 83h, 84h, 85h, 86h, 0
|
|
|
|
|
gpOPTION db 3Dh, 3Eh, 3Fh, 40h, 0
|
|
|
|
|
gpQUIT db 48h, 49h, 4Ah, 0
|
|
|
|
|
gpRANK db 6Eh, 6Fh, 70h, 0
|
|
|
|
|
gpMUSIC db 4Bh, 4Ch, 4Dh, 4Eh, 0
|
|
|
|
|
gpKEYCONFIG db 5Ch, 5Dh, 5Eh, 5Fh, 60h, 61h, 0
|
|
|
|
|
g4SPACES db 0CFh, 0CFh, 0CFh, 0CFh, 0
|
|
|
|
|
gpEASY db 71h, 72h, 73h, 0
|
|
|
|
|
gpNORMAL db 74h, 75h, 76h, 77h, 0
|
|
|
|
|
gpHARD db 78h, 79h, 7Ah, 0
|
|
|
|
|
gpLUNATIC db 7Bh, 7Ch, 7Dh, 7Eh, 0
|
|
|
|
|
gpOFF db 0CFh, 0CFh, 5Ah, 5Bh, 0CFh, 0CFh, 0CFh, 0
|
|
|
|
|
gpFM_86 db 0CFh, 4Fh, 50h, 51h, 52h, 0CFh, 0CFh, 0
|
|
|
|
|
gpMIDI_SC88 db 53h, 54h, 55h, 56h, 57h, 58h, 59h, 0
|
|
|
|
|
gpTYPE1 db 62h, 63h, 64h, 65h, 0
|
|
|
|
|
gpTYPE2 db 62h, 63h, 64h, 66h, 0
|
|
|
|
|
gpTYPE3 db 62h, 63h, 64h, 67h, 0
|
|
|
|
|
gpKEY_VS_KEY db 68h, 69h, 6Ch, 6Dh, 68h, 69h, 0
|
|
|
|
|
gpJOY_VS_KEY db 6Ah, 6Bh, 6Ch, 6Dh, 68h, 69h, 0
|
|
|
|
|
gpKEY_VS_JOY db 68h, 69h, 6Ch, 6Dh, 6Ah, 6Bh, 0
|
2019-12-08 05:32:01 +00:00
|
|
|
|
_menu_sel db 0
|
|
|
|
|
_quit db 0
|
2014-08-10 01:44:54 +00:00
|
|
|
|
byte_D953 db 1
|
2019-12-08 05:32:01 +00:00
|
|
|
|
_main_menu_initialized db 0
|
|
|
|
|
_option_initialized db 0
|
2020-09-06 17:28:52 +00:00
|
|
|
|
public _CFG_FN
|
|
|
|
|
label _CFG_FN
|
2014-08-10 01:44:54 +00:00
|
|
|
|
aYume_cfg db 'YUME.CFG',0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
; char path[]
|
2014-08-10 01:44:54 +00:00
|
|
|
|
path db 'mainl',0
|
|
|
|
|
asc_D965 db ' ',0
|
|
|
|
|
aVfvcvbgngngbgn db '<27>f<EFBFBD>c<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>T<EFBFBD>l<EFBFBD>g<EFBFBD><67><EFBFBD>ɂȂ<C982><C882>Ă<EFBFBD><C482>܂<EFBFBD><DC82>B',0Ah,0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
aUmx db '<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>͂Q<CD82>D<EFBFBD>T<EFBFBD>l<EFBFBD>g<EFBFBD><67><EFBFBD>łȂ<C582><C882>Ɛ<EFBFBD><C690><EFBFBD><EFBFBD>ɃQ<C983>[<5B><><EFBFBD><EFBFBD><EFBFBD>v<EFBFBD><76><EFBFBD>C<EFBFBD>o<EFBFBD><6F><EFBFBD>܂<EFBFBD><DC82><EFBFBD>',0Ah,0
|
2014-08-10 01:44:54 +00:00
|
|
|
|
aViosrfvVVkvqbd db 0Ah
|
2014-06-29 22:52:27 +00:00
|
|
|
|
db '<27><><EFBFBD>萔<EFBFBD>ł<EFBFBD><C582><EFBFBD><EFBFBD>Q<EFBFBD>D<EFBFBD>T<EFBFBD>l<EFBFBD>g<EFBFBD><67><EFBFBD>ɐ<C990><D882>ւ<EFBFBD><D682>āA<C481><41><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>x<EFBFBD><78><EFBFBD>s<EFBFBD><73><EFBFBD>ĂˁB',0Ah,0
|
2014-08-10 01:44:54 +00:00
|
|
|
|
aCOul db '<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>1.dat',0
|
|
|
|
|
aGbgvgkxsslvVBb db 0Ah
|
2014-06-29 22:52:27 +00:00
|
|
|
|
db '<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>ł<EFBFBD><C582>B<EFBFBD><42><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>𑝂₵<F0919D82>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',0Ah,0
|
2014-08-10 01:44:54 +00:00
|
|
|
|
aMikoft_bft db 'MIKOFT.bft',0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
db 0
|
2014-08-23 10:08:48 +00:00
|
|
|
|
include libs/master.lib/bfnt_id[data].asm
|
2014-08-27 20:57:18 +00:00
|
|
|
|
include libs/master.lib/clip[data].asm
|
2014-08-27 22:05:06 +00:00
|
|
|
|
include libs/master.lib/edges[data].asm
|
2014-08-30 05:49:51 +00:00
|
|
|
|
include libs/master.lib/fil[data].asm
|
2014-08-21 20:07:58 +00:00
|
|
|
|
include libs/master.lib/dos_ropen[data].asm
|
2014-08-31 08:23:41 +00:00
|
|
|
|
include libs/master.lib/gaiji_backup[data].asm
|
2014-08-31 08:08:09 +00:00
|
|
|
|
include libs/master.lib/gaiji_entry_bfnt[data].asm
|
2014-08-27 03:42:48 +00:00
|
|
|
|
include libs/master.lib/grp[data].asm
|
2018-04-15 14:05:57 +00:00
|
|
|
|
include libs/master.lib/js[data].asm
|
2014-08-23 13:47:05 +00:00
|
|
|
|
include libs/master.lib/pal[data].asm
|
2014-08-27 00:40:09 +00:00
|
|
|
|
include libs/master.lib/pf[data].asm
|
2014-08-30 10:13:04 +00:00
|
|
|
|
include libs/master.lib/rand[data].asm
|
2014-08-28 05:54:38 +00:00
|
|
|
|
include libs/master.lib/sin8[data].asm
|
2014-08-15 12:26:44 +00:00
|
|
|
|
include libs/master.lib/tx[data].asm
|
2014-08-26 20:52:26 +00:00
|
|
|
|
include libs/master.lib/vs[data].asm
|
2014-08-27 23:37:48 +00:00
|
|
|
|
include libs/master.lib/wordmask[data].asm
|
2014-08-21 20:53:12 +00:00
|
|
|
|
include libs/master.lib/mem[data].asm
|
2014-08-23 16:07:02 +00:00
|
|
|
|
include libs/master.lib/super_entry_bfnt[data].asm
|
2014-08-22 20:31:44 +00:00
|
|
|
|
include libs/master.lib/superpa[data].asm
|
2020-09-06 17:28:52 +00:00
|
|
|
|
public _snd_active
|
2015-02-23 10:47:22 +00:00
|
|
|
|
_snd_active db 0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
db 0
|
2014-09-03 13:23:51 +00:00
|
|
|
|
include libs/master.lib/respal_exist[data].asm
|
2014-08-31 16:08:50 +00:00
|
|
|
|
include libs/master.lib/draw_trapezoid[data].asm
|
2014-11-17 03:54:40 +00:00
|
|
|
|
include th02/formats/pfopen[data].asm
|
2017-01-12 18:54:26 +00:00
|
|
|
|
include th03/formats/cdg[data].asm
|
2019-12-05 02:53:01 +00:00
|
|
|
|
public _MUSIC_TITLES
|
|
|
|
|
_MUSIC_TITLES label dword
|
2014-06-29 22:52:27 +00:00
|
|
|
|
dd aNo_1B@cVOul ; "NO.1 <20>@<40><><EFBFBD>͎<EFBFBD><CD8E><EFBFBD><EFBFBD><EFBFBD><EFBFBD>z<EFBFBD><7A><EFBFBD><EFBFBD> "
|
|
|
|
|
dd aNo_2B@B@Select ; "NO.2 <20>@ <20>@ Selection "
|
|
|
|
|
dd aNo_3Umx ; "NO.3 <20><><EFBFBD><EFBFBD><EFBFBD>d<EFBFBD><64><EFBFBD>k "
|
|
|
|
|
dd aNo_4Reincarnat ; "NO.4 Reincarnation "
|
|
|
|
|
dd aNo_5Dim_Dream ; "NO.5 Dim. Dream "
|
|
|
|
|
dd aNo_6TabulaRasa ; "NO.6 Tabula rasa<73>@<40>`<60><EFBFBD><F394928F><EFBFBD> "
|
|
|
|
|
dd aNo_7B@Maniacal ; "NO.7 <20>@ Maniacal Princess "
|
|
|
|
|
dd aNo_8CPOBLostDr ; "NO.8 <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>`Lost Dream "
|
|
|
|
|
dd aNo_9CMCvlyBDre ; "NO.9 <20><><EFBFBD><EFBFBD><EFBFBD>V<EFBFBD>Y <20>`Dream War "
|
|
|
|
|
dd aNo_10Cvc@mirab ; "NO.10 <20><><EFBFBD>@<40><><EFBFBD><EFBFBD><EFBFBD>I<EFBFBD>`Fight it out!"
|
|
|
|
|
dd aNo_11B@SailorO ; "NO.11 <20>@ Sailor of Time "
|
|
|
|
|
dd aNo_12Strawberr ; "NO.12 Strawberry Crisis!! "
|
|
|
|
|
dd aNo_13F ; "NO.13 <20>ꖂ<F1939D88>@<40><><EFBFBD>E<EFBFBD>_ "
|
|
|
|
|
dd aNo_14B@cvc@pri ; "NO.14 <09>@<40><><EFBFBD>@<40><><EFBFBD><EFBFBD> "
|
|
|
|
|
dd aNo_15B@lviuvC ; "NO.15 <09>@<40>v<EFBFBD><76><EFBFBD>̖<EFBFBD> "
|
|
|
|
|
dd aNo_16Umx ; "NO.16 <09><><EFBFBD><EFBFBD><EFBFBD>̐<CC90><C282><EFBFBD> "
|
|
|
|
|
dd aNo_17IiiuvCumo ; "NO.17 <20>i<EFBFBD><69><EFBFBD>̖<EFBFBD><CC96><EFBFBD> "
|
|
|
|
|
dd aNo_18MapleDrea ; "NO.18 Maple Dream... "
|
|
|
|
|
dd aNo_19CRlvLxu ; "NO.19 <20><><EFBFBD>l<EFBFBD>̋x<CC8B><78> "
|
|
|
|
|
dd aB@b@ ; " <20>@<40>@ "
|
|
|
|
|
dd aB@b@vpvxvivf ; " <20>@<40>@<40>p<EFBFBD><70><EFBFBD><EFBFBD><EFBFBD><EFBFBD> "
|
2019-12-05 02:53:01 +00:00
|
|
|
|
public _MUSIC_FILES
|
|
|
|
|
_MUSIC_FILES label dword
|
2014-06-29 22:52:27 +00:00
|
|
|
|
dd aOp_m_0 ; "op.m"
|
|
|
|
|
dd aSelect_m_0 ; "select.m"
|
|
|
|
|
dd a00mm_m ; "00mm.m"
|
|
|
|
|
dd a01mm_m ; "01mm.m"
|
|
|
|
|
dd a02mm_m ; "02mm.m"
|
|
|
|
|
dd a03mm_m ; "03mm.m"
|
|
|
|
|
dd a04mm_m ; "04mm.m"
|
|
|
|
|
dd a05mm_m ; "05mm.m"
|
|
|
|
|
dd a06mm_m ; "06mm.m"
|
|
|
|
|
dd aDec_m ; "dec.m"
|
|
|
|
|
dd a07mm_m ; "07mm.m"
|
|
|
|
|
dd a08mm_m ; "08mm.m"
|
|
|
|
|
dd aDemo1_m ; "demo1.m"
|
|
|
|
|
dd aDemo2_m ; "demo2.m"
|
|
|
|
|
dd aDemo3_m ; "demo3.m"
|
|
|
|
|
dd aDemo4_m ; "demo4.m"
|
|
|
|
|
dd aDemo5_m ; "demo5.m"
|
|
|
|
|
dd aEd_m ; "ed.m"
|
|
|
|
|
dd aScore_m ; "score.m"
|
2022-03-12 20:31:36 +00:00
|
|
|
|
include th02/op/polygons[data].asm
|
2017-01-09 20:10:33 +00:00
|
|
|
|
music_track_playing db 0
|
2014-08-10 01:44:54 +00:00
|
|
|
|
aNo_1B@cVOul db 'NO.1 <20>@<40><><EFBFBD>͎<EFBFBD><CD8E><EFBFBD><EFBFBD><EFBFBD><EFBFBD>z<EFBFBD><7A><EFBFBD><EFBFBD> ',0
|
|
|
|
|
aNo_2B@B@Select db 'NO.2 <20>@ <20>@ Selection ',0
|
|
|
|
|
aNo_3Umx db 'NO.3 <20><><EFBFBD><EFBFBD><EFBFBD>d<EFBFBD><64><EFBFBD>k ',0
|
|
|
|
|
aNo_4Reincarnat db 'NO.4 Reincarnation ',0
|
|
|
|
|
aNo_5Dim_Dream db 'NO.5 Dim. Dream ',0
|
|
|
|
|
aNo_6TabulaRasa db 'NO.6 Tabula rasa<73>@<40>`<60><EFBFBD><F394928F><EFBFBD> ',0
|
|
|
|
|
aNo_7B@Maniacal db 'NO.7 <20>@ Maniacal Princess ',0
|
|
|
|
|
aNo_8CPOBLostDr db 'NO.8 <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>`Lost Dream ',0
|
|
|
|
|
aNo_9CMCvlyBDre db 'NO.9 <20><><EFBFBD><EFBFBD><EFBFBD>V<EFBFBD>Y <20>`Dream War ',0
|
|
|
|
|
aNo_10Cvc@mirab db 'NO.10 <20><><EFBFBD>@<40><><EFBFBD><EFBFBD><EFBFBD>I<EFBFBD>`Fight it out!',0
|
|
|
|
|
aNo_11B@SailorO db 'NO.11 <20>@ Sailor of Time ',0
|
|
|
|
|
aNo_12Strawberr db 'NO.12 Strawberry Crisis!! ',0
|
|
|
|
|
aNo_13F db 'NO.13 <20>ꖂ<F1939D88>@<40><><EFBFBD>E<EFBFBD>_ ',0
|
|
|
|
|
aNo_14B@cvc@pri db 'NO.14 <20>@<40><><EFBFBD>@<40><><EFBFBD><EFBFBD> ',0
|
|
|
|
|
aNo_15B@lviuvC db 'NO.15 <20>@<40>v<EFBFBD><76><EFBFBD>̖<EFBFBD> ',0
|
|
|
|
|
aNo_16Umx db 'NO.16 <20><><EFBFBD><EFBFBD><EFBFBD>̐<CC90><C282><EFBFBD> ',0
|
|
|
|
|
aNo_17IiiuvCumo db 'NO.17 <20>i<EFBFBD><69><EFBFBD>̖<EFBFBD><CC96><EFBFBD> ',0
|
|
|
|
|
aNo_18MapleDrea db 'NO.18 Maple Dream... ',0
|
|
|
|
|
aNo_19CRlvLxu db 'NO.19 <20><><EFBFBD>l<EFBFBD>̋x<CC8B><78> ',0
|
|
|
|
|
aB@b@ db ' <20>@<40>@ ',0
|
|
|
|
|
aB@b@vpvxvivf db ' <20>@<40>@<40>p<EFBFBD><70><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ',0
|
|
|
|
|
aOp_m_0 db 'op.m',0
|
|
|
|
|
aSelect_m_0 db 'select.m',0
|
|
|
|
|
a00mm_m db '00mm.m',0
|
|
|
|
|
a01mm_m db '01mm.m',0
|
|
|
|
|
a02mm_m db '02mm.m',0
|
|
|
|
|
a03mm_m db '03mm.m',0
|
|
|
|
|
a04mm_m db '04mm.m',0
|
|
|
|
|
a05mm_m db '05mm.m',0
|
|
|
|
|
a06mm_m db '06mm.m',0
|
|
|
|
|
aDec_m db 'dec.m',0
|
|
|
|
|
a07mm_m db '07mm.m',0
|
|
|
|
|
a08mm_m db '08mm.m',0
|
|
|
|
|
aDemo1_m db 'demo1.m',0
|
|
|
|
|
aDemo2_m db 'demo2.m',0
|
|
|
|
|
aDemo3_m db 'demo3.m',0
|
|
|
|
|
aDemo4_m db 'demo4.m',0
|
|
|
|
|
aDemo5_m db 'demo5.m',0
|
|
|
|
|
aEd_m db 'ed.m',0
|
|
|
|
|
aScore_m db 'score.m',0
|
2022-03-12 20:31:36 +00:00
|
|
|
|
include th02/op/music_cmt_load[data].asm
|
2014-08-10 01:44:54 +00:00
|
|
|
|
aOp3_pi db 'op3.pi',0
|
|
|
|
|
aOpwin_bft db 'opwin.bft',0
|
|
|
|
|
aOp_m db 'op.m',0
|
|
|
|
|
aTl01_pi db 'TL01.PI',0
|
|
|
|
|
aTl02_pi db 'TL02.PI',0
|
2014-06-29 22:52:27 +00:00
|
|
|
|
db 0
|
2021-12-19 18:52:31 +00:00
|
|
|
|
public _SCOREDAT_FN
|
|
|
|
|
_SCOREDAT_FN dw offset aYume_nem
|
2014-06-29 22:52:27 +00:00
|
|
|
|
aYume_nem db 'YUME.NEM',0
|
2021-12-19 18:52:31 +00:00
|
|
|
|
evendata
|
2014-08-10 01:44:54 +00:00
|
|
|
|
off_E1FE dd a00sl_cd2
|
2014-06-29 22:52:27 +00:00
|
|
|
|
; "00SL.CD2"
|
|
|
|
|
dd a02sl_cd2 ; "02SL.CD2"
|
|
|
|
|
dd a04sl_cd2 ; "04SL.CD2"
|
|
|
|
|
dd a06sl_cd2 ; "06SL.CD2"
|
|
|
|
|
dd a08sl_cd2 ; "08SL.CD2"
|
|
|
|
|
dd a10sl_cd2 ; "10SL.CD2"
|
|
|
|
|
dd a12sl_cd2 ; "12SL.CD2"
|
|
|
|
|
dd a14sl_cd2 ; "14SL.CD2"
|
|
|
|
|
dd a16sl_cd2 ; "16SL.CD2"
|
|
|
|
|
db 3
|
|
|
|
|
db 1
|
|
|
|
|
db 5
|
|
|
|
|
db 4
|
|
|
|
|
db 4
|
|
|
|
|
db 2
|
|
|
|
|
db 3
|
|
|
|
|
db 4
|
|
|
|
|
db 3
|
|
|
|
|
db 2
|
|
|
|
|
db 3
|
|
|
|
|
db 1
|
|
|
|
|
db 4
|
|
|
|
|
db 1
|
|
|
|
|
db 4
|
|
|
|
|
db 2
|
|
|
|
|
db 2
|
|
|
|
|
db 5
|
|
|
|
|
db 4
|
|
|
|
|
db 5
|
|
|
|
|
db 1
|
|
|
|
|
db 5
|
|
|
|
|
db 2
|
|
|
|
|
db 4
|
|
|
|
|
db 5
|
|
|
|
|
db 5
|
|
|
|
|
db 3
|
[Maintenance] Distinguish between Shift-JIS and gaiji strings
The main point of the previous strings/ subdirectory was to bundle all
hardcoded strings for translators. And sure, *technically*, gaiji
strings are *both* strings *and* something you might want to translate.
But mainly, they're sprites with an attached enum, and their own
directory. Changes to the enum quickly tend to involve changes to the
strings that use these values, so it makes sense to keep both in the
same directory.
Especially since 82% of the previous strings/ directories consisted of
such gaiji strings.
That leaves the strings/ directory rather empty and nondescript though.
Recently though, I've been wanting to generally move all Shift-JIS text
to this directory. While that wouldn't *solve* the typical "text editor
accidentally a file upon save, due to wrongly detected encoding" issue,
it's at least a mitigation: If all Shift-JIS strings are in files that
contain nothing *but* Shift-JIS strings, a wrongly detected encoding
becomes immediately noticeable.
For that job, strings/ can have a more descriptive name though. Hence,
shiftjis/.
Part of P0141, funded by [Anonymous] and rosenrose.
2021-05-20 18:16:44 +00:00
|
|
|
|
include th03/gaiji/p_cursor[data].asm
|
2014-06-29 22:52:27 +00:00
|
|
|
|
db 0
|
|
|
|
|
db 0
|
2014-08-10 01:44:54 +00:00
|
|
|
|
a00sl_cd2 db '00SL.CD2',0
|
|
|
|
|
a02sl_cd2 db '02SL.CD2',0
|
|
|
|
|
a04sl_cd2 db '04SL.CD2',0
|
|
|
|
|
a06sl_cd2 db '06SL.CD2',0
|
|
|
|
|
a08sl_cd2 db '08SL.CD2',0
|
|
|
|
|
a10sl_cd2 db '10SL.CD2',0
|
|
|
|
|
a12sl_cd2 db '12SL.CD2',0
|
|
|
|
|
a14sl_cd2 db '14SL.CD2',0
|
|
|
|
|
a16sl_cd2 db '16SL.CD2',0
|
|
|
|
|
aSlex_cd2 db 'slex.cd2',0
|
|
|
|
|
a99sl_cdg db '99sl.cdg',0
|
|
|
|
|
aSlwin_cdg db 'slwin.cdg',0
|
|
|
|
|
aSlex_cdg db 'slex.cdg',0
|
|
|
|
|
aSelect_m db 'select.m',0
|
|
|
|
|
aChname_bft db 'chname.bft',0
|
|
|
|
|
aTlsl_rgb db 'TLSL.RGB',0
|
2014-09-18 15:20:12 +00:00
|
|
|
|
db 041h, 0C1h, 0E1h, 0
|
2015-02-18 11:07:37 +00:00
|
|
|
|
.data?
|
|
|
|
|
|
2019-12-08 05:32:01 +00:00
|
|
|
|
_main_input_allowed db ?
|
|
|
|
|
_option_input_allowed db ?
|
|
|
|
|
_in_option db ?
|
2014-06-29 22:52:27 +00:00
|
|
|
|
db ?
|
2019-12-08 05:32:01 +00:00
|
|
|
|
_putfunc dw ?
|
2014-08-27 20:57:18 +00:00
|
|
|
|
include libs/master.lib/clip[bss].asm
|
2014-08-30 05:49:51 +00:00
|
|
|
|
include libs/master.lib/fil[bss].asm
|
2018-04-15 14:05:57 +00:00
|
|
|
|
include libs/master.lib/js[bss].asm
|
2014-08-23 13:47:05 +00:00
|
|
|
|
include libs/master.lib/pal[bss].asm
|
2014-08-26 20:52:26 +00:00
|
|
|
|
include libs/master.lib/vs[bss].asm
|
2014-08-26 21:58:08 +00:00
|
|
|
|
include libs/master.lib/vsync[bss].asm
|
2014-08-21 20:53:12 +00:00
|
|
|
|
include libs/master.lib/mem[bss].asm
|
2014-08-22 20:31:44 +00:00
|
|
|
|
include libs/master.lib/superpa[bss].asm
|
[Reverse-engineering] 32-bit VRAM plane pointers
I've looked at every openly available piece of PC-98 documentation, and there
don't seem to be any official names for the individual planes. The closest
thing I could find was the description at
http://island.geocities.jp/cklouch/column/pc98bas/pc98disphw2.htm
explaining that they represent the blue, red, green, and brightness component
when using the default PC-98 palette. However, these planes correspond to
nothing else but the 4 individual bits of the final index into the color
palette, and you can assign any color to every single palette slot. Therefore,
it's merely a convention that your own palettes don't have to follow (and in
Touhou, they don't).
Nevertheless, there doesn't seem to be an alternative, and the Neko Project II
source code uses the same B/R/G/E convention, so I'll go with that as well.
2015-02-10 22:43:34 +00:00
|
|
|
|
include th01/hardware/vram_planes[bss].asm
|
2015-03-15 21:54:15 +00:00
|
|
|
|
include th02/snd/snd[bss].asm
|
|
|
|
|
include th02/snd/load[bss].asm
|
2014-11-16 03:00:41 +00:00
|
|
|
|
include libs/master.lib/pfint21[bss].asm
|
2018-09-11 17:34:19 +00:00
|
|
|
|
include th03/hardware/input[bss].asm
|
2017-01-12 18:54:26 +00:00
|
|
|
|
include th03/formats/cdg[bss].asm
|
2014-11-18 16:56:13 +00:00
|
|
|
|
include th02/formats/pi_slots[bss].asm
|
2017-01-07 21:30:46 +00:00
|
|
|
|
include th03/formats/hfliplut[bss].asm
|
2022-03-12 20:31:36 +00:00
|
|
|
|
include th02/op/music[bss].asm
|
|
|
|
|
include th03/op/cmt_back[bss].asm
|
|
|
|
|
include th02/op/music_cmt[bss].asm
|
2021-12-21 13:14:28 +00:00
|
|
|
|
public _hi
|
|
|
|
|
_hi scoredat_section_t <?>
|
2014-08-10 01:44:54 +00:00
|
|
|
|
word_FC52 dw ?
|
2019-12-30 14:48:17 +00:00
|
|
|
|
public _resident
|
|
|
|
|
_resident dd ?
|
2020-02-19 16:45:19 +00:00
|
|
|
|
public _playchars
|
|
|
|
|
_playchars db PLAYER_COUNT dup (?)
|
2014-08-10 01:44:54 +00:00
|
|
|
|
byte_FC5A db ?
|
|
|
|
|
byte_FC5B db ?
|
|
|
|
|
byte_FC5C db ?
|
2014-07-05 21:03:42 +00:00
|
|
|
|
db ?
|
2019-11-30 14:48:36 +00:00
|
|
|
|
include th03/hardware/input_modes[bss].asm
|
2014-08-10 01:44:54 +00:00
|
|
|
|
word_FC62 dw ?
|
|
|
|
|
word_FC64 dw ?
|
|
|
|
|
word_FC66 dw ?
|
|
|
|
|
byte_FC68 db ?
|
2014-06-29 22:52:27 +00:00
|
|
|
|
db ? ;
|
|
|
|
|
|
2015-02-19 06:46:36 +00:00
|
|
|
|
end
|