Skip to content

REVO / API version 0.0.10

IClientEvent

Property Type Details
disconnected (reason, message) => void —
entityEnterColshape (colshape, entity) => void Fires once when a streamed-in entity enters. Boundary points count as inside.
entityHit (victim, attacker, weaponHash, damage) => void Fires after GTA applies damage and cannot cancel it. Unknown attackers are null. Skipped if the victim is destroyed before delivery. Check valid because earlier listeners may destroy either entity.
entityLeaveColshape (colshape, entity) => void Fires after removing the entity from the shape’s member list. During Colshape.destroy(), the shape is still valid. Repeated destroy() calls have no effect. Skipped during resource shutdown. Check both objects’ valid flags after await.
entityStreamIn (entity) => void Fires when an entity is created in or removed from GTA. Runs synchronously while the entity is registered. After await, check valid again.
entityStreamOut (entity) => void —
keyDown (key, modifiers) => void —
keyUp (key, modifiers) => void —
mouseButton (button, released, x, y, modifiers) => void —
mouseMove (x, y, modifiers, leave) => void —
mouseWheel (delta, x, y, modifiers) => void —
networkEntityReadyChanged (entity, ready) => void On replica removal, ready is false and entity.valid may already be false.
playerDespawned () => void —
playerDimensionChanged (oldDimension, newDimension) => void Fires after Player.local.dimension changes, including spawn and reset to 0 on disconnect.
playerDodge (attacker) => void attacker is null if it is unknown or no longer registered.
playerSpawned () => void Fired after each server spawn of the local player.
playerTalkingStarted (player) => void Once per streamed-in speaker across all voice channels, including self. Also fires when an already-talking player streams in.
playerTalkingStopped (player) => void Fires when speech stops or the player streams out. The player is still valid during the callback. Phone and radio playback can continue outside streaming range. Use voice.isPlayerTalking(networkId) and getPlayerLevel(networkId) for distant speakers.
syncedMetaChange (object, key, newValue, oldValue) => void Fires for initial metadata and updates. Missing old or new values are undefined.
weaponAimStarted () => void —
weaponAimStopped () => void —
weaponChange (oldWeapon, newWeapon) => void —
weaponFired (weaponHash) => void —
weaponReloadStarted (weaponHash) => void —
windowFocus (focused) => void —

Events and listeners