You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/input/Input.js
+5-12Lines changed: 5 additions & 12 deletions
Original file line number
Diff line number
Diff line change
@@ -32,20 +32,13 @@ Phaser.Input = function (game) {
32
32
this.hitContext=null;
33
33
34
34
/**
35
-
* @property {array} moveCallbacks - An array of callbacks that will be fired every time the activePointer receives a move event from the DOM.
35
+
* An array of callbacks that will be fired every time the activePointer receives a move event from the DOM.
36
+
* To add a callback to this array please use `Input.addMoveCallback`.
37
+
* @property {array} moveCallbacks
38
+
* @protected
36
39
*/
37
40
this.moveCallbacks=[];
38
41
39
-
/**
40
-
* @property {function} moveCallback - An optional callback that will be fired every time the activePointer receives a move event from the DOM. Set to null to disable.
41
-
*/
42
-
this.moveCallback=null;
43
-
44
-
/**
45
-
* @property {object} moveCallbackContext - The context in which the moveCallback will be sent. Defaults to Phaser.Input but can be set to any valid JS object.
46
-
*/
47
-
this.moveCallbackContext=this;
48
-
49
42
/**
50
43
* @property {number} pollRate - How often should the input pointers be checked for updates? A value of 0 means every single frame (60fps); a value of 1 means every other frame (30fps) and so on.
51
44
* @default
@@ -445,7 +438,7 @@ Phaser.Input.prototype = {
445
438
* Adds a callback that is fired every time the activePointer receives a DOM move event such as a mousemove or touchmove.
446
439
*
447
440
* The callback will be sent 4 parameters: The Pointer that moved, the x position of the pointer, the y position and the down state.
448
-
441
+
*
449
442
* It will be called every time the activePointer moves, which in a multi-touch game can be a lot of times, so this is best
450
443
* to only use if you've limited input to a single pointer (i.e. mouse or touch).
451
444
* The callback is added to the Phaser.Input.moveCallbacks array and should be removed with Phaser.Input.deleteMoveCallback.
0 commit comments