moguay wrote:Capture the moment to make a heal, not required an array.
You need to check quickly all the group and extract only the priority.
For exemple you can classify by hp and cast it by priority if found
Below just a draft code :Code: Select all
/varset lower70 int local 70
/varset lower70toon string local
/varset lower50 int local 50
/varset lower70toon string local
/for x 0 to ${Group.Members}
if ${Group.Member[x].PctHPs} > 50 && ${Group.Member[x].PctHPs} < ${lower90}) {
/varset lower70 ${Group.Member[x].PctHPs}
/varset lower70toon ${Group.Member[x]}
}
if ${Group.Member[x].PctHPs} < ${lower50}) {
/varset lower50 ${Group.Member[x].PctHPs}
/varset lower50toon ${Group.Member[x]}
}
/next x
/if (${Spawn[pc ${lower50toon}].ID}) { casting 50hp... }
/if ({Spawn[pc ${lower70toon}].ID}) { casting 70hp... }
Code: Select all
/if ( ${Group.Member[0].PctHPs}<=75 && ${Group.Member[1].PctHPs}<=75 && ${Group.Member[2].PctHPs}<=75 && ${Group.Member[3].PctHPs}<=75 && ${Group.Member[4].PctHPs}<=75 && ${Group.Member[5].PctHPs}<=75 ) {
/casting "5270" -maxtries|5
} else {
/echo returning to main
/delay 1
}
/return
Code: Select all
:Next2
/if ( ${Group.Member[2].PctHPs}<=80 && ${Group.Member[2].PctHPs}>=70 ) {
/target ${Group.Member[2]}
/delay 50
/gsay Tossing a hot on ${Target.CleanName}
/casting "Pious Elixir" -maxtries|5
/delay 5s
/casting "Harmony of Spirit III" -maxtries|5
/delay 3s
} else /if (${Group.Member[2].PctHPs}<=65) {
/target ${Group.Member[2]}
/delay 50
/gsay quickie heal and big heal incoming for ${Target.CleanName}
/casting "Pious Remedy" -maxtries|3
/delay 3s
/casting "9190" -maxtries|3
/delay 5s
} else {
/delay 3
/goto :Next3
Code: Select all
Sub AutoGroupHeal
| For Group Heal
/declare autogrouppct int local 70
/declare autogroupcount int local 2
/declare count int local 0
/declare count70 int local 0
/declare count100 int local 0
/declare countquick int local 0
| For Single Target Heal
/declare lower70 int local 70
/declare lower70toon string local
/declare lower50 int local 50
/declare lower70toon string local
/for x 0 to ${Group.Members}
/if (${Group.Member[${x}].PctHPs}<=${autogrouppct} && ${Group.Member[${x}].ID}!=NULL && ${Spawn[pc =${Group.Member[${x}].CleanName}].ID}!=NULL && ${Spawn[pc =${Group.Member[${x}].CleanName}].Distance}<=300) {
/if (${Spawn[pc =${Group.Member[${x}].CleanName}].Distance}<=70) /varcalc count70 ${count70}+1
/if (${Spawn[pc =${Group.Member[${x}].CleanName}].Distance}<=100) /varcalc count100 ${count100}+1
/if (${Group.Member[${x}].PctHPs}<=61) /varset countquick ${countquick}+1
/varcalc count ${count}+1
}
if ${Group.Member[x].PctHPs} > 50 && ${Group.Member[x].PctHPs} < ${lower90}) {
/varset lower70 ${Group.Member[x].PctHPs}
/varset lower70toon ${Group.Member[x]}
}
if ${Group.Member[x].PctHPs} < ${lower50}) {
/varset lower50 ${Group.Member[x].PctHPs}
/varset lower50toon ${Group.Member[x]}
}
/next x
/if (${count}>=${autogroupcount}) {
/if (${countquick}>1) {
| Auto Break Current Casting
/if (${Me.Casting.ID} || ${Window[TargetWindow].Child[Casting_SpellName].Text.Length} || ${Window[CastingWindow].Open}) /stopcast
/delay 1s (${Cast.Ready})
/if (${Me.Moving}) {
/keypress left
/keypress right
/keypress forward
/keypress back
/keypress forward
}
/if (${Me.Ducking}) /keypress DUCK
}
/if ((${Me.Class.Name.Equal[Cleric]} || ${Me.Class.Name.Equal[Paladin]}) && !${Me.Moving}) {
/if (${count100}>=${autogroupcount}) {
casting Group Heal 100 range...
} else /if (${count70}>=${autogroupcount}) {
casting Group Heal 70 range...
} else {
casting Spell Group Heal...
}
}
/if ((${Me.Class.Name.Equal[Shaman]} || ${Me.Class.Name.Equal[Druid]}) && !${Me.Moving}) {
casting Clicies Group Heal...
}
} else /if (${Spawn[pc ${lower50toon}].ID}) {
casting 50hp...
} else /if (${Spawn[pc ${lower70toon}].ID}) {
casting 70hp...
}
/return
Return to “Third party software”
Users browsing this forum: No registered users and 1 guest