0 Members and 1 Guest are viewing this topic.
"FONT":Asm(prgmSPRTFNT
"+FONT":Asm(prgmSPRTFNT
"-":Asm(prgmSPRTFNT
#include "ti83plus.inc"#define progStart $9D95.org progStart-2.db $BB,$6Dname = n-SpriteFont+9872hadjust = a-SpriteFont+9872hSetUpFont: bcall(_RclAns) sub 4 jr z,Parsedeacthook1: call Is_Hook_Active ret nz jp deacthook-SpriteFont+9872hParse: ex de,hl ld c,(hl) inc hl ld b,(hl) inc hl ld a,(hl) cp 71h jr z,deacthook1 cp 70h ;+ sign jr nz,LoadHook call Is_Hook_Active inc hl jr nz,LoadHook ld de,name+1 ldir xor a ld (de),a retLoadHook: push hl push bc ld hl,(fontHookPtr) ld a,(fontHookPtr+2) ld (prevhook),hl ld (prevpage),a ld hl,SpriteFont ld de,9872h ;appbackupscreen ld bc,SpriteFontEnd-SpriteFont ldir pop bc pop hl ld de,name+1 ldir xor a ld (de),a ld hl,9872h ld a,l bcall(4FE4h) ;Sets the font hook retIs_Hook_Active: ld a,(9872h) sub 83h ret nz bit 5,(iy+35h) ret nz push hl ld hl,(fonthookPtr) ld de,9872h sbc hl,de pop hl ret nzSpriteFont: .db 83h dec a jr z,$+5exithook: xor a inc a ret bit 1,(iy+8) jr nz,locate_replace push hldeacthook: .db 21hprevhook: .dw 0 .db 3Ehprevpage: .db 0 bcall(4FE4h) ;Sets the font hook pop hl jr exithooklocate_replace:;B is the char ld (restoreBC-SpriteFont+9872h),bc ld l,b ld h,a in a,(6) ld (restorePage-SpriteFont+9872h),a ld c,l ld b,h add hl,hl add hl,bc add hl,hl add hl,bc push hl ld hl,name rst 20h bcall(_ChkFindSym) pop hl jr c,deacthook ex de,hl inc hl inc hl add hl,de ld a,b or a jr z,ram_font+2 ld b,0 add hl,bc ld c,10 add hl,bc jp p,ram_font-SpriteFont+9872h inc a \ ld h,40hram_font: out (6),a ld de,lFont_record ld b,7 ld a,(hl) \ ld (de),a inc e \ inc l call z,adjust djnz $-7 ld hl,lFont_record .db 3EhrestorePage: .db 0 out (6),a .db 1restoreBC: .dw 0 xor a reta: inc h ret po in a,(6) inc a out (6),a ld h,40h retn: .db 15h,0,0,0,0,0,0,0,0SpriteFontEnd: