-
Notifications
You must be signed in to change notification settings - Fork 2
/
misc_oz.asm
70 lines (64 loc) · 1.22 KB
/
misc_oz.asm
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
;Miscellaneous OZ routines for applications
;
;
;28/11/99
MODULE miscoz
SECTION code
INCLUDE "stdio.def"
INCLUDE "director.def"
XDEF ozread
XREF myflags
XREF redefine
.ozread
ld bc,0
call_oz(os_tin)
ret c
and a
ret nz
ld bc,0
call_oz(os_tin)
and a
ret z
;Deal with command a..for now, just ret
ld hl,myflags
sub $80
jr nz,oz_notq
;Quit
xor a
call_oz(os_bye)
.oz_notq
dec a ;$81 - display
jr nz,oz_notsize
ld a,(hl)
xor 8
ld (hl),a
.oz_notsize
dec a ;$82 - inverse
jr nz,oz_notinv
ld a,(hl)
xor 16
ld (hl),a
ret
.oz_notinv
dec a ;$83 - title music
jr nz,nottitmusic
ld a,(hl)
xor 2
ld (hl),a
ret
.nottitmusic
dec a ;$84 = samples on/off
jr nz,notsample
ld a,(hl)
xor 4
ld (hl),a
ret
.notsample
dec a ;$85 - redefine
ret nz
bit 1,(hl)
ret z
bit 2,(hl)
ret nz
; jp redefine
ret