Yes, the actual numbers for the items are not 0000, those were just placeholders when I began thinking of this script at work today. I have decided to axe the plugin and do it manually and it works perfectly, only I still have the explicit right versus left wrists to tackle. Finally, I need to get it working as a loop to have the ill effects count the number of correct/missing items of the 8.
This works as intended for checking all 8 visible armor items:
Code:
sub EVENT_SPAWN {
$npc->TempName("");
quest::settimer("armor", 30);
}
sub EVENT_TIMER {
if ($timer eq "armor") {
my @clientlist = $entity_list->GetClientList();
foreach $ent (@clientlist) {
if ($ent->GetItemIDAt(2) == 2298 && $ent->GetItemIDAt(7) == 2372 && $ent->GetItemIDAt(9) == 2376 && $ent->GetItemIDAt(10) == 31891 && $ent->GetItemIDAt(12) == 2377 && $ent->GetItemIDAt(17) == 2370 && $ent->GetItemIDAt(18) == 2378 && $ent->GetItemIDAt(19) == 2379) {
$ent->Message(315, "Your armor protects you from harm.");
}
else {
$ent->CastSpell(7026,$ent->GetID()); #casts Aura of Crimson Mists IV
quest::ze(4, $ent->GetCleanName() . " suffers in the throes of anguish.");
}
}
}
}
Hint: the item numbers are unique to my server, who knows what they are on other servers.