Healer helper

Have a macro idea but not sure where to start? Ask here.

Moderator: MacroQuest Developers

Bobthebuilder
decaying skeleton
decaying skeleton
Posts: 1
Joined: Wed Jul 09, 2008 8:44 am

Healer helper

Post by Bobthebuilder » Wed Jul 09, 2008 9:13 am

I have searched around and found some macros that i suppose could be edited, however I cant seem to get them to work..
just looking for a simple macro that I can send a tell to my box'd shaman saying "heal me" and he will heal.. That's pretty much it.

thanks in advance.

MattJM
orc pawn
orc pawn
Posts: 12
Joined: Thu Nov 10, 2005 3:05 pm

Post by MattJM » Wed Jul 09, 2008 10:09 am

Get VIP...Use Autobot/Modbot and learn to search...

This is in non-vip...

http://www.macroquest2.com/phpBB2/viewtopic.php?t=9541

That should be perfect for you...

User avatar
three-p-o
a grimling bloodguard
a grimling bloodguard
Posts: 600
Joined: Sun Nov 03, 2002 5:59 pm

Post by three-p-o » Wed Jul 09, 2008 10:53 am

I concur with MattJM, however since I am bored at work.
Riped and modified from an old macro that I had made updates to. Note, the original was a nuking macro, not sure if this will work.
This should be a little secure, commands have to be sent via tell and you have to define a master.
It should also warn you when someone other than you attempts to use your Shammy and relay tells to you.
it will setup an INI file with the master you specified on first load using Minor Healing on gem1. Edit the INI file to change these.

Requires spell_routines.inc
Has not been tested and I am not going to support it.

Save as healme.mac

Code: Select all

| Usage /mac healme master

#include spell_routines.inc

#chat tell

Sub Main
	/declare IniFile          string outer
	/declare Master           string outer
	/declare Spell            string outer
	/declare Gem              string outer

	/varset IniFile heal_${Me.Name}.ini
	/if (${Defined[Param0]}) {
		/ini "${IniFile}" Settings Master ${Param0}
		/varset Master ${Param0}
	} else /if (!${Defined[Param0]}) {
		/varset TempStr ${Ini[${IniFile},Settings,tankname,NOTFOUND]}
		/varset Master ${TempStr}
		/if (${TempStr.Equal["NOTFOUND"]}) {
			/echo You need to start the macro with /mac healme master and generate your .INI file.
			/endmacro
		}
	}
	/call LoadINI
	/call AntiRetard
	/cleanup
	/echo Macro successfully started.
	/echo Your master is ${Master}
	/if (${Me.Sitting}) /sit off
	
	:mainloop
	
	/doevents
	/delay 0
	
	/goto :mainloop
/endmacro
	

Sub Event_Chat(ChatType, Sender, ChatText)
	:wait1
	/if (${Me.Casting.ID} || ${Me.Moving}) /goto :wait1
	/if (${Sender} = ${Master} && ${ChatText} = "heal me") {
		/if (${Spawn[${Sender}].ID} && ${Spawn[${Sender}].Distance}<=100) {
			/squelch /target id ${Spawn[${Sender}].ID}
			/delay 2s
			/call cast "$Spell" $Gem 7s
		} else {
			/echo Heal failed - ${Sender} too far away or not in zone.
		}
	} else /if (${Sender} <> ${Master} && ${ChatText} = "heal me") {
		/echo WARNING!!! - Non-authorized user, ${Sender}, attempting use me.
		/squelch /tell ${Master} ${Sender} is attempting to have me heal him.
		/goto done
	} else /if (${Sender} <> ${Master} && ${ChatText} <> "heal me") {
		/squelch /tell ${Master} ${Sender} told me ${ChatText}
	}
	:done
/return

Sub LoadINI
	|  INI setup variables
	/varset TempStr ${Ini[${IniFile},Settings,Spell,NOTFOUND]}
	/varset Spell ${TempStr}
	/if (${TempStr.Equal["NOTFOUND"]}) {
		/varset INIFlag 1
		/ini "${IniFile}" Settings Spell "Minor Healing"
		/varset Spell Minor Healing
	}
	/varset TempStr ${Ini[${IniFile},Settings,Gem,NOTFOUND]}
	/varset Gem ${TempStr}
	/if (${TempStr.Equal["NOTFOUND"]}) {
		/varset INIFlag 1
		/ini "${IniFile}" Settings Gem gem1
		/varset Gem gem1
	}
	/if (${INIFlag}==1) {
		/echo INI file created/appended.  Please customize ${IniFile} in your macros directory. You may now start the macro with /mac afnuke
		/endmacro
	}
/return

Sub AntiRetard
	|  Anti Retard Code
	/if (!${Me.Book["${Spell}"]}) {
		/echo You don't seem to have the spell ${Spell}
		/endmacro
	}
/return
Slovotsky's Law # 146. Power corrupts. Absolute power is kind of neat.

"When i open the dll files expecting to just copy their code to the cpp file is all garbage and not code. Is the procedure for adding dll plugins different?" -- fujitsu