dwitter.net | mohd-akram (40)

+ New dweet
function u(t) {
} //
122/140


Please log in (or register) to post a dweet (copy-paste the code somewhere safe to save it meanwhile)


u(t) is called 60 times per second. t: Elapsed time in seconds. S: Shorthand for Math.sin. C: Shorthand for Math.cos. T: Shorthand for Math.tan. R: Function that generates rgba-strings, usage ex.: R(255, 255, 255, 0.5) c: A 1920x1080 canvas. x: A 2D context for that canvas.
Try the new frontend: beta.dwitter.net
Current theme challenge: #Opposites
show FPS hide FPS share 1 remix fullscreen

function u(t) {

}//
136/140


Please log in (or register) to post as a new dweet (copy-paste code somewhere safe to save it meanwhile).

Please log in (or register) to comment.

show FPS hide FPS share fullscreen

function u(t) {

}//
65/140


Please log in (or register) to post as a new dweet (copy-paste code somewhere safe to save it meanwhile).

  • Moon

Please log in (or register) to comment.

show FPS hide FPS share fullscreen

function u(t) {

}//
140/140


Please log in (or register) to post as a new dweet (copy-paste code somewhere safe to save it meanwhile).

Please log in (or register) to comment.

show FPS hide FPS share fullscreen

function u(t) {

}//
129/140


Please log in (or register) to post as a new dweet (copy-paste code somewhere safe to save it meanwhile).

  • AM wave

Please log in (or register) to comment.

show FPS hide FPS share 1 remix fullscreen

function u(t) {

}//
136/140


Please log in (or register) to post as a new dweet (copy-paste code somewhere safe to save it meanwhile).

  • u/quuxman
    I was hoping to shrink it to the point of adding little dots, but I don't think it's possible
  • u/quuxman
    I was hoping to shrink it to the point of adding little dots, but I don't think it's possible
  • u/quuxman
    c.width+=0 x.fillRect(0,0,w=2e3,w) x.fillStyle='#ff0' x.moveTo(a=t*500%w,b=540) x.arc(a,b,100,m=S(t*15)*.4+.4,-m) x.fill()
  • u/mohd-akram
    Yeah, that was my initial goal :D
  • u/mohd-akram
    c.width+=0;x.fillRect(0,0,w=2e3,w);y=540;t=t*y%w;for(i=w;i>=0;i-=5e2)if(!i||t<i)x.beginPath(),x.lineWidth=l=i?20:99,x.arc(i||t,y,l/2,m=i?.01:S(t/l*2)**2,-m),x.strokeStyle=R(y,y,i&&y),x.stroke()
  • u/joeytwiddle
    You could post the "too long" version on codegolf.tk if you like :)

Please log in (or register) to comment.

show FPS hide FPS share fullscreen

function u(t) {

}//
127/140


Please log in (or register) to post as a new dweet (copy-paste code somewhere safe to save it meanwhile).

  • Happy New Year!

Please log in (or register) to comment.

You've reached the end.