is NPC spawned
Hola,
Is there a way to check if an NPC is spawned before doing something? Something like: Code:
if (defined $qglobals{"MjarakIsDead"}){ |
Found EntityVariableExists() under the mob-> commands,
Tried the following with no luck. Code:
if (defined $qglobals{"MjarakIsDead"}){ ###Mjarak 2 min warning |
Quote:
if ($mjarak) |
Quote:
Tadah! if ($mjarak) { works, Thanks Jolig! |
EntityList::IsMobSpawnedByNpcTypeID() should work with both lua and Perl. (I'm not sure the exact syntax though :P)
|
Quote:
Code:
my $mjarak = $entity_list->GetMobByNpcTypeID(4770039); |
Quote:
|
Quote:
Also, you said in code but not in the quest system, what exactly do you mean by that, it wouldn't be handled in a perl for example? |
Quote:
Because code, in other words. |
I see.
The entity variables I'm using won't last long, only 2 minutes. Using it for a lockout system, if someone zones in and the mob is up it's going to despawn it w/in 2 minutes unless the player leaves the zone. If I'm only using the variables for a relatively short amount of time, should I really be worried about them being buggy? Sidenote, anyone know of a way to return the time remaining on a qglobal to players? |
All times are GMT -4. The time now is 07:23 AM. |
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.