by carson

Genuary 2023 Day 4 - Intersections

IPFS
Genuary 2023 Day 4 - Intersections

4 January 2023TEZOSIPFS

If you haven't seen my days 1-3 of #genuary, check out teia.art/carson

-- genuary #4 2023
-- intersections
-- by carson kompon

-- fxhash snippet
w=stat(6)s=1
for i=1,#w do
ch=ord(sub(w,i,i))s+=s*31+ch
end
srand(s)

-- main code
objs={}
am=10+rnd(32)
offset=rnd()
colstart=rnd(13)\1
colrange=2+rnd(4)\1
coldir=1
ss=rnd(-1)
if(colstart>13-colrange)coldir=-1
pal({[0]=7,136,8,137,9,10,138,11,139,3,131,1,140,12},1)
cls()
for i=1,16 do
for j=0,3 do
add(objs,{
x=8+rnd(112),
y=8+rnd(112),
c=1+colstart+(coldir*rnd(colrange)),
r=0,
len=4+rnd(80),
dir=offset+j/4,
spd=rnd()
})
end
end
::_::
srand(ss)
for i=1,999 do
x=rnd(128)
y=rnd(128)
c=pget(x,y)
pset(x+rnd(2)-1,y+rnd(2)-1,c)
end
for o in all(objs) do
o.x+=cos(o.dir)*o.spd
o.y+=sin(o.dir)*o.spd
circfill(o.x,o.y,o.r,o.c)
o.len-=1
if(o.len<=0)del(objs,o)
end
flip()
goto _

I make games and gameart. Currently studying game design :)

@CarsonKompon | carsonk.net

16 EDITIONS

0 RESERVES

minted

16 / 16

fixed price

0.5 TEZ
feedback

stay ahead with our newsletter

receive news on exclusive drops, releases, product updates, and more