Open yiuxiu opened 3 years ago
How can I apply a force to an object to make it move in the specified direction? API is not very clear
@yiuxiu check out the Impulses example.
You apply impulses like this
https://github.com/pmndrs/cannon-es/blob/9d65831bf8834e2a4f721dad515ebd8ed639ec29/examples/impulses.html#L40-L41
CANNON.Body.velocity Class
How can I apply a force to an object to make it move in the specified direction? API is not very clear