don't stand too close to the glass it's still a little upset
(299 chars)
pal({1,3,9,140,13,12,6,0,8,11,10,12,14,135,7},1)
c,s,f=cos,sin,circfill
p=0::_::p+=1poke(24414,17<<p%4)f(0,0,99,0)camera(-64,-64)z=.5+c(t()/8)/2
for y=-40,40,3do for x=-38,38,3do
u,v=c(a)*x-s(a)*y,c(a)*y+x*s(a)q=c(y/4+t()+v/55)+s(x/3+t()+u/33)+c(v/66)+s(u/55)f(u,v,(.4+q/3)/z,15)end end
flip()goto _
|
this is so cool and beautiful. i wish i understood the code
hey pocketsound, its making use of the 24414 poke to change which bits of the color used when drawing are allowed to be changed each frame. the bitwise representation of 17 is 00010001, and << is a bitwise OR operation, and p is added to by 1 each frame. so p is modulo'd by 4, producing 0, 1, 2, or 3, which is used to bitwise OR (<<) 17, and 0/1/2/3 have bitwise representations of 00, 01, 10, 11, and OR combines values, so it shifts which bits/colors are being written to each frame with the circles drawn in color 15 (circfill is redefined as "f" at the top). 15 is 1111 bitwise, so it will modify whichever bits its allowed to each frame by the 24414 poke. a giant circle is also drawn every frame in color 0, but because of the bit masking poke, it only changes/"wipes" bits for 1/4 of the color bits each frame, making each one take 4 frames to get "cleared". over 4 frames, there are 16 different color combinations that can result from the 1111 being written with color 15 cycled across the bits, and when all 3 overlap, it will always make 15, which is remapped to 7 in the pal() call at the top. juicy stuff
[Please log in to post a comment]




