📄️ ObjectHandle
An ObjectHandle is a script's reference to a networked object in the world: a player's character, a vehicle, a mounted gun, a rigid object, an NPC, a tether or a sandstorm. Every typed handle (PlayerObjectHandle, VehicleHandle, MountedGunHandle, RigidObjectHandle, NPCHandle, TetherHandle, SandstormHandle) is also an ObjectHandle, so every method on this page works on all of them.
📄️ Player
Every connected player is represented by two different handles. A PlayerHandle is the player's connection the networked object that has a position, health, a skin, weapons and animations. Use this page to know which one you have, how to get one from the other, and what each can do.
📄️ Players
The player functions of the World table that exist on both sides: all players and a random player. For what you can do with the handles these functions return, see Player, which also explains the difference between a PlayerHandle (the connection) and a PlayerObjectHandle (the character).
📄️ VehicleHandle
A VehicleHandle refers to a networked vehicleGetVehicle(), or by casting an ObjectHandle with AsVehicle().
📄️ MountedGunHandle
A MountedGunHandle refers to a networked mounted gun: a stationary turret (machine gun, mortar, rocket launcher, ...) that players can operate. You get one from World.SpawnMountedGun, or by casting an ObjectHandle with AsMountedGun().
📄️ RigidObjectHandle
A RigidObjectHandle refers to a networked physics prop built from a model file and a physics (collision) file: barrels, crates, rocks and any other loose object. You get one from World.SpawnRigidObject on the server, or by casting an ObjectHandle with AsRigidObject().
📄️ NPCHandle
An NPCHandle refers to a networked non-player character: a soldier, civilian or animal driven by script orders. You get one from World.SpawnNPC, or by casting an ObjectHandle with AsNPC().
📄️ TetherHandle
A TetherHandle refers to a networked tether
📄️ SandstormHandle
A SandstormHandle refers to a networked sandstorm: a box-shaped volume of blowing sand with a wall of sand on its front face, which gives anyone inside it the sandstorm look (sky, light and fog). You get one from World.SpawnSandstorm, or by casting an ObjectHandle with AsSandstorm().