Moderator: MacroQuest Developers
donations for this month's patches.Code: Select all
/declare GID int outer 0
/declare HealPct int outer 70
/declare MemGem int outer 8
/declare HealingSpell string outer "Minor Healing"
Sub Main
/Call DoGroupCheck
/return
Sub DoGroupCheck
/For GID 0 to ${Math.Calc[${Group.GroupSize}-1]} {
/target ID ${Group.Member[${GID}].ID}
/call Memspell ${HealingSpell} ${MemGem}
/delay 30s ${Me.SpellReady[${HealingSpell}
/If (${Group.Member[${GID}].PctHPs}>${HealPct}) /cast ${HealingSpell}
/delay 30s !${Me.Casting}
/target clear
}
/return
Sub MemSpell(SpellName,SpellGem)
/if (${Me.Gem["${SpellName}"]) /return
/mem ${SpellName} ${SpellGem}
/delay 20s ${Window[SpellBookWnd].Open}
/return
why even bother with spawn?iconicman wrote:I always target using IDs rather than names
/target id ${Spawn[ID ${Group.Member[${GID}].ID}]}
Always told it was best practice to do that.
Code: Select all
/target id ${Group.Member[GID].ID}Code: Select all
/For GID 0 to ${Math.Calc[${Group.GroupSize}-1]} Code: Select all
/For GID 0 to ${Group} Code: Select all
/next GIDCode: Select all
/If (${Group.Member[${GID}].PctHPs}>${HealPct}) /cast ${HealingSpell}Code: Select all
/If (${Group.Member[${GID}].PctHPs}<${HealPct}) /cast ${HealingSpell}lol thanks maskoi for ripping my macro apart :p i never tested it... like i said... i was at work...Maskoi wrote:why even bother with spawn?iconicman wrote:I always target using IDs rather than names
/target id ${Spawn[ID ${Group.Member[${GID}].ID}]}
Always told it was best practice to do that.and ${Group} = number of group members without youCode: Select all
/target id ${Group.Member[GID].ID}could beCode: Select all
/For GID 0 to ${Math.Calc[${Group.GroupSize}-1]}and your /for needs a /next you have it {} like a /if statementCode: Select all
/For GID 0 to ${Group}and > should be < or it will heal when toons hps are over 70% not underCode: Select all
/next GIDchange toCode: Select all
/If (${Group.Member[${GID}].PctHPs}>${HealPct}) /cast ${HealingSpell}Code: Select all
/If (${Group.Member[${GID}].PctHPs}<${HealPct}) /cast ${HealingSpell}