đŸ“ĻObjects

Built in object creation/rendering system allowing you to Register/Remove/Edit objects quickly and easily without un-needed code in your scripts

Register

Core.Objects.Register("myObjectIdentifier", {
  Type       = "ped",           --## "ped", "object", "vehicle"
  Model      = "a_m_beachman",  --## Model Name
  Hash       = -12393292,       --## OPTIONAL : Use hash instead? 
  Pos        = vector4(0,0,0,0),
  RenderDist = 50.0,   
  Network    = true,            --## OPTIONAL: Can be networked, dont give all peds a networked ped to spawn
}, function(ret, data) --## data = {entity:thisEntity}
  if ret == "despawn" then 
    --## Triggers on despawn, when leaving render dist
  elseif ret == "spawn" then 
    --## Triggers when spawned 
  end
end)

Remove

Will delete this ped and also stop it from being spawned within range

Core.Objects.Remove("myObjectidentifier") 

Last updated