{"name":"Genuary 2023 Day 11 - Suprematism","description":"-- genuary #11 2023\n-- suprematism\n-- by carson kompon\n\n-- credit: https://www.lexaloffle.com/bbs/?tid=34282\nfunction draw_polygon(points)\n\tlocal xl,xr,ymin,ymax={},{},129,0xffff\n\tfor k,v in pairs(points) do\n\t\tlocal p2=points[k%#points+1]\n\t\tlocal x1,y1,x2,y2=v[1],flr(v[2]),p2[1],flr(p2[2])\n\t\tif y1>y2 then\n\t\t\ty1,y2,x1,x2=y2,y1,x2,x1\n\t\tend\n\t\tlocal d=y2-y1\n\t\tfor y=y1,y2 do\n\t\t\tlocal xval=flr(x1+(x2-x1)*(d==0 and 1 or (y-y1)/d))\n\t\t\txl[y],xr[y]=min(xl[y] or 32767,xval),max(xr[y] or 0x8001,xval)\n\t\tend\n\t\tymin,ymax=min(y1,ymin),max(y2,ymax)\n\tend\n\tfor y=ymin,ymax do\n\t\trectfill(xl[y],y,xr[y],y)\n\tend\nend\n\n-- this function took me too long to write bc it's nearly 9pm\nfunction rectfillrot(x,y,w,h,r)\n\tw/=2\n\th/=2\n\tpoints={}\n\tadd(points,{\n\t\tx-cos(r)*w-cos(r+.25)*h,\n\t\ty-sin(r)*w-sin(r+.25)*h\n\t})\n\tadd(points,{\n\t\tx+cos(r)*w-cos(r+.25)*h,\n\t\ty+sin(r)*w-sin(r+.25)*h\n\t})\n\tadd(points,{\n\t\tx+cos(r)*w+cos(r+.25)*h,\n\t\ty+sin(r)*w+sin(r+.25)*h\n\t})\n\tadd(points,{\n\t\tx-cos(r)*w+cos(r+.25)*h,\n\t\ty-sin(r)*w+sin(r+.25)*h\n\t})\n\tdraw_polygon(points)\nend\n\ntears={}\ncounter=0\n\n::_::\n\tcls(0)\n\tcolor(1)\n\tif counter%12==0 then\n\t\tadd(tears,{\n\t\t\tx=24+((rnd(2)\\1)*80),\n\t\t\ty=24,spd=0,r=3+rnd(2)-1\n\t\t})\n\tend\n\tfor tear in all(tears) do\n\t\ttear.spd+=0.1\n\t\ttear.y+=tear.spd\n\t\tcircfill(tear.x,tear.y,tear.r)\n\t\tif(tear.y>=132)del(tears,tear)\n\tend\n\tcolor(8)\n\trectfillrot(24,24,32,8,t()/4)\n\trectfillrot(24,24,32,8,-t()/4)\n\trectfillrot(104,24,32,8,t()/4)\n\trectfillrot(104,24,32,8,-t()/4)\n\tcolor(9)\n\trectfillrot(64,54,28,10,-.125)\n\trectfill(49,60,77,68)\n\trectfill(63-12,80,63+12,82)\n\trectfill(63-18,86,63+18,90)\n\tcolor(10)\n\trectfillrot(42,100,82,6,-.0625)\n\trectfillrot(128-42,100,82,6,.0625)\n\tcolor(4)\n\trectfill(63-42,100,63+42,108)\n\tcounter+=1\n\tflip()\ngoto _\n","tags":["animated","opensource","pico8","pico-8","genuary","genuary11","pixelart","generative","creativecoding"],"symbol":"OBJKT","artifactUri":"ipfs://bafybeibfyvqyvtb4bgab5uayb6s3p6zshlplj4qw7vxvkh7vvb7vivnw7y","displayUri":"ipfs://QmYs1zab35tSghXkAYu3XVnry6u3vss724kRTJMJsSTzoC","thumbnailUri":"ipfs://QmYs1zab35tSghXkAYu3XVnry6u3vss724kRTJMJsSTzoC","creators":["tz1XqJ9e6NdouxdGvm2V3aknwFnGL6Kinu6A"],"formats":[{"fileSize":1003261,"fileName":"genuary_2023_11.zip","mimeType":"application/x-directory","uri":"ipfs://bafybeibfyvqyvtb4bgab5uayb6s3p6zshlplj4qw7vxvkh7vvb7vivnw7y"},{"mimeType":"image/gif","fileSize":850587,"fileName":"cover_genuary_2023_11.gif","dimensions":{"value":"512x512","unit":"px"},"uri":"ipfs://QmYs1zab35tSghXkAYu3XVnry6u3vss724kRTJMJsSTzoC"},{"mimeType":"image/gif","fileSize":850587,"fileName":"thumbnail_genuary_2023_11.gif","dimensions":{"value":"512x512","unit":"px"},"uri":"ipfs://QmYs1zab35tSghXkAYu3XVnry6u3vss724kRTJMJsSTzoC"}],"decimals":0,"isBooleanAmount":false,"shouldPreferSymbol":false,"rights":"cc-by-sa-4.0","date":"2023-01-12T02:13:20.604Z","mintingTool":"https://teia.art/mint"}