My Version of ShamBot

A forum for you to dump all the macros you create, allowing users to use, modify, and comment on your work.

Moderator: MacroQuest Developers

Tuffy
a lesser mummy
a lesser mummy
Posts: 33
Joined: Thu Oct 02, 2003 9:20 am

My Version of ShamBot

Post by Tuffy » Thu Jan 22, 2004 2:38 pm

Yep it's a hack, chop, past, or what ever else you can think of. But it does the job. I didn't use spell names because I use my shaman with toons of different levels. Just mem the spell sit of the toon I'm followind and a way I go.

Code: Select all

|Sham.mac  
| To start type /macro Sham mastername 
| I take no credit for any of this code.
| All code has came from other people.
| 

#chat tell 

#Event CastResist "Your target resisted "



Sub Main 
/declare MastersName global 
/varset MastersName "@Param0" 

/echo >>>Check Spells<<<


:MainLoop 
  /doevents 
  /goto :MainLoop 

/return 

Sub Event_Chat 
|Master Command
  /if "@Param1"!="@MastersName" /return 

|Common Commands
  /if "@Param2"~~"sit" 		/sit 
  /if "@Param2"~~"stand" 	/stand 
  /if "@Param2"~~"Follow" 	/follow 
  /if "@Param2"~~"botcamp" 	/q 
  /if "@Param2"~~"botattack" 	/attack 
  /if "@Param2"~~"endmacro" 	/endmacro
  /if "@Param2"~~"mana" 	/call do-mana

  /if "@Param2"~~"assist" 	/call Do-Assist 

|Pet Commands
  /if "@Param2"~~"petattack" 	/call PetAttack 
  /if "@Param2"~~"petback" 	/call Petback 
  /if "@Param2"~~"petguard" 	/call petguard 
  /if "@Param2"~~"pethold" 	/call pethold 

|Special Commands
|  /if "@Param2"~~"Epic" 	/call Do-Epic 	|Epic Spear of Fate

  /if "@Param2"~~"Slow" 	/call Do-Slow 	|Gem 8 
  /if "@Param2"~~"Heal" 	/call Do-Heal 	|Gem 7
  /if "@Param2"~~"regen" 	/call Do-Regen	|Gem 6
  /if "@Param2"~~"hos" 		/call Do-Hos	|Gem 5
  /if "@Param2"~~"stam" 	/call Do-Stam	|Gem 4
  /if "@Param2"~~"Malo" 	/call Do-Malo	|Gem 3
  /if "@Param2"~~"nuke" 	/call Do-Nuke	|Gem 2
  /if "@Param2"~~"dance" 	/call Do-Dance	|Gem 1

 
/return 

|==============================================================
|Epic
|==============================================================
|Sub Do-Epic
	/sit off 
	/assist @MastersName 
	/delay 2s
        /attack off 
	/cast item "Spear of Fate"
	/delay 1s 
	/tell @MastersName Casting Epic on %T
	/delay 10s 
        /sit on
/return 

|============================================================== 
|Common Commands

Sub Do-Assist 
	/assist @MastersName 
	/delay 2s
        /attack off 
	/tell @MastersName Assisting you on %T

/return 

Sub Do-mana
        /tell @MastersName Mana Status is $char(mana,pct)

/return
|============================================================== 
|Pet Commands

Sub PetAttack 
	/pet attack 

/return 

Sub PetBack 
	/pet back off 
	/pet back off 
	/pet back off 

/return

Sub petguard 
	/pet guard here 

/return 

Sub pethold
	/pet hold

/return

|============================================================== 
|Special Commands

|Gem 8
Sub Do-Slow 
	/sit off 
	/assist @MastersName 
	/delay 2s 
        /attack off	
        /cast 8
    	/delay 1s 
	/tell @MastersName Slowing %T
	/delay 6s 
        /sit on
/return 


|Gem 7
Sub Do-Heal 
	/sit off 
	/target @MastersName 
	/delay 1s 
	/cast 7
	/delay 1s 
	/tell @MastersName Casting a heal on %T
	/delay 6s 
        /sit on
/return 

|Gem 6
Sub Do-Regen 
	/sit off 
	/target @MastersName 
	/delay 1s 
	/cast 6
	/delay 1s 
	/tell @MastersName Casting regen on %T
	/delay 6s 
        /sit on
/return 

|Gem 5
Sub Do-HoS 
	/sit off 
	/target @MastersName 
	/delay 1s 
	/cast 5
	/delay 1s 
	/tell @MastersName Casting HoS on %T 
	/delay 6s 
        /sit on
/return 

|Gem 4
Sub Do-stam 
	/sit off 
	/target @MastersName 
	/delay 1s 
	/cast 4
	/delay 1s 
	/tell @MastersName Casting sta on %T 
	/delay 6s 
        /sit on
/return 

|Gem 3
Sub Do-Malo 
	/sit off 
	/assist @MastersName 
	/delay 2s
        /attack off 
	/cast 3
	/delay 1s 
	/tell @MastersName Debuffin %T 
	/delay 6s 
        /sit on
/return 

|Gem 2
Sub Do-Nuke 
	/sit off 
	/assist @MastersName 
	/delay 2s
        /attack off 
	/cast 2
	/delay 1s 
	/tell @MastersName "Nuking %T" 
	/delay 6s 
        /sit on
/return 

|Gem 1
Sub Do-Dance 
	/sit off 
	/if n $char(hp,pct)>=50 /cast 1
	/delay 1s 
	/tell @MastersName Done Dancing
	/delay 6s 
        /sit on
/return 


|==============================================================
|#Event Sub Commands

Sub Event_CastResist 

	/tell @MastersName %t resisted spell
	
/return
Enjoy

illus1on
orc pawn
orc pawn
Posts: 24
Joined: Wed Apr 14, 2004 3:32 pm

Post by illus1on » Sun Apr 18, 2004 6:33 pm

I've been trying to get a Shaman macro similar to this one, writing, and cutting-pasting it also. Im having no luck. I am looking through this one, and I think that it could be something that is along the lines of what I am looking for.

The buffing, epic, malos, slowing, etc.

What would the command be for Malo'ing the mob at inc (when in range) and then slowing immediately after? Auto retry if resisted. I'm not skilled in languages on this board, and most of the things I read here are like ancient hieroglyphics to me anyhow.

But, if you wouldn't mind it, I would definitely be up for the addition into this current little script.

frabtik
a ghoul
a ghoul
Posts: 114
Joined: Sat Feb 21, 2004 10:07 am

Post by frabtik » Mon Apr 19, 2004 9:40 am

autodebuff.mac
This code looks really bad.
Not sure that there is a point to having one line subs that are only called once. They def make the macro more difficult to read and understand. Having 10 subs that all do almost exactly the same thing also makes it more difficult to understand. The point of writing a sub in my opinion it to break it up into more easily understood portions and break a problem down into smaller pieces to tackle at at time and to prevent rewriting the same code 10 times. If the subs have only one line different you probly need to pass some parameters to them but really the casting code is pretty backass words anyway. Casting spells by gem will always fail if you have them in wrong order etc and may get you your group or raid in a world of hurt if you are depending on them. I would advise to look at one of the spellcast.inc files in the snippets forum to get a better idea of how casting should be done and just use them anyway. If you do not like autodebuff for some reason or another, ie you are a moron, then genbot certainly would cover pretty much everything you are doing as well. Genbot may not be the best way of doing lots of things but it still works fine from my experience and the posts indicate a rewrite is in the works to optimize a lot of redundant code and add new enhancements. But really if you are running a shaman autodebuff is probly the code to start with.

Lane
a hill giant
a hill giant
Posts: 201
Joined: Fri Dec 06, 2002 11:57 am

Post by Lane » Mon Apr 19, 2004 12:17 pm

Some pretty harsh comments on this macro.

I've bene using this for several months now on a shammy that I was originally PLing. It was kinda pointless to write and rewrite the macro when I was getting new spells every few EQ sessions. With this I didn't have to rewrite. I kept an updated spell load at each spell level so I rarly had the wrong spell loaded.

On breaking it up into subs, I was quite happy with that. I've gone through and modified almost all of them to do others things that I needed and added to each of the comments.

You may not see any point to the way he did things, but that doesn't meen it's not usful to others just the way it is. Thanks for the code. I still use it today, now that my shammy is over lvl 60, and I'm using him in groups and raids using modified versions of this macro.

-Lane

Tuffy
a lesser mummy
a lesser mummy
Posts: 33
Joined: Thu Oct 02, 2003 9:20 am

Post by Tuffy » Mon Apr 19, 2004 6:05 pm

Thanks for the comments Lane, this was one of my first atempts at right mq2 code.


To the hater. /shrug use genbot.

Waxxedazz
a lesser mummy
a lesser mummy
Posts: 47
Joined: Sat May 31, 2003 7:09 pm

heh

Post by Waxxedazz » Mon Apr 19, 2004 10:23 pm

..I.. to the hater! At least someone is trying instead of always whining for people to make them a bot macro. WTG on your first attempt its better then my first.