EventMap
Defined in: client/api.d.ts:572
Native events dispatched through Events.on. Each property is the exact callback argument tuple for that event.
Properties
Section titled “Properties”abilityStatus
Section titled “abilityStatus”
readonlyabilityStatus: [AbilityHandle]
Defined in: client/api.d.ts:631
A local ability handle started or settled. handle.status is never “requested” here.
anchorReleased
Section titled “anchorReleased”
readonlyanchorReleased: [string,Vec3]
Defined in: client/api.d.ts:641
The local player’s anchor ended. reason is “script”, “death”, “kneel”, “mount”, “teleport”, “hold”, “travel” or “pawn”; at is the floor-level point they were anchored at. Raised the frame after.
blueprintEvent
Section titled “blueprintEvent”
readonlyblueprintEvent: [number,string,Record<string,string|number|boolean| {x:number;y:number;z:number; }>]
Defined in: client/api.d.ts:741
The engine dispatched a function Blueprints.watch() named on a spawned Blueprint. params holds its parameters by name, read after the call.
breakableState
Section titled “breakableState”
readonlybreakableState: [number,"broken"|"repaired",string]
Defined in: client/api.d.ts:586
The local player broke or repaired a repairable world object. Raised after Breakables.arm().
brewingInput
Section titled “brewingInput”
readonlybrewingInput: [string]
Defined in: client/api.d.ts:591
The local player began, collected or destroyed a potion at a cauldron. The argument is JSON text to parse: { action: "begin" | "collect" | "destroy", siteUid, stationUid, potionId, yield }.
browserConsoleMessage
Section titled “browserConsoleMessage”browserConsoleMessage: [
BrowserConsoleMessageEvent]
Defined in: client/api.d.ts:826
Dispatched for console output of an owned view; the framework logs these regardless.
browserCreated
Section titled “browserCreated”browserCreated: [
BrowserCreatedEvent]
Defined in: client/api.d.ts:776
Dispatched once per view, before any navigation, to the resource that created it.
browserCursorChange
Section titled “browserCursorChange”browserCursorChange: [
BrowserCursorChangeEvent]
Defined in: client/api.d.ts:806
Dispatched when an owned view’s requested cursor shape changes.
browserDocumentReady
Section titled “browserDocumentReady”browserDocumentReady: [
BrowserDocumentReadyEvent]
Defined in: client/api.d.ts:786
Dispatched when an owned view’s main document is ready; the earliest point at which the page can receive Web.emit.
browserInputFocusChange
Section titled “browserInputFocusChange”browserInputFocusChange: [
BrowserInputFocusChangeEvent]
Defined in: client/api.d.ts:816
Dispatched when focus enters or leaves an editable element of an owned view; use it to stop routing keys to the game.
browserLoadingFailed
Section titled “browserLoadingFailed”browserLoadingFailed: [
BrowserLoadingFailedEvent]
Defined in: client/api.d.ts:791
Dispatched when a frame of an owned view fails to load.
browserLoadingStart
Section titled “browserLoadingStart”browserLoadingStart: [
BrowserLoadingStartEvent]
Defined in: client/api.d.ts:781
Dispatched when any frame of an owned view begins loading.
browserNavigate
Section titled “browserNavigate”browserNavigate: [
BrowserNavigateEvent]
Defined in: client/api.d.ts:796
Dispatched for every navigation an owned view is asked to perform, refused or not.
browserOriginChange
Section titled “browserOriginChange”browserOriginChange: [
BrowserOriginChangeEvent]
Defined in: client/api.d.ts:831
Dispatched on view creation and whenever Web.loadURL re-locks an owned view to a different origin.
browserPopup
Section titled “browserPopup”browserPopup: [
BrowserPopupEvent]
Defined in: client/api.d.ts:801
Dispatched when an owned view blocks a popup; windowless views cannot host one, so handle the URL yourself.
browserResourceBlocked
Section titled “browserResourceBlocked”browserResourceBlocked: [
BrowserResourceBlockedEvent]
Defined in: client/api.d.ts:821
Dispatched when an owned view rejects a navigation or a page event from outside its locked origin.
browserTooltip
Section titled “browserTooltip”browserTooltip: [
BrowserTooltipEvent]
Defined in: client/api.d.ts:811
Dispatched when an owned view requests a tooltip; windowless rendering draws none, so the script must.
chatMessage
Section titled “chatMessage”chatMessage: [
object]
Defined in: client/api.d.ts:836
Dispatched for every chat line the server sends. An empty author is a notice line; color is packed 0xRRGGBBAA, 0 for the chat box’s default.
chatSend
Section titled “chatSend”chatSend: [
string]
Defined in: client/api.d.ts:841
Dispatched synchronously for a line the player typed into the chat box, before it is sent. A handler returning false, not a Promise of it, blocks it; Chat.send does not raise this.
creatorChanged
Section titled “creatorChanged”
readonlycreatorChanged: [CreatorState&object]
Defined in: client/api.d.ts:616
The creator’s state changed during a session. change says which selection caused it and whether it applied, when one did.
damageReceived
Section titled “damageReceived”
readonlydamageReceived: [number,string,number,boolean,string,boolean]
Defined in: client/api.d.ts:596
An NPC or the local player took damage. Raised after CombatEvents.arm(). Class names are empty for an actor that is gone; targetNpcId is 0 unless the target is a replicated NPC.
dialogueMuted
Section titled “dialogueMuted”
readonlydialogueMuted: [DialogueLine]
Defined in: client/api.d.ts:576
The server’s Audio.setDialoguePolicy kept one of the game’s own spoken lines from starting on this client. Raised on the next frame, for a script to play a replacement in its place.
entityStateChange
Section titled “entityStateChange”entityStateChange: [
Entity,string,any,any]
Defined in: client/api.d.ts:771
Dispatched when one key of an entity’s state changes: on the server when a script writes it, on a client when the write arrives. value is undefined when the key was removed and previous is undefined when it held nothing before, so a stored null stays distinguishable from an absent key. The entity is whatever the game’s WrapScriptEntity answers, and the base Entity handle by default.
fieldGuideChallengeChanged
Section titled “fieldGuideChallengeChanged”
readonlyfieldGuideChallengeChanged: [FieldGuideChallenge]
Defined in: client/api.d.ts:736
A challenge record changed: progress, a finished tier or a claimed reward. At most once per record per frame; not raised by a restore or a save load.
fieldGuideCollectionChanged
Section titled “fieldGuideCollectionChanged”
readonlyfieldGuideCollectionChanged: [FieldGuideCollectionItem]
Defined in: client/api.d.ts:731
The game wrote a collection item’s state: a page collected, a trait learned, a beast seen. Not raised by a restore or a save load.
gameEvent
Section titled “gameEvent”
readonlygameEvent: [string,string]
Defined in: client/api.d.ts:611
A native function a script asked to watch ran, such as through Races.watchEvents or Brewing.watchNative. objectClass is empty for an object that is gone.
herbInput
Section titled “herbInput”
readonlyherbInput: [string]
Defined in: client/api.d.ts:621
The local player planted, fertilized, harvested or destroyed at a herb plot. The argument is JSON text to parse: { action: "plant" | "fertilize" | "harvest" | "destroy", plotUid, plantId, fertilizerId, state }, where state is the plot’s growth state after the action.
incantation
Section titled “incantation”
readonlyincantation: [object]
Defined in: client/api.d.ts:756
The local player said an incantation. The client raises it only for resources whose Speech.listen list holds the id, at most a few times a second, and gives only the id: no audio, text or score. Forwarded with Events.emitServer it is the client’s claim, which the server must check.
localDowned
Section titled “localDowned”
readonlylocalDowned: []
Defined in: client/api.d.ts:636
The local player went down. The client twin of the server’s playerDowned, for presentation.
localDownedEnd
Section titled “localDownedEnd”
readonlylocalDownedEnd: [object]
Defined in: client/api.d.ts:651
Deprecated
Section titled “Deprecated”Raised alongside localDownedEnded with the same arguments; listen to that instead.
localDownedEnded
Section titled “localDownedEnded”
readonlylocalDownedEnded: [object]
Defined in: client/api.d.ts:646
The local player got back up; wasDead when it was a respawn after death.
localSpellCast
Section titled “localSpellCast”
readonlylocalSpellCast: [string]
Defined in: client/api.d.ts:681
The local player cast a spell; spellPath is its spell record, or a server-defined spell’s id.
localSpellStopped
Section titled “localSpellStopped”
readonlylocalSpellStopped: [string]
Defined in: client/api.d.ts:691
A toggle spell the local player cast went off: Lumos’s light or Disillusionment’s charm, ended by a recast or anything else. spellPath is what its localSpellCast reported.
mailRead
Section titled “mailRead”
readonlymailRead: [string,string]
Defined in: client/api.d.ts:656
The player read an owl post letter, theirs or the game’s. sender is the sender id, not the display name. Not raised for a letter that loads, restores or is composed already read.
mapCaptured
Section titled “mapCaptured”
readonlymapCaptured: [MapCaptureResult]
Defined in: client/api.d.ts:751
A MapCapture.capture finished, written or failed. One capture runs at a time, across every resource.
minimapChanged
Section titled “minimapChanged”
readonlyminimapChanged: [MinimapState,MinimapState]
Defined in: client/api.d.ts:721
The minimap switched map, Hogwarts floor or tile. Read Minimap.state() at start for the state before the first change.
objectInteracted
Section titled “objectInteracted”
readonlyobjectInteracted: [ObjectInteraction]
Defined in: client/api.d.ts:746
The local player pressed F on one of the game’s own interactables that hears the press as InteractionInitiated: chests, doors, locks, notices, portkeys and the like. Raised as the object is told, before it reacts, and whether or not it then does anything. An interactable that takes F another way raises nothing, and neither does a prop of the interactables resource.
playerRegionChanged
Section titled “playerRegionChanged”
readonlyplayerRegionChanged: [string]
Defined in: client/api.d.ts:626
The local player entered a named region of the game’s map. Empty regions and repeats of the current one are dropped.
pvpRelationChanged
Section titled “pvpRelationChanged”
readonlypvpRelationChanged: [PvpRelationChange]
Defined in: client/api.d.ts:661
This client resolved its relation to another player for the first time, or the relation changed. Nothing is raised when the player streams out.
raceEnd
Section titled “raceEnd”
readonlyraceEnd: [string,boolean,boolean,RaceTimer]
Defined in: client/api.d.ts:676
Deprecated
Section titled “Deprecated”Raised alongside raceEnded with the same arguments; listen to that instead.
raceEnded
Section titled “raceEnded”
readonlyraceEnded: [string,boolean,boolean,RaceTimer]
Defined in: client/api.d.ts:671
A race the local player started ended, once per run. finished once they got past its last ring; false when it was abandoned, by the game or Races.abandon. newBest is the game’s own verdict on timer.total, time trials only.
raceGate
Section titled “raceGate”
readonlyraceGate: [string,number,boolean,RaceTimer]
Defined in: client/api.d.ts:666
The local player flew through (hit) or past a ring of the race they are running. gate is the ring’s index, from 0; the last is the finish. timer is read once the game counted the ring, so a miss’s penalty is in it.
resourceStart
Section titled “resourceStart”resourceStart: [
string]
Defined in: client/api.d.ts:761
Dispatched after a resource entry point has run and immediately before the resource becomes running.
resourceStop
Section titled “resourceStop”resourceStop: [
string]
Defined in: client/api.d.ts:766
Dispatched while a resource is stopping, before its stop callback, timers, exports and event handlers are cleaned up.
spellAssignment
Section titled “spellAssignment”
readonlyspellAssignment: [SpellAssignment]
Defined in: client/api.d.ts:701
A spell was assigned to a slot of the spell diamond. One event covers a group of native writes, such as both halves of a drag-and-swap; read the loadout again to see the result.
spellCast
Section titled “spellCast”
readonlyspellCast: [string]
Defined in: client/api.d.ts:686
Deprecated
Section titled “Deprecated”Raised alongside localSpellCast with the same arguments; listen to that instead.
spellCooldownChanged
Section titled “spellCooldownChanged”
readonlyspellCooldownChanged: [string,SpellCooldown|null]
Defined in: client/api.d.ts:711
One of the local player’s spells went on cooldown, came off it (null), or moved other than by counting down: a reduction, a pause, or a change of drain rate entering or leaving combat. A countdown kept from the last event stays within a quarter second of the game’s own. Read Spells.cooldowns() at start for the cooldowns already running.
spellHit
Section titled “spellHit”
readonlyspellHit: [string,string,string,number,boolean,string,boolean]
Defined in: client/api.d.ts:601
A spell hit an actor. Raised after CombatEvents.arm(), except a hit on the local player, which is always raised and has an empty spellType.
spellHitPlayer
Section titled “spellHitPlayer”
readonlyspellHitPlayer: [number,number,string,number,BodyPart|null]
Defined in: client/api.d.ts:606
A spell of the local player hit another player, and the hit was relayed to the server. bodyPart is where it struck, as this client’s copy of their body read it. Informational; the server arbitrates it.
spellLearningFinished
Section titled “spellLearningFinished”
readonlyspellLearningFinished: [SpellLearningResult]
Defined in: client/api.d.ts:716
Native lesson result for the requesting resource; no spell is granted.
spellLoadoutChanged
Section titled “spellLoadoutChanged”
readonlyspellLoadoutChanged: [number,number]
Defined in: client/api.d.ts:706
The player switched spell sets (0-3), by F1-F4, the mouse wheel, a controller or anything else that moves the game’s active set. Read Spells.currentLoadout() at start for the set already selected.
spellStopped
Section titled “spellStopped”
readonlyspellStopped: [string]
Defined in: client/api.d.ts:696
Deprecated
Section titled “Deprecated”Raised alongside localSpellStopped with the same arguments; listen to that instead.
voiceStart
Section titled “voiceStart”voiceStart: []
Defined in: client/api.d.ts:846
Dispatched when the local player starts speaking, as isTalking turns true.
voiceStop
Section titled “voiceStop”voiceStop: []
Defined in: client/api.d.ts:851
Dispatched when the local player stops speaking, as isTalking turns false.
waypointChanged
Section titled “waypointChanged”
readonlywaypointChanged: [Waypoint|null,Waypoint|null]
Defined in: client/api.d.ts:581
The local player placed, moved or removed their map waypoint. Read Blips.waypoint() at start for the waypoint before the first change.
worldLootRequest
Section titled “worldLootRequest”
readonlyworldLootRequest: [WorldLootInfo]
Defined in: client/api.d.ts:726
Asks whether this client may collect one of the game’s own loot actors; a handler returning false refuses it. Refused loot offers no prompt, the interact button does nothing on it, and a refused moonstone breaks without paying out. Raised once per loot actor as it loads or offers its prompt, the frame after (a moonstone when it breaks, so its payout lands a frame later); the answer holds until WorldLoot.refresh(). Not raised for the moonstones and foragables World.setLootPolicy takes off every client (they are refused and hidden) or for the server’s own Lootables.