home *** CD-ROM | disk | FTP | other *** search
- ;
- ; Z3LIB Module Name: Z3MSGH
- ; Author: Richard Conn
- ; Z3LIB Version Number: 1.3
- ; Module Version Number: 1.1
- ;
- public putshm
-
- ext getmsg
-
- ;
- ; PUTSHM sets the value of the shell message specified in B. This
- ; value is input in the A register. No registers are affected. There are
- ; only three shell messages, so 0 <= B <= 2.
- ;
- putshm:
- push hl ;save HL
- push de ;save DE
- push af ;save value
- call getmsg ;get ptr to messages
- ld de,13 ;offset to registers
- add hl,de
- ld a,b ;get register number
- add a,l ;make HL pt to register
- ld l,a
- ld a,h
- adc a,0
- ld h,a
- pop af ;get value
- ld (hl),a ;put register value
- pop de ;get DE
- pop hl ;get HL
- ret
-
- end