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

Jelpi sprites / useful functions

A topic by Josiah Winslow created Jul 27, 2019 Views: 242 Replies: 2
Viewing posts 1 to 2
Submitted (1 edit)

I've created some forward and backward facing sprites of Jelpi (the guy in the sample minigame, and in the transition screen) for my own minigame, and I thought you all could get some use out of them. They are all in this cart.

Also included are two functions which I found useful: a function for drawing ellipses (stretched circles), and a function for fading out the palette. They're also copied here, if you want to copy-paste directly from here.


--fill ellipse
function elipfill(x,y,rx,ry,c)
 for i=y-ry+.5,y+ry-.5 do
  local p=flr(rx*sqrt(ry*ry-y*y+2*y*i-i*i)/ry+.5)
  rect(x-p,i,x+p,i,c)
 end
end


--fade palette
function fadepal(fade)
 for j=1,15 do
  local c=j
  for k=1,mid(0,flr(fade*100)/22,0x4.bba2)+j*0x.10fd do
   c=tonum("0x"..sub("01121d64493d1de",c,c))
  end
  pal(j,c)
 end
end

Submitted

the front and back jelpis were already in the jam cart

Submitted

Heh, I literally made them a few minutes before the jam started. I guess he liked them enough to put them in that fast. 馃槢