@dcturner thank you :] this reminds me my toilet flush indeed.
Another one and it is really not what I was trying to do some hours ago...
x=64y=64 c=1i=0 p=128 pset(x,y,1) while 1 do x+=1+rnd(2) y+=1+rnd(2) if(x>p)x=p if(x<0)x=0 if(y>p)y=p if(y<0)y=0 pset(x,y,c) c+=.0001 end 
I couldn't get mountains in under the character count, so I decided to fly over Kansas instead.
n=15 t=0::s::cls()t=1 for i=0,n do z=(i*n+t%n)/1500 for j=n,n do c=sin(t/300)pset((j*.7+c)/z+64,(j*c/9+c/3+1)/z+64,9)end end flip()goto s 
I made a compilation of all my tweetcarts (20 so far) in one cartridge to see how it could work.
There is free tokens for about 4x more so we could do a prety long animation everyone together, maybe with a random switch.
It was not so hard to do, but I had to use labels, so some manual work is required. I needed to add one line in each cart loop and one line to link label and cart's id. My early carts needed some rewrite (those using _draw, some with no loop at all). I also renamed labels inside carts, but it may be skipped if included in a local scope.
If someone is good at scripting, maybe it could be automated ...
Enjoy.
s={0,0,0,48,24,48,84}::a::cls()u=rnd(3)1 for x=0,7 do for y=1,7 do c=7 if((s[y]+204)/2^x%2<1)c=0 pset(60+x,60+u+y,c)end end flip() goto a 
Small 1bit sprite decoder with just enough space left to make it hop.
t=1r=40n=64s=sin::a::cls()for i=0,r do for j=0,r do line(s(t/8)*n+n,s(i/8+.3)*n+n,s(j/8)*r+n,s(j/8+.3)*r+n,t%5+8)end end t+=.08 flip()goto a 
Riffing on knarf's "not what it was meant to be". 138 chars.
poke(24364,5)x=64y=64 t={0,5,6,7}c=1i=0p=64 ::s:: x+=.5+rnd(1) y+=.5+rnd(1) x%=p y%=2*p circ(x,y,1+rnd(1),t[flr(c)%4+1])c+=.0001 goto s 
tried some metaballs but for some reason I have no idea how many chALL GLORY TO THE HYPNOTOAD!

I told you to stop poking at the lava lamp. Now it's gone all fuzzy.
m=0x6000 t=1::s:: t+=.001 x=flr(rnd(63)) y=flr(rnd(127)) a=m+flr(x+y*64) v=flr(t+(sin((y)/128)+sin(x/64))*64) poke(a,v) goto s 
God this is hard, original effect had motion as well, got like 10 chars away but couldn't get it. (added more after removing motion, so I was doing stuff like just using circ
)
::s::circfill(64,64,rnd(10),10) for x=0,128 do for y=0,128 do c=pget(x,y) if(rnd(2)+c<c+1)pset(x,y,c/2)pset(x,y+1,c*0.9)end end goto s 
140
poke(24364,7)w=8z=1i=.0001p=64x=0y=0s=sin::a:: x+=1+s(z) y+=1+s(i) x%=p y%=p w+=i if(w>192)w=8 circ(x,y,1,flr(2+s(x/w)+s(y/w)+z))z+=i goto a 
t=0::s::w=64 t+=.01 z=40+9*cos(t)for y=w,w do q=z+4*cos(y/w)for x=w,w do e=z+4*sin(x/w)pset(x+w,y+w,bxor(x/q+t,y/et*2)%2+1)end end goto s 
It's that Amiga effect.
t=0::s::w=64 t+=.01 for y=w,w do q=16+8*cos(t+y/(w*2))for x=w,w do pset(x+w,y+w,bxor(x/q,y/16t*8)%2+1)end end goto s 
t=0v=1/32h=1::g::cls()for i=0,9 do s=t+0.1*i ?i,64+cos(s)*40,64+sin(s)*40,15i end circ(64,26,10,1)t+=v if(btnp(4))h=32/31 v/=h flip()goto g 
140/140
Shitty wheel of fortune. Press Z to stop the wheel and Ctrl+R to restart.
I found a solution to prevent cheating by just pressing the arrow up: it is now a real, complete game ha ha.
🐤 FLAPPYTWEET 2
 Use arrow up to jump over the walls
 If you hit a wall, the floor or the ceiling, you die
140 chars:
y=1 w=128 t=0 while y>0 do cls()t+=1 srand(flr(t/w))x=wt%w y+=1 if(btn(2))y=3 pset(9,y)i=rnd(w)line(x,i,x,w) if(x==9 and y>i)y=0 flip()end 
Made this slow abstract thing by accident last night?
cls() f=128 t=0 p=0 while 1 do for i=1,f do a=flr(t/f) pset(f+t%f+a,t%f,(t%p/8+rnd(t%a/8))%86) t+=10 end p+=1 end 
all your brains are belong to us.
p={0,1,5,6,7,6,5,1}u=64t=0::z::x=urnd(128)y=urnd(128)pset(x+u,y+u,16*atan2(x,y)sqrt(x*x+y*y))c=1+flr(rnd(8))pal(t+c,p[c],1)t+=0.01 goto z 
I wanted to recreate one of the scene from the "Best Illusion of The Year Contest" winner entry named "Motion Integration Unleashed: New Tricks for an Old Dog", so I created an illusion with the so named "Gabor elements". You can watch the original illusion in the video at 0:35.
cls(6)z=0::s:: z+=.001 for a=0,90 do x=a%7 y=(ax)*10/7+1 x*=20 for i=x,x+3 do b=sin(z)*(61y)/5+i line(i,y,i,y+5,b%3+5)end end goto s 
It took a while to figure out that I can use cls(6) instead of rectfill(0,0,128,128,6). I had to cut out some features to keep the 140 character limit: in the video the Gabor elements rolling the other direction in every second column, you can reenable modifying the 9th line to:
b=sin(z)*cos(x/40)*(61y)/5+i 
I managed to reorganize the code and made every other column rolling counterwise.
cls(6)z=0::s:: z+=.001 for a=0,90 do c=a%7y=1+10/7*(ac)for i=c*20,c*20+3 do b=i+sin(z)*cos(c/2)/5*(61y)line(i,y,i,y+5,b%3+5)end end goto s 
139 chars
a=24576;t=0;v=126 function _draw()t+=.01 memcpy(a,a+63,8129)c=1+rnd(t)x=rnd(v)h=vrnd(t)rectfill(x1,h1,x+6,v,0)rectfill(x,h,x+5,128,c)end 
140.
t=73p={t}n=128 function _draw()cls()for i=n,2,1 do p[i]=p[i1]x=p[ni]or 0rect(x,ni,x+1,n,i)end t+=0.02 p[1]+=sin(t)+sin(t/2)+cos(t/3) end 
Same as curtain but without the cls(). 135.
I tried to draw some static optical illusion but i think it's a fail :p
At least it has less than 140 chars !
cls() n=30 a=64 b=a*2 for i=0,n do x=a+a*sin(i/n) y=a+a*cos(i/n) line(x,y,a,a,7) end for i=0,5 do line(11+i*b/6,0,11+i*b/6,b,8) end 
FIRE ORB
cls()::s:: a=rnd()r=rnd(63)x=64+cos(a)*r y=65+sin(a)*r cl=pget(x,y) if(rnd()<.01)cl+=1 if(r>62.9)cl=8 circ(x,y1,1,cl)goto s 
My attempt at some sort of game :D
When the red bug appears, press "Z" to squash it. Wait too long, and game over! You get less and less time to squash the bug as time goes on.
Of course characters needed to be saved... so the game crashes to indicate you lost :)
t=0q=rnd(150)r=30 cls()function _draw()t+=1 if(t>q)pset(q%128,q%128,8) if(btn(4) and t>q)then cls()q+=rnd(99)+20 r=1 end if(t>q+r)x+=1 end 
Exactly 140 characters!
Nice, grey! It's an actual game. :)
If you reformat a bit, you can get a few chars back and make the crash report a little more meaningful to the player:
t=0q=rnd(150)r=30 cls()function _draw()t+=1 if(t>q)pset(q%128,q%128,8) if(btn(4)and t>q)cls()q+=rnd(99)+20 r=1 if(t>q+r)you_missed_it() end 
poke(0x5f2c,7)t,c=0,0,0 ::a:: t+=.0009 for i=0,32 do c+=1 for j=2,2 do circ(32+j*cos(t)*3*i,32+j*sin(t)*4*i,i*sin(t)*15,c%16)end end goto a 
140
r=1 d=0 ::a:: d+=.01 d%=256 r+=.1 r%=192 for t=0,8,.05 do x=64+r*sin(t/8)+d*cos(d+t) y=64+r*cos(t/8)+d*sin(d+t) circ(x,y,2,r/8+d) end goto a 
So much awesome in this thread. We should do another "tweet" jam, but with 256 chars. I imagine even cooler stuff would come out of that.
More CRT worship.
o=128 l=o*64 d=l*3 m=memcpy pal(6,9)m(0,d,l)i=9::s::m(d,d*.6,l) for y=0,o do r=rnd(2)sspr(r,y+i/o,o,1,0,y*2)end flip()i*=2 if(r<1)i=9 goto s 
140 characters.
Ernõ Rubik sometimes dreamed of Tinkertoys as a child
139
n=127 t=0::l::cls()t+=0.005 x=64+64*sin(1.6*t)y=nn*abs(sin(t))line(x2,0,x+2,0,1)circ(x,y,y/10,8+y/42)rect(x25,120,x+25,n,12)flip()goto l 
I started collecting nice little tricks I learned from these carts, feel free to fork and add stuff and so on (I did not explain stuff too well):
https://gist.github.com/kometbomb/7ab11b8383d3ac94cbfe1be5fb859785
138
a="\128\132\133\134\135\136\137\138\140\141\143\144\146\147\150\152\153"r=rnd::l::i=r(#a)print(sub(a,i,i),r(122),r(124),r(16))flip()goto l 
 Restart the cart to generate another.
p=print r=rnd cls(3)rectfill(0,0,127,50,12)p("\143",20,20,10)for i=1,50 do p("\149",r(120),49+r(78),8+r(4))end p("\138",r(119),45+r(80),6) 
 Inspired by the tweetcart Tileset Maker by Alberton. Pause to have a look!
h="\130\134\138\140"b="\137\146"r=rnd::a::for x=0,96,8 do c=1+r(15)i=1+r(4)j=1+r(2) ?sub(h,i,i),x,117,c ?sub(b,j,j),x,121,c end ?"\n" goto a 
t=1w=128::s:: t+=.00002 x=rnd(w)y=rnd(w) v=(t+(sin(y/w)+sin(x/w))) if(rnd(1000)<.01)circfill(x,y,30,8) v=flr(v%1+.5)*7 circ(x,y,1,v) goto s 
Well with all this tweetcarts, I guess tokens limit is not an excuse anymore for not making kickass titlescreen for all our future games
This thread alone was worth getting a license in my opinion. Tonight I'll try and make myself come back and add my own contribution in this space:
Here it is, a quicky bouncy ball
I definitely have some spare room, but I'm not sure I can fit multiball in.
x=9 y=9 a=2 b=1 ::t::cls() circfill(x,y,6,5) line(x4,y2,x2,y4,7) x+=a y+=b if((x<8)or(x>119))a*=1 if((y<8)or(y>119))b*=1 flip()goto tt 
edit changed it to the lean/correct 140 char version.
bloated sound and anim version:
136
More blood on water :)
Once I got the waterfall effect going, the Contra theme song popped in my head. :)
::a::c={1,12,7} x=rnd(128) y=rnd(128) p=pget(x,y) pset(x,y,c[1+flr(rnd(#c))]) rect(x,y+1,x,y+3,p) if(rnd(1000)<1)circ(64,64,48,8) goto a 
Struggled a lot minifying this, I'm very new to minifying. Got it though, not as much as I wanted but it's something. Every run it creates a kind of 'travelling salesman problem' map and then just creates random routes from one point to another, in random colours.
a={}cls()n=9 for i=0,n do a[i]={x=rnd(128),y=rnd(128)}end s=0 function _draw() e=flr(rnd(n))line(a[s].x,a[s].y,a[e].x,a[e].y,e+1)s=e end 
Had to cheat a little bit here for the cursor sprite, but the code is 140 characters. Uses this mouse stuff.
poke(24365,1)::a::x=stat(32)25y=stat(33)+2rectfill(x,y,x+50,y+8,12)rect(x,y,x+50,y+8,1)y+=2 print("error",x+2,y,7)spr(1,x+25,y)flip()goto a 
Here I'm cheating a lot, just for fun. Code is 126 and obviously could be much smaller.
poke(24365,1) palt(0,f) palt(14,1) ::a:: x=stat(32) y=stat(33) if(stat(34)>0)sspr(8,0,47,17,x27,y2) spr(7,x,y) flip() goto a 
[Please log in to post a comment]