swapTarget(newTarget, silent)
This will change the Pointer.targetObject
object to be the one provided.
This allows you to have fine-grained control over which object the Pointer is targeting.
Note that even if you set a new Target here, it is still able to be replaced by any other valid
target during the next Pointer update.
Parameters
Name | Type | Argument | Default | Description |
---|---|---|---|---|
newTarget | Phaser.InputHandler | The new target for this Pointer. Note this is an | ||
silent | boolean | <optional> | false | If true the new target AND the old one will NOT dispatch their |
- Source code: input/Pointer.js (Line 886)
Please login to continue.