No categories assigned
LUA:GetPet
- Last edited 12 years ago by I need to Update My Profile
LUA Functions: GetPet()
Gets the combat pet for the given spawn
Syntax
var = GetPet(param1)
Parameters
- Required - param1 (Spawn)
- param1 is the spawn who's pet we want to get
Usage
function hailed(NPC, Spawn)
local pet = GetPet(Spawn)
if pet ~= nil then
Say(NPC, "Your pets name is: " .. GetName(pet))
end
end
The NPC will respond with the name of the players pet if they have one
Notes
Returns a spawn