Skip to content

REVO / API version 0.0.10

Object

Collections include LocalObject instances.

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 Physical.dimension
dynamic
readonly
boolean —
heading number Heading in radians.

Inherited from Physical.heading
health number Inherited from Physical.health
id
readonly
number Local ID, assigned independently on the client and server.

Inherited from Physical.id
isLocallySimulated
readonly
boolean Simulation authority does not grant permission to change server-owned state.

Inherited from Physical.isLocallySimulated
isNetworked
readonly
boolean Inherited from Physical.isNetworked
isStreamedIn
readonly
boolean Inherited from Physical.isStreamedIn
maxHealth number Inherited from Physical.maxHealth
netOwner
readonly
Player | null Inherited from Physical.netOwner
networkId
readonly
number | null Server-assigned network ID, or null without replication. Separate from id.

Inherited from Physical.networkId
physicsAsleep
readonly
boolean —
ready
readonly
boolean The initial server state has been applied, or a client-only entity has streamed in.

Inherited from Physical.ready
scriptID
readonly
number GTA handle, or 0 while not streamed in. Do not retain it across frames.

Inherited from Physical.scriptID
streamDistance number | null Per-object distance in metres. null uses the streamer’s default.

Inherited from Physical.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 Physical.streamingEnabled
type
readonly
BaseType Inherited from Physical.type
valid
readonly
boolean Inherited from Physical.valid
all
static readonly
readonly Object[] Overrides Physical.all
count
static readonly
number Overrides Physical.count
Accessor Type Details
angVelocity Read: Vector3
Write: IVector3
Angular velocity in radians per second.

Inherited from Physical.angVelocity
modelHash
readonly
number Inherited from Physical.modelHash
pos Read: Vector3
Write: IVector3
Inherited from Physical.pos
quaternion Read: Quaternion
Write: IQuaternion
Inherited from Physical.quaternion
rot Read: Vector3
Write: IVector3
Euler angles in radians, applied X, then Y, then Z.

Inherited from Physical.rot
velocity Read: Vector3
Write: IVector3
Inherited from Physical.velocity

activatePhysics(): void

void

Physical.activatePhysics


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

Physical.destroy


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

Physical.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

Physical.getSyncedMeta


getSyncedMetaKeys(): string[]

string[]

Physical.getSyncedMetaKeys


hasSyncedMeta(key): boolean

Parameter Type
key string

boolean

Physical.hasSyncedMeta


setAppearance(alpha, textureVariation, lodDistance): void

Parameter Type Description
alpha number Integer in [0, 255].
textureVariation number Integer in [0, 255].
lodDistance number Integer in [-1, 65535]. -1 restores the model default.

void


static getById(id): Object | null

Parameter Type
id number

Object | null

Physical.getById


static getByNetworkId(networkId): Object | null

Parameter Type
networkId number

Object | null

Physical.getByNetworkId


static getByScriptId(scriptID): Object | null

Parameter Type
scriptID number

Object | null

Physical.getByScriptId