Skip to content

REVO / API version 0.0.10

Entity

Only this resource’s local entities can be modified, except pos, heading and setPlayerControl on Player.local. Transforms, streaming settings and LocalPed appearance can be set before stream-in. Other writes require isStreamedIn. After destruction, networkId is null and isNetworked/ready/isStreamedIn are false.

Property Type Details
dimension
readonly
number World ID, default 0. Writable on local objects created by this resource. The server controls other objects. globalDimension makes the object visible in every numbered world.

Inherited from Streamable.dimension
heading number Heading in radians.
id
readonly
number Local ID, assigned independently on the client and server.

Implements IEntity.id

Inherited from Streamable.id
isLocallySimulated
readonly
boolean Simulation authority does not grant permission to change server-owned state.
isNetworked
readonly
boolean —
isStreamedIn
readonly
boolean Inherited from Streamable.isStreamedIn
netOwner
readonly
Player | null —
networkId
readonly
number | null Server-assigned network ID, or null without replication. Separate from id.
ready
readonly
boolean The initial server state has been applied, or a client-only entity has streamed in.
scriptID
readonly
number GTA handle, or 0 while not streamed in. Do not retain it across frames.
streamDistance number | null Per-object distance in metres. null uses the streamer’s default.

Inherited from Streamable.streamDistance
streamingEnabled boolean Enables automatic streaming. Disabling it preserves the current streaming state. A dimension mismatch still suspends it until its dimension is visible again.

Inherited from Streamable.streamingEnabled
type
readonly
BaseType Inherited from Streamable.type
valid
readonly
boolean Inherited from Streamable.valid
all
static readonly
readonly Entity[] Overrides Streamable.all
count
static readonly
number Overrides Streamable.count
Accessor Type Details
modelHash
readonly
number Implements IEntity.modelHash
pos Read: Vector3
Write: IVector3
Implements IEntity.pos

Inherited from Streamable.pos
quaternion Read: Quaternion
Write: IQuaternion
Inherited from Streamable.quaternion
rot Read: Vector3
Write: IVector3
Euler angles in radians, applied X, then Y, then Z.

Inherited from Streamable.rot

destroy(): void

Deletes an entity created by this resource. Throws if the entity is networked, belongs to another resource, has been destroyed, or cannot be removed from GTA.

void


getSyncedMeta<K>(key): ICustomBaseSyncedMeta[K] | undefined

Returns a copy. Client-only objects have no synced metadata.

Type Parameter
K extends never
Parameter Type
key K

ICustomBaseSyncedMeta[K] | undefined

Streamable.getSyncedMeta

getSyncedMeta<T>(key): T | undefined

Returns a copy. Client-only objects have no synced metadata.

Type Parameter Default type
T TransportValue
Parameter Type
key string

T | undefined

Streamable.getSyncedMeta


getSyncedMetaKeys(): string[]

string[]

Streamable.getSyncedMetaKeys


hasSyncedMeta(key): boolean

Parameter Type
key string

boolean

Streamable.hasSyncedMeta


static getById(id): Entity | null

Parameter Type
id number

Entity | null

Streamable.getById


static getByNetworkId(networkId): Entity | null

Parameter Type
networkId number

Entity | null


static getByScriptId(scriptID): Entity | null

Parameter Type
scriptID number

Entity | null