From eedb858a9f384ccccd5b1c0860f55d2ef788966d Mon Sep 17 00:00:00 2001 From: "B. Watson" Date: Mon, 19 Apr 2021 17:40:57 -0400 Subject: Save 4 bytes --- textdecomp.s | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to 'textdecomp.s') diff --git a/textdecomp.s b/textdecomp.s index 403507c..03660ae 100644 --- a/textdecomp.s +++ b/textdecomp.s @@ -11,7 +11,11 @@ ; See textcomp.c for details of encoded format. .include "atari.inc" + .export _print_msg + .export _print_item, _print_location + + .import _item, _location .import _cputc srcptr = FR1 @@ -180,6 +184,21 @@ table: ; outsnac values 53..63 .code .endif +; extern void __fastcall__ print_location(char loc) +_print_location: + asl + tay + lda _location,y + ldx _location+1,y + bne _print_msg ; branch always (location is never $00xx) + +; extern void __fastcall__ print_item(char item) +_print_item: + asl + tay + lda _item,y + ldx _item+1,y ; fall thru + _print_msg: sta srcptr stx srcptr+1 -- cgit v1.2.3