phaser/src/physics/arcade/components/Friction.js

27 lines
357 B
JavaScript
Raw Normal View History

var Friction = {
setFriction: function (x, y)
{
this.body.friction.set(x, y);
return this;
},
setFrictionX: function (x)
{
this.body.friction.x = x;
return this;
},
setFrictionY: function (y)
{
this.body.friction.y = y;
return this;
}
};
module.exports = Friction;