Page 2 of 3

Posted: Wed Mar 30, 2005 10:20 am
by psychosis
Im working with OnyxSys on this and have posted in MQ2::Macros::Help looking for additional info.

Here is the Post

Posted: Wed Mar 30, 2005 1:13 pm
by gimp
I have a new version of the buffbot which i made into a include module instead. I am currently testing it out by running it non-stop together with my usual macro, some improvements were made but i'll wait with posting it until tomorrow or so since i still want to test it some more.

Changes include ini-support for guild-name (if noone is set, default to ${Me.Guild}), accepted buffs stored in INI on a per-character basis so same INI can handle multiple toons, and some tweaks to the parse tells so a few more requests should be recognized.

Posted: Thu Mar 31, 2005 10:39 am
by gimp
Updated first post with new version of the script, if you used the old one please try this out.

Posted: Thu Mar 31, 2005 12:16 pm
by nils
put this into mycleric this morning testing it out works real nice so far....

nils

Posted: Thu Mar 31, 2005 12:40 pm
by nils
hmm anyway of adding in a 'follow'and 'stop' to your little buffbot.inc the one of the shambot has...

nils

Posted: Thu Mar 31, 2005 12:50 pm
by fearless
Those functions should belong in the cleric macro, not in the buffing include file.

Posted: Thu Mar 31, 2005 3:31 pm
by gimp
edit: nm

Not Finished but here is a preview...

Posted: Thu Mar 31, 2005 9:40 pm
by OnyxSys
Original Buffbot Modified... Will Test out the new version later on :)

addition usage:

/tell cheater buffme

(will buff the 5 [up to 7] buffs that have been inserted into .ini file)

Code: Select all

| buffbot.mac 
| 

#include spell_routines.inc 

#define GUILD_NAME  "YourGuildHere" 

#define NOT_FOUND   -1 
#define BUFFBOT_INI "buffbot.ini" 

#define BOOL_TRUE   1 
#define BOOL_FALSE  0 

#Event HandleBuffRequest "#1# tells you, '#2#'" 

|Buff em
Sub Buff_Player(Player, Buff, Request)

  /declare RandomWait int local   0 

  |Is player in range? ${Spell[name].Range} just works if spell already is memmed 
  /if (${Spawn[${Player}].Distance} > 100) { 
     /echo # Debug: ${Player} asked for buff but is oor (${Spawn[${Player}].Distance}) 
     /docommand /tell ${Player} oor 
     /return 
  } 

  /echo # Debug: Buffing ${Player} with ${Buff} (${Request}) 

  /varset RandomWait ${Math.Rand[4]} 
  /varcalc RandomWait ${RandomWait}+1 
  |/echo Paranoia - Waiting ${RandomWait} seconds before resuming 
  /delay ${RandomWait}s 

  /if (!${Me.Gem[${Buff}]}) { 
     /memspell 1 "${Buff}" 
  } 

  /target pc ${Player} 
   
  :loop 
  /if (!${Me.SpellReady[${Buff}]}) { 
     /goto :loop 
     /delay 5 
  } 

  /if (${Me.Spawn.Sitting}) { 
     /echo # Sitting, standing up 
     /stand 
     /delay 2s 
  } 

  /call Cast "${Buff}" 
  /echo # Debug: Done buffing ${Player} 
/return



|Handle incomming command 
Sub Event_HandleBuffRequest(FullText, Player, Text) 

   /declare Buff          string local 
   /declare thebuff       string local 
   /declare AllowedBuff   int    local NOT_FOUND 
   /declare RequestedBuff string local 
   /declare count         int    local 0

   /if (${Spawn[${Player}].GM}) { 
      /echo ***** GM ALERT! *****
      /echo # GM ${Player} told me: ${Text}, exiting! 
      /endmacro 
   } 

   |Is player in zone? 
   /if (!${Spawn[${Player}].ID}) { 
      |/echo # Debug: ${Player} not in zone said: ${Text} 
      /return 
   } 

   |Checking if player is in specified guild, or in white-list 
   /if (${Spawn[${Player}].Guild.NotEqual[GUILD_NAME]}) { 

      /varset AllowedBuff ${Ini[BUFFBOT_INI, AllowedPlayers, ${Player}, BOOL_FALSE]} 

      /if (${AllowedBuff} == BOOL_FALSE) { 
         /echo # Debug: Ignoring request '${Text}' from ${Player} 
         /return 
      } 
      /echo # Debug: ${Player} is white listed (${AllowedBuff}) 
   } 

   |Is player in line of sight? 
   |/if (!${Spawn[${Player}].LineOfSight}) { 
   |   /echo # Debug: ${Player} asked for buff but is not in LoS 
   |   /return 
   |}

   /varset RequestedBuff ${Text} 
   /if (${RequestedBuff.Right[50].Equal["Sorry, I am A.F.K. (Away From Keyboard) right now."]}) /varset RequestedBuff ${RequestedBuff.Left[-50]} 
    
   /if (${RequestedBuff.Left[12].Equal["can i get a "]})   /varset RequestedBuff ${RequestedBuff.Right[-12]} 
   /if (${RequestedBuff.Left[10].Equal["can i get "]})      /varset RequestedBuff ${RequestedBuff.Right[-10]} 
   /if (${RequestedBuff.Right[13].Equal[" when you can"]})   /varset RequestedBuff ${RequestedBuff.Left[-13]} 
   /if (${RequestedBuff.Right[3].Equal[" ty"]})         /varset RequestedBuff ${RequestedBuff.Left[-3]} 
   /if (${RequestedBuff.Right[4].Equal[" plz"]})         /varset RequestedBuff ${RequestedBuff.Left[-4]} 
   /if (${RequestedBuff.Right[4].Equal[" pls"]})         /varset RequestedBuff ${RequestedBuff.Left[-4]} 
   /if (${RequestedBuff.Right[5].Equal[" pls!"]})         /varset RequestedBuff ${RequestedBuff.Left[-5]}
   /if (${RequestedBuff.Right[5].Equal[" plZ!"]})         /varset RequestedBuff ${RequestedBuff.Left[-5]}
   /if (${RequestedBuff.Right[4].Equal[" wmp"]})         /varset RequestedBuff ${RequestedBuff.Left[-4]}
   /if (${RequestedBuff.Right[8].Equal[" please!"]})      /varset RequestedBuff ${RequestedBuff.Left[-8]} 
   /if (${RequestedBuff.Right[7].Equal[" please"]})      /varset RequestedBuff ${RequestedBuff.Left[-7]} 
   /if (${RequestedBuff.Right[4].Equal[" wmp"]})         /varset RequestedBuff ${RequestedBuff.Left[-4]} 
   /if (${RequestedBuff.Right[3].Equal[" =)"]})         /varset RequestedBuff ${RequestedBuff.Left[-3]} 
   /if (${RequestedBuff.Right[3].Equal[" :)"]})         /varset RequestedBuff ${RequestedBuff.Left[-3]} 
   /if (${RequestedBuff.Right[2].Equal[" )"]})         /varset RequestedBuff ${RequestedBuff.Left[-2]} 
   /if (${RequestedBuff.Right[1].Equal["?"]})            /varset RequestedBuff ${RequestedBuff.Left[-1]} 
    
   /if (${RequestedBuff.Length} < 1) { 
      /echo # Debug: too short text 
      /return 
   } 
    
   /if (${RequestedBuff.Length} > 25) { 
      /echo # Debug: too long text 
      /return 
   } 

   |Process buff request 
   /echo # Debug: looking for ${RequestedBuff} 
   /varset Buff ${Ini[BUFFBOT_INI, ${Me.Class.Name}, ${RequestedBuff}, NOT_FOUND]} 
   /echo # Debug: result ${Buff}

   /if (${String[${Buff}].Equal[NOT_FOUND]}) { 
      /echo # ${Player} asked for unknown buff: ${Text} 
      |/docommand /tell ${Player} unknown buff 
      /return 
   }
 
   /if (${Buff.Equal["ALL"]}) {
      /varset count ${Ini[BUFFBOT_INI, ${Me.Class.Name}, buffcount, NOT_FOUND]} 
      /if (${String[${count}].Equal[NOT_FOUND]}) { 
         /echo # buffcount not found in INI file 
         /return 
      }
 
      /echo # Debug: multi buff request received, ${count} buffs incoming
      /docommand /tell ${Player} inc 

      /if (${String[${Buff}].NotEqual[NOT_FOUND]}) { 
         /if (${count} > 0) {
            /varset thebuff ${Ini[BUFFBOT_INI, ${Me.Class.Name}, buff1, NOT_FOUND]} 
            /call Buff_Player ${Player} "${thebuff}" "${Text}"
         }
         /if (${count} > 1) {
            /varset thebuff ${Ini[BUFFBOT_INI, ${Me.Class.Name}, buff2, NOT_FOUND]} 
            /call Buff_Player ${Player} "${thebuff}" "${Text}"
         }
         /if (${count} > 2) {
            /varset thebuff ${Ini[BUFFBOT_INI, ${Me.Class.Name}, buff3, NOT_FOUND]} 
            /call Buff_Player ${Player} "${thebuff}" "${Text}"
         }
         /if (${count} > 3) {
            /varset thebuff ${Ini[BUFFBOT_INI, ${Me.Class.Name}, buff4, NOT_FOUND]} 
            /call Buff_Player ${Player} "${thebuff}" "${Text}"
         }
         /if (${count} > 4) {
            /varset thebuff ${Ini[BUFFBOT_INI, ${Me.Class.Name}, buff5, NOT_FOUND]} 
            /call Buff_Player ${Player} "${thebuff}" "${Text}"
         }
         /if (${count} > 5) {
            /varset thebuff ${Ini[BUFFBOT_INI, ${Me.Class.Name}, buff6, NOT_FOUND]} 
            /call Buff_Player ${Player} "${thebuff}" "${Text}"
         }
         /if (${count} > 6) {
            /varset thebuff ${Ini[BUFFBOT_INI, ${Me.Class.Name}, buff7, NOT_FOUND]} 
            /call Buff_Player ${Player} "${thebuff}" "${Text}"
         }
	  }
      /return
   }

   /docommand /tell ${Player} inc 

   /call Buff_Player ${Player} "${Buff}" "${Text}"

/return 



sub Main 

   /declare SpellCanni outer "Pained Memory" 
   /declare SpellHoT   outer "Breath of Trushar" 
   /declare CanniGem   outer gem3 
   /declare HoTGem     outer gem1 

   /echo mini-buffbot 2.0 started 

   /tgb on 

   :MyMainLoop 
   /doevents 

   | Cann for mana if we are Shaman
   /if (${Me.Class.Name.Equal[Shaman]}) { 
      /if (${Me.PctMana} < 70 && ${Me.CurrentHPs} > 2600 && ${Me.AltAbilityReady[47]}) { 
         /target clear 
         /delay 2 
         /target myself 
         /call cast ${SpellHoT} ${HoTGem} 5s 
         /gsay Canni5 
         /aa act Cannibalization 
         /delay 3s 
      } 
      /if (${Me.PctMana} < 70 && ${Me.CurrentHPs} > 2600 && ${Me.SpellReady[${SpellCanni}]}) /call cast ${SpellCanni} ${CanniGem} 6s 
   }

   /delay 1s 
   /goto :MyMainLoop 

/return
buffbot.ini

Code: Select all

[AllowedPlayers] 
1stFriendName=1 
2ndFriendName=1 

[Enchanter]
buffme=ALL
buffcount=5
buff1=Clairvoyance
buff2=Speed of Salik
buff3=Rune of Zebuxoruk
buff4=Levitation
buff5=Everlasting Breath

speed=Speed of Salik
haste=Speed of Salik
salik=Speed of Salik

gspeed=Vallon's Quickening
ghaste=Vallon's Quickening

c=Clairvoyance
C=Clairvoyance
c6=Clairvoyance
C6=Clairvoyance
clairty=Clairvoyance

c3=Kodiac's Endless Intellect
C3=Kodiac's Endless Intellect

mr=Guard of Druzzil
guard=Guard of Druzzil
mresist=Guard of Druzzil

rune=Rune of Zebuxoruk

qrune=Mayhem
minirune=Mayhem

inv=Cloud of Indifference
invis=Cloud of Indifference

lev=Levitation

eb=Everlasting Breath

[Shaman] 
buffme=ALL
buffcount=5
buff1=Wunshi's Focusing
buff2=Spirit of Fortitude
buff3=Spirit of Sense
buff4=Spirit of Might
buff5=Spirit of Perseverance

wunchi=Wunshi's Focusing
wunshi=Wunshi's Focusing 
wunshis=Wunshi's Focusing 
wunshi's=Wunshi's Focusing 
sushi=Wunshi's Focusing 
focus=Wunshi's Focusing 
fokus=Wunshi's Focusing 
7=Wunshi's Focusing 
beg=Wunshi's Focusing
buffs=Wunshi's Focusing
buff=Wunshi's Focusing
focus me bitch=Wunshi's Focusing
W=Wunshi's Focusing
Woushie=Wunshi's Focusing

sta=Spirit of Fortitude 
stamina=Spirit of Fortitude 
fort=Spirit of Fortitude 
fortitude=Spirit of Fortitude 
boar=Spirit of Fortitude
s=Spirit of Fortitude

groupfort=Talisman of Fortitude
gfort=Talisman of Fortitude 

regen=Spirit of Perseverance 
reg=Spirit of Perseverance

dex=Spirit of Daiku
daiku=Spirit of Daiku

might=Spirit of Might 
str=Spirit of Might 
strength=Spirit of Might 

sense=Spirit of Sense 
sos=Spirit of Sense 
agi=Spirit of Sense
agility=Spirit of Sense 

inv=Invisibility 
invis=Invisibility 

fa=Ferine Avatar 
avatar=Ferine Avatar 

heal=Yoppa's Mending

bot=Breath of Trushar
hot=Breath of Trushar 
qheal=Breath of Trushar
hott=Breath of Trushar 

haste=Swift Like the Wind
thaste=Talisman of Alacrity 

tot=Talisman of the Tribunal 
dr=Talisman of the Tribunal
pr=Talisman of the Tribunal
resist=Talisman of the Tribunal
resists=Talisman of the Tribunal
talisman of tribunal=Talisman of the Tribunal
tribunal=Talisman of the Tribunal
trib=Talisman of the Tribunal

sow=Spirit of Bih`Li 
billy=Spirit of Bih`Li 
bihli=Spirit of Bih`Li 

shrink=Shrink 

shrinkall=Tiny Terror

cure=Remove Greater Curse

ios=Infusion of Spirit

lev=Levitation

leo=Spirit of the Leopard
leopard=Spirit of the Leopard

[Cleric]
buffme=ALL
buffcount=2
buff1=Conviction
buff2=Blessing of Devotion

con=Conviction
conv=Conviction
virt=Conviction
hp=Conviction

Sym=Symbol of Balikor
symbol=Symbol of Balikor
bali=Symbol of Balikor
kazad=Symbol of Balikor

bor=Blessing of Devotion
bod=Blessing of Devotion

heal=Pious Light
ch=Complete Healing

[Druid]
buffme=ALL
buffcount=2
buff1=Stealoak Skin
buff2=Protection of Seasons

po9=Steeloak Skin 
pot9=Steeloak Skin 
9=Steeloak Skin 
nine=Steeloak Skin 
pot10=Steeloak Skin 
steeloak=Steeloak Skin 
steelowk=Steeloak Skin 
steeloak skin=Steeloak Skin 
ss=Steeloak Skin 
skin=Steeloak Skin 
steel=Steeloak Skin 
oak=Steeloak Skin 

soe=Spirit of Eagle 
eagle=Spirit of Eagle 
spirit of eagle=Spirit of Eagle 
spirit of eagles=Spirit of Eagle 
foe=Flight of Eagles 
flight of eagle=Flight of Eagles 
flight of eagles=Flight of Eagles 

pos=Protection of Seasons 
season=Protection of Seasons 
seasons=Protection of Seasons 

str=Nature's Might 
natures might=Nature's Might 

eb=Everlasting Breath 
ds=Nettle Shield 
regen=Oaken Vigor 
sow=Spirit of Wolf 
spirit of wolf=Spirit of Wolf 

Posted: Sat May 28, 2005 9:27 am
by gimp
FYI new versions of this script is now included in the krust macro,
in the file gimp_buffrequests.inc, it can be used alone just as the original file

see this thread for download information:
http://www.macroquest2.com/phpBB2/viewt ... c&start=15

please dont post feedback in this thread

Re: autobuff module (was: buffbot)

Posted: Sun Jan 04, 2026 10:09 am
by xyilla

Re: autobuff module (was: buffbot)

Posted: Sun Jan 04, 2026 10:11 am
by xyilla

Re: autobuff module (was: buffbot)

Posted: Sun Jan 04, 2026 10:13 am
by xyilla

Re: autobuff module (was: buffbot)

Posted: Sun Jan 04, 2026 10:14 am
by xyilla

Re: autobuff module (was: buffbot)

Posted: Sun Jan 04, 2026 10:15 am
by xyilla

Re: autobuff module (was: buffbot)

Posted: Sun Jan 04, 2026 10:16 am
by xyilla