Trigger
Trigger(
props):Element|null
A sphere of radius about its entity that meets its targets, by
default a character a player controls now: on the world that decides
it, inside while any target’s body is within it, and
TriggerEnteredEvent and TriggerExitedEvent as each comes and goes.
onEnter and onExit answer the player’s own entities alone: in a
game played alone on the step’s events, so one that passed through
between two frames still enters and exits. On a page in a room, they
answer from that page’s own test each frame, so they fire at once, and
a pass between two frames fires neither.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
props |
TriggerProps |
Returns
Section titled “Returns”Element | null