remake of cara platform using Javascript