{"name":"bad fireworks alt","description":"Z and X launch more bad fireworks! alt fireworks are 'drippier' then the original\n\n-- bad fireworks alt\n-- alexthescott\n-- 8/24/21\n\np={137,142,143,135,141,13}\npal(p,1)\n\n-- contrived oop\nfunction add_splash()\n\tlocal b={}\n\t\n\tb.c=2+(rnd(3)\\1)*2\n\tb.sr=0\n\tb.br=1\n\tb.bv=0.25\n\tb.bm=(1+rnd(4)\\1)*3\n\tb.x=rnd(128)\n\tb.y=rnd(128)\n\t\n\tb.update=function(s)\n\t\ts.sr+=1\n\t\tif s.br>s.bm then\n\t\t\ts.bv=-0.25\n\t\telseif s.br<=0 then\n\t\t\ts.bv=0\n\t\tend\n\t\ts.br+=s.bv\n\tend\n\t\n\tb.draw=function(s)\n\t\tcirc(s.x,s.y,s.sr,b.c)\n\t\tif s.bv!=0 then\n\t\t\tcircfill(s.x,s.y,s.br,b.c)\n\t\tend\n\tend\n\t\n\tb.destroy=function(s)\n\t\tif s.bv==0 and s.sr>181 then\n\t\t\tdel(splash,s)\n\t\tend\n\tend\n\t\n\tadd(splash,b)\nend\n\n-- set btn delay\npoke(0x5f5d, 30)\n\nsplash={}\nadd_splash()\n\ncls()\n::♥::\n-- burn pixels\nfor p=0,2048 do\n\tpx=rnd(128)\n\tpy=rnd(128)\n\tpc=pget(px,py)\n\tif pc!=0 and pc%2==0 then\n\t\tif rnd(2)\\1==0 then\n\t\t\tpset(px,py+1,pc)\n\t\t\tpset(px,py+2,pc)\n\t\tend\n\t\tpset(px,py,pc-1)\n\telse\n\t\tpset(px,py,0)\n\tend\nend\n\nif t()<2 then\n\tprint(\"bad fireworks alt\",30,64,1)\nelse\n\n\t-- little boom\n\tif t()%3==0 then\n\t\tadd_splash()\n\tend\n\t\n\t-- 40 sec 'big' boom\n\tif t()%40==0 then\n\t\tfor i=1,10 do\n\t\t\tadd_splash()\n\t\tend\n\tend\n\t\n\t-- diy boom\n\tif btnp(4) or btnp(5) then\n\t\tadd_splash()\n\tend\n\t\n\t-- object loop\n\tfor s in all(splash) do\n\t\ts:draw()\n\t\ts:update()\n\t\ts:destroy()\n\tend\nend\nflip()\ngoto ♥","tags":["pico8","pico-8"],"symbol":"OBJKT","artifactUri":"ipfs://QmfJ9RBxjT5NFFL4DP2CAn9cPgUUvCmEkTqUKG7cZhJwaS","displayUri":"ipfs://QmboC2u6LRNwmMH4psm6TD2RcRX4oaAYuyUhXoYUKj5Jz7","thumbnailUri":"ipfs://QmboC2u6LRNwmMH4psm6TD2RcRX4oaAYuyUhXoYUKj5Jz7","creators":["tz1St3n29AbYXZXV8W1BG41qYzz86J2CFAW7"],"formats":[{"uri":"ipfs://QmfJ9RBxjT5NFFL4DP2CAn9cPgUUvCmEkTqUKG7cZhJwaS","mimeType":"application/x-directory"}],"decimals":0,"isBooleanAmount":false,"shouldPreferSymbol":false}