itch.io Spring Selects Series A
On Sale: GamesAssetsToolsTabletopComics
Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags

TIC-80

Fantasy computer for making, playing and sharing tiny games. · By Nesbox

How to use TIC with other palettes

A topic by Nesbox created Dec 17, 2016 Views: 1,716 Replies: 5
Viewing posts 1 to 3
Developer (1 edit) (+1)

work in progress...

I'm playing 'Quest for Glory' with pico8 palette here

pico8 palette is always eyes candy. Awesome work anyway. Hope I can try it soon.

Developer

Going to release the demo with 0.0.12

Thanks

(1 edit)

What about the pal() function from pico-8 ? If i want, say, to do a screen fade effect by changing the palette colors just like pico-8 in TIC how would i do it ?

Thanks for the great engine btw.

Developer

I see two ways:

  1. you can change palette RGB values directly in the RAM by using poke api function (here are 16 colors * 3 rgb=48 bytes by 0x3FC0 address);
  2. change color index in the PALETTE MAP using poke (here are 16 bytes with color indixes by 0x3FF0 addr);
64K RAM layout
--------------
0000-SCREEN
3FC0-PALETTE
3FF0-PALETTE MAP

Thanks.

(2 edits)

my demo

Hey i think i figured out the method!

Is something like this?

-- author: Victoro

-- desc: fade effect

-- script: lua

t=0

x=104

y=24

mode=0

scr={x=240,y=128}

local function fade()

if t<5 then

poke(0x3fc0,t*50)

poke(0x3fc1,t*50)

poke(0x3fc2,t*50)

return

else

poke(0x3fc0,0)

poke(0x3fc1,0)

poke(0x3fc2,0)

cls()

mode=1

end

end

function TIC()

t=t+0.06

cls()

if mode==0 then fade() end

if mode==1 then

spr(1+(t%6)/3,x,y,-1,4)

print("TIC-80",(scr.x//2)-19,(scr.y//2),t*10)

end

end