       @pos.y = Math.min(Math.max(@pos.y, 0), canvas.height)
       @vel.y = -@vel.y * 0.5
 
-    @mass = Math.min(Math.max(@vel.mag()/10000, 0.1), 1)
+    @mass = Math.min(Math.max(@vel.mag()/1, 0.1), 1)
 
   draw: (ctx) =>
     ctx.save()

    ctx.restore()

class Animator
  constructor: (canvas) ->
    @$canvas = canvas
    @canvas = @$canvas[0]
    @$canvas.mousemove(@update_mouse_pos)
    @$canvas.mousedown(@explode_particles)
    @particles = @generate_particles(50)
    @tick = .001

  generate_particles: (num) ->
    colors = ['#FF5454', '#FF904A', '#FFCD57', '#FFFC85', '#FFF']

  pos: 
    x: 0
    y: 0
  mass: 1
$ ->
  MOUSE = 
    pos: new Vector(0, 0)
    mass: 1
  animator = new Animator($("canvas"))
  window.requestAnimationFrame(animator.draw)
