Events
Updated
Components report what happens to them as events. EventType.<Source>.<Action> is the string '<Source>::<action>'; compare it with an event’s eventType. What each event carries is described on the page of the component that sends it.
on('crate', (e) => { if (e.eventType === EventType.PhysicsCollider.CollisionEnter) log('hit', e.data);});AIAgent
Section titled “AIAgent”| Constant | Value |
|---|---|
Event |
AIAgent::prompt |
Event |
AIAgent::thinking |
Event |
AIAgent::response |
Event |
AIAgent::talking |
Event |
AIAgent::writing |
Event |
AIAgent::error |
Event |
AIAgent::idle |
Event |
AIAgent::cancelled |
Event |
AIAgent::translation- |
Event |
AIAgent::translation- |
Event |
AIAgent::translation- |
Event |
AIAgent::translation- |
Event |
AIAgent::turn- |
Event |
AIAgent::turn- |
Event |
AIAgent::turn- |
Event |
AIAgent::turn- |
Event |
AIAgent::instructions- |
Event |
AIAgent::instructions- |
Event |
AIAgent::skill- |
Event |
AIAgent::tool- |
Event |
AIAgent::skill- |
Event |
AIAgent::skill- |
Event |
AIAgent::skill- |
Event |
AIAgent::tool- |
Event |
AIAgent::tool- |
Event |
AIAgent::tool- |
Event |
AIAgent::tool- |
Event |
AIAgent::tool- |
Event |
AIAgent::tool- |
Event |
AIAgent::memory- |
Event |
AIAgent::memory- |
Event |
AIAgent::memory- |
Event |
AIAgent::memory- |
Event |
AIAgent::memory- |
Event |
AIAgent::memory- |
Event |
AIAgent::context- |
AIProximity
Section titled “AIProximity”| Constant | Value |
|---|---|
Event |
AIProximity::enter |
Event |
AIProximity::exit |
AmbientLight
Section titled “AmbientLight”Sent by Ambient Light.
| Constant | Value |
|---|---|
Event |
Ambient |
AnimationClip
Section titled “AnimationClip”Sent by Animation Clip.
| Constant | Value |
|---|---|
Event |
Animation |
Event |
Animation |
Event |
Animation |
AnimationGraph
Section titled “AnimationGraph”Sent by Animation Graph.
| Constant | Value |
|---|---|
Event |
Animation |
AnimationTimeline
Section titled “AnimationTimeline”Sent by Animation Timeline.
| Constant | Value |
|---|---|
Event |
Animation |
Event |
Animation |
Event |
Animation |
Event |
Animation |
Event |
Animation |
Sent by Audio.
| Constant | Value |
|---|---|
Event |
Audio::ready |
Event |
Audio::error |
Event |
Audio::play |
Event |
Audio::pause |
Event |
Audio::stop |
Event |
Audio::end |
AudioAmbisonic
Section titled “AudioAmbisonic”Sent by Audio Ambisonic.
| Constant | Value |
|---|---|
Event |
Audio |
Event |
Audio |
Event |
Audio |
Event |
Audio |
Event |
Audio |
Event |
Audio |
AudioPositional
Section titled “AudioPositional”Sent by Audio Positional.
| Constant | Value |
|---|---|
Event |
Audio |
Event |
Audio |
Event |
Audio |
Event |
Audio |
Event |
Audio |
Event |
Audio |
AudioTone
Section titled “AudioTone”Sent by Audio Tone.
| Constant | Value |
|---|---|
Event |
Audio |
Event |
Audio |
Event |
Audio |
AudioTonePositional
Section titled “AudioTonePositional”Sent by Audio Tone Positional.
| Constant | Value |
|---|---|
Event |
Audio |
Event |
Audio |
Event |
Audio |
AudioZone
Section titled “AudioZone”Sent by Audio Zone.
| Constant | Value |
|---|---|
Event |
Audio |
Event |
Audio |
CharacterController
Section titled “CharacterController”Sent by Character Controller.
| Constant | Value |
|---|---|
Event |
Character |
Event |
Character |
Collada
Section titled “Collada”Sent by Collada.
| Constant | Value |
|---|---|
Event |
Collada::ready |
Event |
Collada::error |
DirectionalLight
Section titled “DirectionalLight”Sent by Directional Light.
| Constant | Value |
|---|---|
Event |
Directional |
Enable
Section titled “Enable”Sent by Enable.
| Constant | Value |
|---|---|
Event |
Enable::change |
| Constant | Value |
|---|---|
Event |
FBX::ready |
Event |
FBX::error |
| Constant | Value |
|---|---|
Event |
GIF::ready |
Event |
GIF::error |
Event |
GIF::play |
Event |
GIF::pause |
Event |
GIF::end |
| Constant | Value |
|---|---|
Event |
GLTF::ready |
Event |
GLTF::error |
Grabbable
Section titled “Grabbable”Sent by Grabbable.
| Constant | Value |
|---|---|
Event |
Grabbable::start |
Event |
Grabbable::end |
Event |
Grabbable::hover |
Event |
Grabbable::leave |
Handle
Section titled “Handle”Sent by Handle.
| Constant | Value |
|---|---|
Event |
Handle::start |
Event |
Handle::end |
Event |
Handle::hover |
Event |
Handle::leave |
HemisphereLight
Section titled “HemisphereLight”Sent by Hemisphere Light.
| Constant | Value |
|---|---|
Event |
Hemisphere |
Sent by Image.
| Constant | Value |
|---|---|
Event |
Image::ready |
Event |
Image::error |
KitPiece
Section titled “KitPiece”Sent by Kit Piece.
| Constant | Value |
|---|---|
Event |
Kit |
Event |
Kit |
| Constant | Value |
|---|---|
Event |
KTX2::ready |
Event |
KTX2::error |
Sent by Layer.
| Constant | Value |
|---|---|
Event |
Layer::change |
LightShadow
Section titled “LightShadow”Sent by Light Shadow.
| Constant | Value |
|---|---|
Event |
Light |
Sent by Link.
| Constant | Value |
|---|---|
Event |
Link::open |
Sent by Lock.
| Constant | Value |
|---|---|
Event |
Lock::change |
Lottie
Section titled “Lottie”Sent by Lottie.
| Constant | Value |
|---|---|
Event |
Lottie::ready |
Event |
Lottie::error |
Event |
Lottie::play |
Event |
Lottie::pause |
Event |
Lottie::end |
MediaStream
Section titled “MediaStream”Sent by Media Stream.
| Constant | Value |
|---|---|
Event |
Media |
Event |
Media |
MotionPathController
Section titled “MotionPathController”Sent by Motion Path Controller.
| Constant | Value |
|---|---|
Event |
Motion |
NavMeshAgent
Section titled “NavMeshAgent”| Constant | Value |
|---|---|
Event |
Nav |
Networkable
Section titled “Networkable”Sent by Networkable.
| Constant | Value |
|---|---|
Event |
Networkable::ownership- |
Event |
Networkable::connect |
Event |
Networkable::disconnect |
Event |
Networkable::error |
Event |
Networkable::peer- |
Event |
Networkable::peer- |
| Constant | Value |
|---|---|
Event |
OBJ::ready |
Event |
OBJ::error |
| Constant | Value |
|---|---|
Event |
PDF::ready |
Event |
PDF::error |
Event |
PDF::page |
Persistable
Section titled “Persistable”Sent by Persistable.
| Constant | Value |
|---|---|
Event |
Persistable::change |
Event |
Persistable::cleared |
Event |
Persistable::error |
PhysicsCollider
Section titled “PhysicsCollider”| Constant | Value |
|---|---|
Event |
Physics |
Event |
Physics |
Event |
Physics |
Event |
Physics |
PhysicsRigidBody
Section titled “PhysicsRigidBody”Sent by Physics Rigid Body.
| Constant | Value |
|---|---|
Event |
Physics |
Event |
Physics |
Pivotable
Section titled “Pivotable”Sent by Pivotable.
| Constant | Value |
|---|---|
Event |
Pivotable::start |
Event |
Pivotable::end |
Event |
Pivotable::hover |
Event |
Pivotable::leave |
PointLight
Section titled “PointLight”Sent by Point Light.
| Constant | Value |
|---|---|
Event |
Point |
RectAreaLight
Section titled “RectAreaLight”Sent by Rect Area Light.
| Constant | Value |
|---|---|
Event |
Rect |
ScreenGamepad
Section titled “ScreenGamepad”Sent by Screen Gamepad.
| Constant | Value |
|---|---|
Event |
Screen |
Event |
Screen |
Selectable
Section titled “Selectable”Sent by Selectable.
| Constant | Value |
|---|---|
Event |
Selectable::select |
Event |
Selectable::deselect |
Event |
Selectable::change |
Event |
Selectable::hover |
Event |
Selectable::leave |
Shadow
Section titled “Shadow”Sent by Shadow.
| Constant | Value |
|---|---|
Event |
Shadow::change |
Snappable
Section titled “Snappable”Sent by Snappable.
| Constant | Value |
|---|---|
Event |
Snappable::snap |
Event |
Snappable::unsnap |
SnapZone
Section titled “SnapZone”Sent by Snap Zone.
| Constant | Value |
|---|---|
Event |
Snap |
Event |
Snap |
Event |
Snap |
Event |
Snap |
SpawnPoint
Section titled “SpawnPoint”Sent by Spawn Point.
| Constant | Value |
|---|---|
Event |
Spawn |
SpotLight
Section titled “SpotLight”Sent by Spot Light.
| Constant | Value |
|---|---|
Event |
Spot |
SpotPoint
Section titled “SpotPoint”Sent by Spot Point.
| Constant | Value |
|---|---|
Event |
Spot |
Event |
Spot |
SteeringAgent
Section titled “SteeringAgent”Sent by Steering Agent.
| Constant | Value |
|---|---|
Event |
Steering |
| Constant | Value |
|---|---|
Event |
SVG::ready |
Event |
SVG::error |
Teleport
Section titled “Teleport”Sent by Teleport.
| Constant | Value |
|---|---|
Event |
Teleport::start |
Event |
Teleport::aim |
Event |
Teleport::arrive |
Event |
Teleport::cancel |
Event |
Teleport::end |
Transform
Section titled “Transform”Sent by Transform.
| Constant | Value |
|---|---|
Event |
Transform::position- |
Event |
Transform::rotation- |
Event |
Transform::scale- |
Event |
Transform::change |
TravelPoint
Section titled “TravelPoint”Sent by Travel Point.
| Constant | Value |
|---|---|
Event |
Travel |
Event |
Travel |
UIAvatar
Section titled “UIAvatar”| Constant | Value |
|---|---|
Event |
UIAvatar::press |
UIButton
Section titled “UIButton”| Constant | Value |
|---|---|
Event |
UIButton::press |
UICheckbox
Section titled “UICheckbox”| Constant | Value |
|---|---|
Event |
UICheckbox::change |
UIDrawing
Section titled “UIDrawing”| Constant | Value |
|---|---|
Event |
UIDrawing::pointer- |
Event |
UIDrawing::pointer- |
Event |
UIDrawing::pointer- |
Event |
UIDrawing::pointer- |
Event |
UIDrawing::pointer- |
UIImage
Section titled “UIImage”| Constant | Value |
|---|---|
Event |
UIImage::press |
Event |
UIImage::ready |
Event |
UIImage::error |
UIInput
Section titled “UIInput”| Constant | Value |
|---|---|
Event |
UIInput::change |
Event |
UIInput::submit |
Event |
UIInput::focus |
Event |
UIInput::blur |
UIKeyboard
Section titled “UIKeyboard”| Constant | Value |
|---|---|
Event |
UIKeyboard::press |
Event |
UIKeyboard::show |
Event |
UIKeyboard::hide |
UILabel
Section titled “UILabel”| Constant | Value |
|---|---|
Event |
UILabel::press |
UIList
Section titled “UIList”| Constant | Value |
|---|---|
Event |
UIList::select |
Event |
UIList::deselect |
UIListItem
Section titled “UIListItem”| Constant | Value |
|---|---|
Event |
UIList |
UIMenu
Section titled “UIMenu”| Constant | Value |
|---|---|
Event |
UIMenu::open |
Event |
UIMenu::close |
UIMenuItem
Section titled “UIMenuItem”| Constant | Value |
|---|---|
Event |
UIMenu |
UINotification
Section titled “UINotification”| Constant | Value |
|---|---|
Event |
UINotification::open |
Event |
UINotification::action |
Event |
UINotification::dismiss |
UIProgress
Section titled “UIProgress”| Constant | Value |
|---|---|
Event |
UIProgress::change |
UISlider
Section titled “UISlider”| Constant | Value |
|---|---|
Event |
UISlider::change |
Event |
UISlider::change- |
UISwitch
Section titled “UISwitch”| Constant | Value |
|---|---|
Event |
UISwitch::change |
UIToggleButton
Section titled “UIToggleButton”| Constant | Value |
|---|---|
Event |
UIToggle |
UITooltip
Section titled “UITooltip”| Constant | Value |
|---|---|
Event |
UITooltip::show |
Event |
UITooltip::hide |
UIVideo
Section titled “UIVideo”| Constant | Value |
|---|---|
Event |
UIVideo::ready |
Event |
UIVideo::error |
Event |
UIVideo::play |
Event |
UIVideo::pause |
Event |
UIVideo::stop |
Event |
UIVideo::end |
| Constant | Value |
|---|---|
Event |
USDZ::ready |
Event |
USDZ::error |
Sent by Video.
| Constant | Value |
|---|---|
Event |
Video::ready |
Event |
Video::error |
Event |
Video::play |
Event |
Video::pause |
Event |
Video::stop |
Event |
Video::end |
WaterVolume
Section titled “WaterVolume”Sent by Water Volume.
| Constant | Value |
|---|---|
Event |
Water |
Event |
Water |
Event |
Water |
Event |
Water |
XRAnchor
Section titled “XRAnchor”| Constant | Value |
|---|---|
Event |
XRAnchor::tracked |
Event |
XRAnchor::lost |
Event |
XRAnchor::restored |
XRMeshes
Section titled “XRMeshes”| Constant | Value |
|---|---|
Event |
XRMeshes::detected |
Event |
XRMeshes::updated |
Event |
XRMeshes::lost |
XROrigin
Section titled “XROrigin”| Constant | Value |
|---|---|
Event |
XROrigin::recenter |
Event |
XROrigin::reset |
XRPlanes
Section titled “XRPlanes”| Constant | Value |
|---|---|
Event |
XRPlanes::detected |
Event |
XRPlanes::updated |
Event |
XRPlanes::lost |