Playing with physics in JS