Moving squares on canvas using Node.js