Navigation
These archived docs are for Phaser 2.4.6 Phaser 3 docs can be found on newdocs.phaser.io.
Phaser CE docs can be found on the Phaser CE Documentation site.

Constructor

Phaser.Component. InCamera

new InCamera()

The InCamera component checks if the Game Object intersects with the Game Camera.

Source code: gameobjects/components/InCamera.js (Line 12)

Public Properties

[readonly] inCamera : boolean

Checks if this Game Objects bounds intersects with the Game Cameras bounds.

It will be true if they intersect, or false if the Game Object is fully outside of the Cameras bounds.

An object outside the bounds can be considered for camera culling if it has the AutoCull component.

Source code: gameobjects/components/InCamera.js (Line 26)