A world object — the game's third entity type, covering everything that isn't a ped or a vehicle: crates, cones, ATMs, dropped items, placeable scenery.
Named Prop rather than Object to stay clear of Object in Haxe's own
namespace and of the fivem.client.natives.Object extern.
var cone = Prop.create("prop_roadcone02a", position, false);
cone.placeOnGround();
Local props (the default) exist on this client only and are much cheaper — the right choice for decoration. Spawn networked props only when other players genuinely need to see and interact with them.
Static methods
staticcreate(model:Hash, position:Vector3, networked:Bool = false, placeOnGround:Bool = false):Prop
Spawns a prop, streaming its model in first. Returns null if the
model is invalid or failed to load.
Parameters:
networked | Whether other players can see it. |
|---|---|
placeOnGround | Whether to snap it onto the surface below. |
staticcreateNoOffset(model:Hash, position:Vector3, networked:Bool = false):Prop
Spawns a prop with its origin exactly at position, skipping the
game's automatic model-offset correction.
Use this when placing props from saved coordinates — the offset applied
by create is what makes a re-loaded object drift from where it was
saved.
Constructor
Methods
inlineplaceOnGround():Bool
Drops the prop so it rests correctly on whatever is beneath it, instead of floating or intersecting the ground.