GetActorLoot
What a dead actor’s or animal’s body still holds for a search.
Syntax
Section titled “Syntax”GetActorLoot(id)| Parameter | Type | |
|---|---|---|
id |
number | the actor or animal |
Returns
Section titled “Returns”table | nil - a list of {class =, amount =, health =} (empty once searched bare); nil for anything but a server actor or animal
Example
Section titled “Example”-- a body searched bare goes ten seconds laterSetTimer(function() local left = GetActorLoot(deer) if left and #left == 0 then DestroyEntity(deer) endend, 10000, true)See also
Section titled “See also”SetActorLoot · OnPlayerLootActor · the NPC actors group of the index
