lifecycle.onTrigger

Section: Lifecycle

What it does

onTrigger is a lifecycle function: you write it in your script and the engine calls it. The engine calls it: trigger volume enter. It receives other.

The API says: trigger volume enter

Signature

onTrigger(other)

Arguments

  • other

Example · generated

function onTrigger(other) {  ui.setText('hud', 'entered ' + other);}

onTrigger is not called, it is written. The engine calls it: trigger volume enter. The body shown here is an example of what goes in it.

7 members in lifecycle