Neiv
09-21-2008, 04:21 PM
I am setting out bots that provide full heals to those who donate plat. I'm using Angelox's buff bot script, which I've modified to include healing only. The script includes a spawn event that sets a proximity. The script triggered by the ENTER event is as follows:
sub EVENT_ENTER
{
$npc->SetAppearance(1);
quest::say("Healer available. I'm inside the gate, near the causeway to the wall.");
}
I would like to make this script trigger only when a player enters the proximity whose health is below, say, 70%. The HP events and functions seem only to apply to npcs and mobs, not players. Nor could I find a quest object that would accomplish this. Is there a variable that would return my current HP in percentage to allow me to do this? Thanks.
sub EVENT_ENTER
{
$npc->SetAppearance(1);
quest::say("Healer available. I'm inside the gate, near the causeway to the wall.");
}
I would like to make this script trigger only when a player enters the proximity whose health is below, say, 70%. The HP events and functions seem only to apply to npcs and mobs, not players. Nor could I find a quest object that would accomplish this. Is there a variable that would return my current HP in percentage to allow me to do this? Thanks.