Moderator: MacroQuest Developers
Code: Select all
:ScanSelf
:LoopStart
/press F1
/varset $v11 $target(HP,pct)
:ScanGM2
/press F2
call CheckCasterGroupMember2
/varset $v22 $target(HP,pct)
:ScanGM3
/press F3
call CheckCasterGroupMember3
/varset $v33 $target(HP,pct)
:ScanGM4
/press F4
call CheckCasterGroupMember4
/varset $v44 $target(HP,pct)
:ScanGM5
/press F5
call CheckCasterGroupMember5
/varset $v55 $target(HP,pct)
:ScanGM6
/press F6
call CheckCasterGroupMember6
/varset $v66 $target(HP,pct)
Sub CheckCasterGroupMember2
/if $target(pc==Enchanter) {
/varset $v2 1
/goto :ScanGM3
}
Else /if $target(pc==Magician) {
/varset $v2 1
/goto :ScanGM3
}
Else /if $target(pc==Cleric) {
/varset $v2 1
/goto :ScanGM3
}
Else /if $target(pc==Beastlord) {
/varset $v2 1
/goto :ScanGM3
}
Else /if $target(pc==Necromancer) {
/varset $v2 1
/goto :ScanGM3
}
Else /if $target(pc==Druid) {
/varset $v2 1
/goto :ScanGM3
}
Else /if $target(pc==Shaman) {
/varset $v2 1
/goto :ScanGM3
}
Else /if $target(pc==Wizard) {
/varset $v2 1
/goto :ScanGM3
}
Else{
/varset $v2 0
/goto :ScanGM3
}
Sub CheckCasterGroupMember3
/if $target(pc==Enchanter) {
/varset $v3 1
/goto :ScanGM4
}
Else /if $target(pc==Magician) {
/varset $v3 1
/goto :ScanGM4
}
Else /if $target(pc==Cleric) {
/varset $v3 1
/goto :ScanGM4
}
Else /if $target(pc==Beastlord) {
/varset $v3 1
/goto :ScanGM4
}
Else /if $target(pc==Necromancer) {
/varset $v3 1
/goto :ScanGM4
}
Else /if $target(pc==Druid) {
/varset $v3 1
/goto :ScanGM4
}
Else /if $target(pc==Shaman) {
/varset $v3 1
/goto :ScanGM4
}
Else /if $target(pc==Wizard) {
/varset $v3 1
/goto :ScanGM4
}
Else{
/varset $v3 0
/goto :ScanGM4
}
Sub CheckCasterGroupMember4
/if $target(pc==Enchanter) {
/varset $v4 1
/goto :ScanGM5
}
Else /if $target(pc==Magician) {
/varset $v4 1
/goto :ScanGM5
}
Else /if $target(pc==Cleric) {
/varset $v4 1
/goto :ScanGM5
}
Else /if $target(pc==Beastlord) {
/varset $v4 1
/goto :ScanGM5
}
Else /if $target(pc==Necromancer) {
/varset $v4 1
/goto :ScanGM5
}
Else /if $target(pc==Druid) {
/varset $v4 1
/goto :ScanGM5
}
Else /if $target(pc==Shaman) {
/varset $v4 1
/goto :ScanGM5
}
Else /if $target(pc==Wizard) {
/varset $v4 1
/goto :ScanGM5
}
Else{
/varset $v4 0
/goto :ScanGM5
}
Sub CheckCasterGroupMember5
/if $target(pc==Enchanter) {
/varset $v5 1
/goto :ScanGM6
}
Else /if $target(pc==Magician) {
/varset $v5 1
/goto :ScanGM6
}
Else /if $target(pc==Cleric) {
/varset $v5 1
/goto :ScanGM6
}
Else /if $target(pc==Beastlord) {
/varset $v5 1
/goto :ScanGM6
}
Else /if $target(pc==Necromancer) {
/varset $v5 1
/goto :ScanGM6
}
Else /if $target(pc==Druid) {
/varset $v5 1
/goto :ScanGM6
}
Else /if $target(pc==Shaman) {
/varset $v5 1
/goto :ScanGM6
}
Else /if $target(pc==Wizard) {
/varset $v5 1
/goto :ScanGM6
}
Else {
/varset $v5 0
/goto :ScanGM6
}
Sub CheckCasterGroupMember6
/if $target(pc==Enchanter) {
/varset $v6 1
}
Else /if $target(pc==Magician) {
/varset $v6 1
}
Else /if $target(pc==Cleric) {
/varset $v6 1
}
Else /if $target(pc==Beastlord) {
/varset $v6 1
}
Else /if $target(pc==Necromancer) {
/varset $v6 1
}
Else /if $target(pc==Druid) {
/varset $v6 1
}
Else /if $target(pc==Shaman) {
/varset $v6 1
}
Else /if $target(pc==Wizard) {
/varset $v6 1
}
Else{
/varset $v6 0
Call Heal
}
Sub Heal
/if $v11<=80 and $v22<=80 and $v33<=80 and $v44<=80 and $v55<=80 and $v66<=80{
Call GroupHeal
}
/if $v11<=60{
call FastHeal
}
else /if $v11=>61{
call CompleteHeal
}
/if $v2=1{
call FastHeal
}
else /if $v2=0{
call CompleteHeal
}
/if $v3=1{
call FastHeal
}
else /if $v3=0{
call CompleteHeal
}
/if $v4=1{
call FastHeal
}
else /if $v4=0{
call CompleteHeal
}
/if $v5=1{
call FastHeal
}
else /if $v5=0{
call CompleteHeal
}
/if $v6=1{
call FastHeal
}
else /if $v6=0{
call CompleteHeal
}
Sub FastHeal
/sit off
/cast “Divine Light”
/delay 6
/sit on
/goto :LoopStart
Sub CompleteHeal
/sit off
/cast “Complete Healing”
/delay 12
/sit on
/goto :LoopStart
Sub GroupHeal
/sit off
/cast “Word of Restoration”
/delay 6
/sit on
/goto :LoopStart
Code: Select all
/if x==y {
/echo x is y....
} else /if y==z {
/echo y is z
} else {
echo y isn't z or x...
}Code: Select all
:ScanSelf
:LoopStart
/press F1
/varset $v11 $target(HP,pct)
:ScanGM2
/press F2
call CheckCasterGroupMember2
/varset $v22 $target(HP,pct)
:ScanGM3
/press F3
call CheckCasterGroupMember3
/varset $v33 $target(HP,pct)
:ScanGM4
/press F4
call CheckCasterGroupMember4
/varset $v44 $target(HP,pct)
:ScanGM5
/press F5
call CheckCasterGroupMember5
/varset $v55 $target(HP,pct)
:ScanGM6
/press F6
call CheckCasterGroupMember6
/varset $v66 $target(HP,pct)
Sub CheckCasterGroupMember2
/if $target(pc==Enchanter) {
/varset $v2 1
/goto :ScanGM3
} Else /if $target(pc==Magician) {
/varset $v2 1
/goto :ScanGM3
} Else /if $target(pc==Cleric) {
/varset $v2 1
/goto :ScanGM3
} Else /if $target(pc==Beastlord) {
/varset $v2 1
/goto :ScanGM3
} Else /if $target(pc==Necromancer) {
/varset $v2 1
/goto :ScanGM3
} Else /if $target(pc==Druid) {
/varset $v2 1
/goto :ScanGM3
} Else /if $target(pc==Shaman) {
/varset $v2 1
/goto :ScanGM3
} Else /if $target(pc==Wizard) {
/varset $v2 1
/goto :ScanGM3
} Else{
/varset $v2 0
/goto :ScanGM3
}
Sub CheckCasterGroupMember3
/if $target(pc==Enchanter) {
/varset $v3 1
/goto :ScanGM4
} Else /if $target(pc==Magician) {
/varset $v3 1
/goto :ScanGM4
} Else /if $target(pc==Cleric) {
/varset $v3 1
/goto :ScanGM4
} Else /if $target(pc==Beastlord) {
/varset $v3 1
/goto :ScanGM4
} Else /if $target(pc==Necromancer) {
/varset $v3 1
/goto :ScanGM4
} Else /if $target(pc==Druid) {
/varset $v3 1
/goto :ScanGM4
} Else /if $target(pc==Shaman) {
/varset $v3 1
/goto :ScanGM4
} Else /if $target(pc==Wizard) {
/varset $v3 1
/goto :ScanGM4
} Else{
/varset $v3 0
/goto :ScanGM4
}
Sub CheckCasterGroupMember4
/if $target(pc==Enchanter) {
/varset $v4 1
/goto :ScanGM5
} Else /if $target(pc==Magician) {
/varset $v4 1
/goto :ScanGM5
} Else /if $target(pc==Cleric) {
/varset $v4 1
/goto :ScanGM5
} Else /if $target(pc==Beastlord) {
/varset $v4 1
/goto :ScanGM5
} Else /if $target(pc==Necromancer) {
/varset $v4 1
/goto :ScanGM5
} Else /if $target(pc==Druid) {
/varset $v4 1
/goto :ScanGM5
} Else /if $target(pc==Shaman) {
/varset $v4 1
/goto :ScanGM5
} Else /if $target(pc==Wizard) {
/varset $v4 1
/goto :ScanGM5
} Else{
/varset $v4 0
/goto :ScanGM5
}
Sub CheckCasterGroupMember5
/if $target(pc==Enchanter) {
/varset $v5 1
/goto :ScanGM6
} Else /if $target(pc==Magician) {
/varset $v5 1
/goto :ScanGM6
} Else /if $target(pc==Cleric) {
/varset $v5 1
/goto :ScanGM6
} Else /if $target(pc==Beastlord) {
/varset $v5 1
/goto :ScanGM6
} Else /if $target(pc==Necromancer) {
/varset $v5 1
/goto :ScanGM6
} Else /if $target(pc==Druid) {
/varset $v5 1
/goto :ScanGM6
} Else /if $target(pc==Shaman) {
/varset $v5 1
/goto :ScanGM6
} Else /if $target(pc==Wizard) {
/varset $v5 1
/goto :ScanGM6
} Else {
/varset $v5 0
/goto :ScanGM6
}
Sub CheckCasterGroupMember6
/if $target(pc==Enchanter) {
/varset $v6 1
} Else /if $target(pc==Magician) {
/varset $v6 1
} Else /if $target(pc==Cleric) {
/varset $v6 1
} Else /if $target(pc==Beastlord) {
/varset $v6 1
} Else /if $target(pc==Necromancer) {
/varset $v6 1
} Else /if $target(pc==Druid) {
/varset $v6 1
} Else /if $target(pc==Shaman) {
/varset $v6 1
} Else /if $target(pc==Wizard) {
/varset $v6 1
} Else{
/varset $v6 0
Call Heal
}
Sub Heal
/if $v11<=80 and $v22<=80 and $v33<=80 and $v44<=80 and $v55<=80 and $v66<=80{
Call GroupHeal
}
/if $v11<=60{
call FastHeal
} else /if $v11=>61{
call CompleteHeal
} /if $v2=1{
call FastHeal
} else /if $v2=0{
call CompleteHeal
} /if $v3=1{
call FastHeal
} else /if $v3=0{
call CompleteHeal
} /if $v4=1{
call FastHeal
} else /if $v4=0{
call CompleteHeal
} /if $v5=1{
call FastHeal
} else /if $v5=0{
call CompleteHeal
} /if $v6=1{
call FastHeal
} else /if $v6=0{
call CompleteHeal
}
Sub FastHeal
/sit off
/cast “Divine Light”
/delay 6
/sit on
/goto :LoopStart
Sub CompleteHeal
/sit off
/cast “Complete Healing”
/delay 12
/sit on
/goto :LoopStart
Sub GroupHeal
/sit off
/cast “Word of Restoration”
/delay 6
/sit on
/goto :LoopStart