Update: CC - Touch Move (c55930et90.js) 4 bytes modified
parent
e53648c594
commit
fa9b44dc7f
|
@ -12,15 +12,10 @@ if (!this.initialized) {
|
||||||
this.initialized = true;
|
this.initialized = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
touch.left *= sensitivity;
|
this.x -= Math.round(touch.left * sensitivity);
|
||||||
touch.right *= sensitivity;
|
this.x += Math.round(touch.right * sensitivity);
|
||||||
touch.up *= sensitivity;
|
this.y -= Math.round(touch.up * sensitivity);
|
||||||
touch.down *= sensitivity;
|
this.y += Math.round(touch.down * sensitivity);
|
||||||
|
|
||||||
this.x -= touch.left;
|
|
||||||
this.x += touch.right;
|
|
||||||
this.y -= touch.up;
|
|
||||||
this.y += touch.down;
|
|
||||||
|
|
||||||
if (this.x < 0) {
|
if (this.x < 0) {
|
||||||
this.x = 0;
|
this.x = 0;
|
||||||
|
|
Loading…
Reference in New Issue