mirror of
https://github.com/photonstorm/phaser
synced 2024-11-26 06:30:38 +00:00
Fixed Shake effect
This commit is contained in:
parent
b7b10545f3
commit
76d2630f8b
1 changed files with 2 additions and 2 deletions
|
@ -237,8 +237,8 @@ var Shake = new Class({
|
||||||
if (this._elapsed < this.duration)
|
if (this._elapsed < this.duration)
|
||||||
{
|
{
|
||||||
var intensity = this.intensity;
|
var intensity = this.intensity;
|
||||||
var width = this.camera._cw;
|
var width = this.camera.width;
|
||||||
var height = this.camera._ch;
|
var height = this.camera.height;
|
||||||
var zoom = this.camera.zoom;
|
var zoom = this.camera.zoom;
|
||||||
|
|
||||||
this._offsetX = (Math.random() * intensity.x * width * 2 - intensity.x * width) * zoom;
|
this._offsetX = (Math.random() * intensity.x * width * 2 - intensity.x * width) * zoom;
|
||||||
|
|
Loading…
Reference in a new issue