Cleric group autoheal script

Macro depository for macros written before the user variable changes that broke all of them.

Moderator: MacroQuest Developers

powerspike
a ghoul
a ghoul
Posts: 80
Joined: Sun Aug 11, 2002 11:40 pm
Location: Australia
Contact:

Cleric group autoheal script

Post by powerspike » Sun Aug 18, 2002 12:25 am

Well this is my first script from scratch so something might not be quite right. IT's a group autoheal script for a cleric, when you run it starts running though characters in the group and heals when there under 50% health (added a commented out section for Complete heal as well for thoose that are over lvl 39).

any suggestions or ideas very welcome.

Code: Select all

| - clericAH.mac -
| By powerspike
| Basic group auto heal script
#include spellsub.mac

Sub Main
	/press ESC
	/press F1
	/if "$target()"=="TRUE" /varset v7 0
	/press ESC
	/press F2
	/if "$target()"=="TRUE" /varset v7 1
	/press ESC
	/press F3
	/if "$target()"=="TRUE" /varset v7 2
	/press ESC
	/press F4
	/if "$target()"=="TRUE" /varset v7 3
	/press ESC
	/press F5
	/if "$target()"=="TRUE" /varset v7 4
	/press ESC
	/press F6
	/if "$target()"=="TRUE" /varset v7 5
	/press ESC
	:LoopStart

		/delay 1
			|/echo $v7 --
			/for v40 0 to $v7
				/delay 5
				/if n $v40==0 /press F1
				/if n $v40==1 /press F2
				/if n $v40==2 /press F3
				/if n $v40==3 /press F4
				/if n $v40==4 /press F5
				/if n $v40==5 /press F6
				/varset v59 $target(hp,pct)
				| the if statement checks to see if HP are under 50% on the target if so stand heal and sit
				/if n $v59<=50 {
					/sit off
					/gsay Healing $target(name)
					| This call spellsub is set to Sup Heal (slot 1)
					/call SpellSub 1 8
					| THis call Spell Sub is set to Cheal (slot 2)
					| /call Spell Sub 2 13
					/sit on
				} else /if n $v59>=90 {
					/delay 0				
				}
			/next v40
	/goto :LoopStart
	/return
/goto LoopStart
/return


(just edited the HP line from /varset v59 $target(hp,cur) to /varset v59 $target(hp,pct) - when it checked yourself you got HP in points instead of percent so it wouldn't heal yourself until you where down to 50 HP instead of 50%HP) :)
Last edited by powerspike on Sun Aug 18, 2002 2:26 am, edited 1 time in total.

User avatar
L124RD
Site Admin
Site Admin
Posts: 1343
Joined: Fri Jun 14, 2002 12:15 am
Location: Cyberspace
Contact:

Post by L124RD » Sun Aug 18, 2002 12:31 am

Salutations,
maybe you should put a mana check in there, make sure you have enough mana to heal 'em before you /gsay you're healing when you can't...

User avatar
rizwank
Huggle Police
Huggle Police
Posts: 524
Joined: Tue Jul 23, 2002 12:07 am
Contact:

Post by rizwank » Sun Aug 18, 2002 2:04 am

perhaps also a setup so you can CH tanks and just heal the rest, or if someones hp is well below 50% then you cast a faster heal etc...

its a good script though, esp for one from scratch:)

powerspike
a ghoul
a ghoul
Posts: 80
Joined: Sun Aug 11, 2002 11:40 pm
Location: Australia
Contact:

Post by powerspike » Sun Aug 18, 2002 2:24 am

already working on making it better, seems you can get a characters class, was thinking about healing based on class - cheal tanks on 20-30% HP casters on around 40-50%, just working though stupid logic errors at the moment =)

User avatar
rizwank
Huggle Police
Huggle Police
Posts: 524
Joined: Tue Jul 23, 2002 12:07 am
Contact:

Post by rizwank » Sun Aug 18, 2002 2:34 am

uberness would be doing a change in hp over time and knowing if, at that right, if CH will cast in time or not... include celestial heal for higher lvls etc...

and make sure not to heal druids shm clr.

good job :) thanks for sharing it with us

powerspike
a ghoul
a ghoul
Posts: 80
Joined: Sun Aug 11, 2002 11:40 pm
Location: Australia
Contact:

Post by powerspike » Tue Aug 20, 2002 2:02 am

assuming working out damage over time is possible, anyone got any idea's on how to do it ?

User avatar
RPZip
a lesser mummy
a lesser mummy
Posts: 63
Joined: Sun Aug 11, 2002 11:31 pm

Post by RPZip » Tue Aug 20, 2002 12:19 pm

Get group members HP every second, then do some simple calcs? I dunno...

powerspike
a ghoul
a ghoul
Posts: 80
Joined: Sun Aug 11, 2002 11:40 pm
Location: Australia
Contact:

Post by powerspike » Tue Aug 20, 2002 8:27 pm

was thinking about using the array varible and maybe save the hp for the last 10 seconds, work out how fast they are losing HP, comparing that to the max HP to try and get a DPS value, but the problem with that is if your getting hit with spells it would throw it out of wack (ie getting hit with a 600DD it would think your taking an extra 60damage / second) and might end up healing you way to early), but the general idea would to be complete heal a tank around 20-25 seconds before death. any idea's or forseeable problems please let me know, or a push in the right direction.
my cleric got 39 last night so i can test it now ;)

Banned_From_EQ
orc pawn
orc pawn
Posts: 16
Joined: Mon Jun 24, 2002 7:01 pm

Post by Banned_From_EQ » Sat Aug 31, 2002 5:08 pm

nm

Banned_From_EQ
orc pawn
orc pawn
Posts: 16
Joined: Mon Jun 24, 2002 7:01 pm

hmm

Post by Banned_From_EQ » Fri Sep 06, 2002 4:02 pm

So i tried out the macro it doesnt CH and it after everyheal it always says OOM. Any ideas?

powerspike
a ghoul
a ghoul
Posts: 80
Joined: Sun Aug 11, 2002 11:40 pm
Location: Australia
Contact:

Post by powerspike » Sat Sep 07, 2002 6:29 am

this macro was written when my cleric was around lvl 35ish - so by default it sup heals only - you can get it to cheal by removing the comment lines.

change this

Code: Select all

               /sit off 
               /gsay Healing $target(name) 
               | This call spellsub is set to Sup Heal (slot 1) 
               /call SpellSub 1 8 
               | THis call Spell Sub is set to Cheal (slot 2) 
               | /call Spell Sub 2 13 
               /sit on 

to this

Code: Select all

               /sit off 
               /gsay Healing $target(name) 
               | This call spellsub is set to Sup Heal (slot 1) 
               |/call SpellSub 1 8 
               | THis call Spell Sub is set to Cheal (slot 2) 
               /call Spell Sub 2 13 
               /sit on 

for complete heal.
If your going to use Complete heal - you might want to drop from 50% to somewhere around 25-30% for better mana effichency



i realy don't know how it can say OOM where there are no mana checks and /tell /gsay /etc stuff in the script ??????
One for the Road guys, what's the worst that could happen......

LOADING, PLEASE WAIT ....

Banned_From_EQ
orc pawn
orc pawn
Posts: 16
Joined: Mon Jun 24, 2002 7:01 pm

Post by Banned_From_EQ » Sat Sep 07, 2002 8:17 am

I found the prob its in spell sub

S_B_R
a lesser mummy
a lesser mummy
Posts: 72
Joined: Tue Jul 30, 2002 11:12 am

Post by S_B_R » Sat Sep 07, 2002 2:25 pm

The problem is if for any reason (other than Fizzle or interruption) "You begin casting" does not come up the spellsub.mac sub routine will assume you are oom and say so. For example:
"Your target is out of range, get closer!"
"You haven't recovered yet..."

Both of those instances will cause spellsub.mac to claim you are OOM. Also should you happen to be doing anything in the inventory or if you cast a spell manually it will also likely say you are OOM.

Later today (hopefully) I'll be posting my updated cleric macro and my spellsub macro. I still need to clean up a few things and give it one last good run through test.
[b]dd if=/dev/zero of=/dev/hda[/b]

S_B_R
a lesser mummy
a lesser mummy
Posts: 72
Joined: Tue Jul 30, 2002 11:12 am

Post by S_B_R » Sat Sep 07, 2002 4:10 pm

Posted the Macro(s) in a new thread Here
[b]dd if=/dev/zero of=/dev/hda[/b]