Get All NPCs by NPCTypeID
Hilariously stupid quest, maybe I'm just hungry.
Is there any easy way to pull all the NPCs by npc_type id? I thought the below bit would work, but it seems to only pull one. I have 11 of npc_type id 12345 in the zone, but it seems to only select one of them. Code:
my @creatures = $entity_list->GetNPCByNPCTypeID(12345); Pre-emptive thank you! -Hate |
It is returning once it finds the first one. So it is working as intended.
entity.cpp line 856 Code:
NPC *EntityList::GetNPCByNPCTypeID(uint32 npc_id) |
As much as I hate signals, that is the only thing that would work here
Code:
quest::signal(npc_id, wait=0 ) # cause an EVENT_SIGNAL on all mobs in the zone with this NPC type, with $signalid = 0. wait is an optional time to wait in ms before sending signal. |
Can do it via signals or very simply:
Code:
my @nlist $entity_list->GetNPCList(); |
All times are GMT -4. The time now is 03:06 AM. |
Powered by vBulletin®, Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.