matter.js how to use it ?
I'm include matter.js lib My code:
init = function()
x=0
y=0
end
update = function()
end
draw = function()
screen.clear()
screen.drawSprite("ball",x,y,8,8)
end
how to give gravity to ball ? how to add wall, that collide with it ? how to detect collides with walls ? how to give impulse to ball ?