No categories assigned
LUA:IsEntity
- Last edited 6 years ago by I need to Update My Profile
LUA - IsEntity
Return to: LUA | Tutorials | Portal | Forum | Project Manager | Bug Tracker
LUA Functions: IsEntity()
Checks to see if the given spawn is an entity
Syntax
IsEntity(param1)
Parameters
- Required - param1 (Spawn)
- param1 is the spawn we want to check
Usage
function AttackTarget(NPC, Target)
if IsEntity(Target) then
Attack(NPC, Target)
end
end
When this function is called it will verify the target is an entity then attack it if it is
Notes
Only Entities can engage in combat
NPC, Player, Pet, Bot, Merc are all entities