mirror of
https://github.com/photonstorm/phaser
synced 2024-12-27 05:23:28 +00:00
27 lines
357 B
JavaScript
27 lines
357 B
JavaScript
|
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;
|