setPedStayInSamePlace
Persists GTA's scalar stay-in-place flag on a script ped without assigning a stand-still task.
Syntax
bool setPedStayInSamePlace(ped thePed, bool stayInSamePlace)GTA task mapping
0350 SCM equivalent: SET_CHAR_STAY_IN_SAME_PLACE
This does not create a CTask. It writes GTA's scalar bStayInSamePlace ped flag through CPed::SetStayInSamePlace.
Arguments
thePedpedScript ped only; players are rejected.
stayInSamePlaceboolDesired local native flag.
Returns
true when the client-local policy was stored; false for a player or invalid element.
Ownership and lifecycle
Low-level ped task calls require the client that simulates the living, streamed ped. Driving tasks also require control of the streamed vehicle. They do not create lifecycle handles; the optional native-task-runtime adds server-owned route epochs and reconstruction for drive_to routes. Gang-tag ownership is resource-exclusive, survives object streaming and recreation, and is released automatically when the owner stops.
- The explicit value survives stream-out and native recreation.
- This is a client-local last-writer-wins policy, not a resource lease or movement task.
Where this comes from
Continue exploring
← Back to the Neon Lua API · How Native ped tasks and gang tags works →