mirror of
https://github.com/photonstorm/phaser
synced 2025-01-11 04:38:51 +00:00
28 lines
375 B
JavaScript
28 lines
375 B
JavaScript
|
var Acceleration = {
|
||
|
|
||
|
setAccelerationX: function (x)
|
||
|
{
|
||
|
this.accel.x = x;
|
||
|
|
||
|
return this;
|
||
|
},
|
||
|
|
||
|
setAccelerationY: function (y)
|
||
|
{
|
||
|
this.accel.y = y;
|
||
|
|
||
|
return this;
|
||
|
},
|
||
|
|
||
|
setAcceleration: function (x, y)
|
||
|
{
|
||
|
this.accel.x = x;
|
||
|
this.accel.y = y;
|
||
|
|
||
|
return this;
|
||
|
}
|
||
|
|
||
|
};
|
||
|
|
||
|
module.exports = Acceleration;
|