PALLETTE.BAS. A set of GOSUBS for Pallette Manipulation

For posting library code and examples.
Post Reply
User avatar
ahenry3068
Posts: 1133
Joined: Tue Apr 04, 2023 9:57 pm

PALLETTE.BAS. A set of GOSUBS for Pallette Manipulation

Post by ahenry3068 »

A bunch of wrapper functions around VPOKE. To do useful things with the VERA Pallette.
Documentation in REM Statements of all the GOSUBS and what they do.
PALLETTE.BAS
(6.11 KiB) Downloaded 312 times
User avatar
ahenry3068
Posts: 1133
Joined: Tue Apr 04, 2023 9:57 pm

PALLETTE.BAS. BASLOAD Edition.

Post by ahenry3068 »

Updated these routines to use BASLOAD. Also updated SetDefPal (Set Default Palette) to BVLOAD DPAL.BIN if DPAL.BIN is available. Its faster than reading 512 bytes of DATA in a loop. Kept the Palette DATA in the code as a fallback, if you need the Memory getting rid of that DATA and the code to use it gets about 1kb back of RAM. Included FILEEXISTS subroutine to check for DPAL.BIN.

Also added PAL2BLACK Gosub.

HERES THE GOSUBS
PALLETTEB.zip
(2.95 KiB) Downloaded 243 times

I've written one additional procedure for my Palette Library since I posted. In my code this is inserted between SetDefPal and the Palette DATA. But the beauty of BASLOAD is you can really paste it anywhere in the source as long as its not in the middle of another GOSUB.
NEW GOSUB SAVEPAL2FILE
SAVEPAL.BAS
(312 Bytes) Downloaded 217 times
Last edited by ahenry3068 on Thu Nov 16, 2023 3:55 am, edited 2 times in total.
TomXP411
Posts: 1781
Joined: Tue May 19, 2020 8:49 pm

Re: PALLETTE.BAS. A set of GOSUBS for Pallette Manipulation

Post by TomXP411 »

Hi, thanks for submitting this, but we do require that downloads be complete, release-ready programs. I'm going to move this over to the programming topic in the main forum area, as that's where snippets and library code should be posted.

Thanks.
Post Reply