laytya / LazyScript

22 stars 12 forks source link

Healing in Party/Raid? #10

Open Lemonadez opened 1 year ago

Lemonadez commented 1 year ago

Is there an example for healing a party?

like shield-ifNotHasBuffParty=shield heal-ifPartyAlive-ifParty<50%hp-ifInRange=heal

right now im doing heal-ifPlayer<50%hp heal-ifParty1<50%hp heal-ifParty2<50%hp heal-ifParty3<50%hp heal-ifParty4<50%hp

laytya commented 1 year ago

there is no PARTY target so u r doing right. Tell me what do u try to make. Ill try help

Lemonadez commented 1 year ago

Im trying to make it easier for healing. instead of doing party1 / party2.

would it be better example in lua

   for i = 1,4 GetNumPartyMembers() do
     nextPlayer = "party" .. i;
for i = 1, GetNumPartyMembers() do
   nextPlayer = "party" .. i;
   if (UnitHealth(nextPlayer)/UnitHealthMax(nextPlayer) <= .25) 
   then
      TargetUnit(nextPlayer)
      CastSpellByName("Flash Heal");
   end
end