thats right, i made optimised sprite drawing for picotron, although, you might wanna have chatGPT do it for you...
function sprpt(s,x,y)
if s=="star!" then
rectfill(x+2,y+2,x+5,y+5,10)
rectfill(x+3,y,x+4,y+1,10)
pset(x,y+2,10)
pset(x+1,y+2,10)
pset(x+1,y+3,10)
pset(x+7,y+2,10)
pset(x+6,y+2,10)
pset(x+6,y+3,10)
pset(x+1,y+6,10)
pset(x+2,y+6,10)
pset(x+1,y+7,10)
pset(x+6,y+6,10)
pset(x+5,y+6,10)
pset(x+6,y+7,10)
end
if s=="heart!" then
rectfill(x,y+1,x+7,y+4,8)
rectfill(x+1,y,x+2,y+5,8)
rectfill(x+5,y,x+6,y+5,8)
rectfill(x+2,y+5,x+5,y+6,8)
rectfill(x+3,y+5,x+4,y+7,8)
end
end
function _update()
sprpt("star!",30,30)
end |
i spent more time on the star because even copy+paste does not save much
yes, admittedly, it does not work from data based sprites, its code based only! if you want an unoptimized lazy version, ill upload one later!
[Please log in to post a comment]




