Genbot v13.1.5 [Updated 07/11/2004] Invites and Events!

Post your completed (working) macros here. Only for macros using MQ2Data syntax!

Moderator: MacroQuest Developers

theafkxper
a hill giant
a hill giant
Posts: 207
Joined: Sun Sep 08, 2002 6:41 pm

Post by theafkxper » Tue Jun 22, 2004 2:48 am

Line 524 in botspells.inc says "/varstep" where it should be "/varset" (at least i believe that is the intended behavior)

Fred
a lesser mummy
a lesser mummy
Posts: 35
Joined: Mon May 24, 2004 8:53 am

New Feature Request

Post by Fred » Tue Jun 22, 2004 5:45 am

Hi

Thanks for creating/mainting a great macro.

One thing I'd like though, is to be able to debuff mobs.
So /g debuff
and all the bots will cast all their debuffs on my target.

Thanks!

:P
Fred the Nec

sj_digriz
a lesser mummy
a lesser mummy
Posts: 40
Joined: Wed Jun 02, 2004 9:10 am
Contact:

Re: New Feature Request

Post by sj_digriz » Tue Jun 22, 2004 8:02 am

Fred wrote:Hi

Thanks for creating/mainting a great macro.

One thing I'd like though, is to be able to debuff mobs.
So /g debuff
and all the bots will cast all their debuffs on my target.

Thanks!

:P
Genbot only allows you to set up your own shortcuts to either cast spells or click items or use keyboard commands and such. So, unless your debuffs are spells or clicky items you are SOL. :roll:

[shortcuts]
slow=sn Forlorn Deeds
debuff=sn Howl of Tashan

Vexix
Genbot Janitor
Posts: 245
Joined: Sat Apr 17, 2004 10:10 am

Post by Vexix » Tue Jun 22, 2004 8:22 pm

Thanks, Sj. :)

By the way, items (assuming they're equipped) and alts work just fine for shortcuts and debuffs. Also, you can stack commands into a shortcut using |. For example:

debuff=sn item Staff of Temperate Flux|sn alt Some name of alt ability here

--Vexix
Last edited by Vexix on Tue Jun 22, 2004 9:16 pm, edited 1 time in total.

Vexix
Genbot Janitor
Posts: 245
Joined: Sat Apr 17, 2004 10:10 am

Post by Vexix » Tue Jun 22, 2004 9:12 pm

Just a quick note on shortcut usage.
sov=snt Speed of Vallon on NameS
and
/t bot sov on someone
Will cause genbot to try to parse:
snt Speed of Vallon on on someone
Which doesn't work.

Either of the following will work:
sov=snt Speed of Vallon on NameS
/t bot sov someone
Or
sov=snt Speed of Vallon NameS
/t bot sov on someone

--Vexix

Vexix
Genbot Janitor
Posts: 245
Joined: Sat Apr 17, 2004 10:10 am

Post by Vexix » Tue Jun 22, 2004 9:21 pm

Afkexper,

Yup. That should be /varset. Happy to see people are reading through the code! How is the code? Pretty obscure?

--Vexix

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

Post by frabtik » Wed Jun 23, 2004 9:51 pm

A couple things about Genbot.
ChatOut should be changed for mq2irc
botcore.inc

Code: Select all

   } else /if (${ChatIn.Equal[IRC]}) { 
      /i say ${ChatText} 
   } 
Why does SelfEcho change MasterName?

Code: Select all

Sub Event_SelfEcho(string EchoText) 
|  /varset MasterName ${Me.CleanName} 
   /varset EchoText ${EchoText.Right[-13]} 
   /call ExecCommand "${EchoText}" 
/return 
Taunt could use some improvement I been toying around with something like this and seems to be working well. I just added the ToT code and have not tested yet but you get the general idea.

botcombat.inc

Code: Select all

|Testing new taunt code.
|Be nice to see if you have ToT or Raid ToT skill.
|This assumes you do since I never group without it.
   /if (${DoTaunt} && ${Me.AbilityReady[Taunt]}) { 
      /if (${Group}>2) {
         /if (${Me.TargetOfTarget.ID}!=${Me.ID}) {
            /if (${Target.Distance}<20) { 
               /call ChatOut 5 ${MasterName} "Taunting ${Target.CleanName}.
               /doability "Taunt" 
            } 
         }         
      } else {
         /declare TempCalc int local
         /declare HeadingMax int local
         /declare HeadingMin int local
         /varset TempCalc ${Math.Calc[${Me.Heading.Degrees}+180]}
         /if (${TempCalc}>360) /varset TempCalc ${Math.Calc[${TempCalc}-360]}
         /varset HeadingMax ${Math.Calc[${TempCalc}+10]}
         /varset HeadingMin ${Math.Calc[${TempCalc}-10]}
         /if ((${Target.Heading.Degrees}>${HeadingMax})||(${Target.Heading.Degrees}<${HeadingMin})) {
            /if (${Target.Distance3D}<20) { 
               /call ChatOut 5 ${MasterName} "Taunting ${Target.CleanName}.
               /doability "Taunt" 
            } 
         }
      }
   }
Made couple minor changes to the ToT taunt after doing some testing, didn't get to test a lot since I forgot to comment out the old one when I got the updated genbot.
Last edited by frabtik on Sat Jun 26, 2004 11:14 pm, edited 1 time in total.

Vexix
Genbot Janitor
Posts: 245
Joined: Sat Apr 17, 2004 10:10 am

Post by Vexix » Fri Jun 25, 2004 10:01 pm

Frabtik,

The change in MasterName is to make sure that responses go out to the right channel. If you type in /gb exp from the terminal, then you shouldn't have to /tell some other character to give the response.

--Vexix

Vexix
Genbot Janitor
Posts: 245
Joined: Sat Apr 17, 2004 10:10 am

Post by Vexix » Fri Jun 25, 2004 10:01 pm

I'm off for a 10 day holiday. Have fun with Genbot while I'm gone. If you would like to improve genbot, please feel free to post new code or documentation here. I've had a few people mention they were interested in helping with documentation, but haven't seen anything yet, so go ahead an post whatever you have here, and others can comment on it.

I'm disappointed that most of my requests for assistance at the top of this thread have gone unanswered. I have limited time to code, and several of the items I mentioned will make significant improvements to genbot. For example, creating the Do-equip subroutine will enable me to add the code to have unequipped items equipped, cast, and replaced.

If you see something on the list you can do, go for it! Genbot is great, and we can make it even better!

--Vexix

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

Post by frabtik » Sat Jun 26, 2004 11:27 pm

Well I may check into that a little, problem is that after you do a /gb the bot stops responding to the master. Anyway, I was just curious why was all, is a minor detail that is easily fixed by commenting it out and just sending the extra msgs.
Couple other simple things that would be useful would be a configuration for slam and incite, I am toying around with slam some since I don't think it works, tried putting in the number etc which I thought would fix it but if that works a ini setting to set that and one for your aggro spell since not everyone has the 63 one and others have upgrades to incite, I have previously been hardcoding it till now when I finally got to 63 and can use incite now. I gotta admit using it for a melee class it works well and I hate the time I gotta put in now to get it working with new changes etc, kills the playtime and for a melee it mostly works very well right now. Once the general base functions are not giving me fits I will see if I can help with some that stuff though. Seems there is code posted in numerous places to swap items out right now. I use a plugin that works nicely other than having to hard code it since the quotes get stripped etc. Is there any provision at this point to allow the bot to tell the master what buffs it needs etc? For me that about only thing I don't have working well, that and zoning, even using the advpath follow the portals are pretty iffy still but I will be working on getting that to work since it is a real pain always having to switch to the bot to click the tele stones etc. Appretiate all the hard work you done though and don't forget to go have fun with it.

Saelinye
a lesser mummy
a lesser mummy
Posts: 31
Joined: Thu Jun 03, 2004 8:17 am

Equip feature for Genbot

Post by Saelinye » Mon Jun 28, 2004 9:08 am

I havent played with this too much.. Also, I did not design this myself, it was borrowed from the author of spell_routine.

call with
/call swap "itemname"
ex: /call swap "Shrunken Goblin Skull Earring"

Code: Select all

Sub Swap(spellName) 
   /declare slotName int local 
   /declare slotID int local 
   /declare oldSlotID int local

      /if ( ${FindItem[${spellName}].InvSlot}>30 ) {
         /if ( ${FindItem[${spellName}].WornSlot[1]} ) { 
            /varset slotName ${FindItem[${spellName}].WornSlot[1]} 
         } else { 
            /varset slotName pack8 
         } 
         /varset slotID ${InvSlot[${slotName}].ID} 
         /varset oldSlotID ${FindItem[${spellName}].InvSlot.ID} 
         /autoinventory 
         /if ( ${InvSlot[${oldSlotID}].Pack} ) { 
         :open_pack 
            /nomodkey /itemnotify ${InvSlot[${oldSlotID}].Pack} rightmouseup 
            /if ( !${Window[${InvSlot[${oldSlotID}].Pack.Name}].Open} ) /goto :open_pack 
         } 
      :pick_up_item 
         /if ( ${InvSlot[${oldSlotID}].Pack} && !${Window[${InvSlot[${oldSlotID}].Pack.Name}].Open} ) /nomodkey /itemnotify ${InvSlot[${oldSlotID}].Pack} rightmouseup 
         /nomodkey /itemnotify ${InvSlot[${oldSlotID}]} leftmouseup 
         /if ( !${Cursor.Name.Equal[${spellName}]} ) /goto :pick_up_item 
      :exchange_items 
         /nomodkey /itemnotify ${slotID} leftmouseup 
         /if ( !${Me.Inventory[${slotID}].Name.Equal[${spellName}]} ) /goto :exchange_items 
         /if ( ${InvSlot[${oldSlotID}].Pack} ) { 
         :close_pack 
            /nomodkey /itemnotify ${InvSlot[${oldSlotID}].Pack} rightmouseup 
            /if ( ${Window[${InvSlot[${oldSlotID}].Pack.Name}].Open} ) /goto :close_pack 
         }
      :drop_item 
      /if ( ${InvSlot[${oldSlotID}].Pack} && !${Window[${InvSlot[${oldSlotID}].Pack.Name}].Open} ) /nomodkey /itemnotify ${InvSlot[${oldSlotID}].Pack} rightmouseup 
      /nomodkey /itemnotify ${oldSlotID} leftmouseup 
      /if ( ${Cursor.ID} ) /goto :drop_item 
      /if ( ${InvSlot[${oldSlotID}].Pack} ) { 
      :close_pack2 
         /nomodkey /itemnotify ${InvSlot[${oldSlotID}].Pack} rightmouseup 
         /if ( ${Window[${InvSlot[${oldSlotID}].Pack.Name}].Open} ) /goto :close_pack2 
      } 
   } 
/return 
Last edited by Saelinye on Mon Jun 28, 2004 12:21 pm, edited 1 time in total.

Saelinye
a lesser mummy
a lesser mummy
Posts: 31
Joined: Thu Jun 03, 2004 8:17 am

Alternatively, this will equip item and cast and replace.

Post by Saelinye » Mon Jun 28, 2004 9:09 am

Again, borrowed from swapcast author. This is tested and works great.

Code: Select all

Sub SwapCast(item,equipslot) 
   /declare inventoryslot int local 
   /declare pack local 
   /declare packslot int local 
   /declare leaveopen int local 1 
   /declare packnumber int local 0 
   /declare leavetwisting int local 0 

   /if (!${Defined[item]}) /goto :end 
   /if (${Twisting}) { 
      /twist stop 
      /varset leavetwisting 1 
   } 
   :stopsingingdelay 
   /if (${Me.Casting.ID}>0) { 
      /stopsong 
      /goto :stopsingingdelay 
      } 
   /varset inventoryslot ${FindItem[${item}].InvSlot} 
   /if (!${inventoryslot}) /goto :notfound 
   :packcountloop 
   /if (${inventoryslot}>250 && ${inventoryslot}<331) { 
      /varset packnumber ${Math.Calc[${packnumber}+1]} 
      /varset inventoryslot ${Math.Calc[${inventoryslot}-10]} 
      /goto :packcountloop 
      } 
   /if (${packnumber} > 0) { 
      /varset pack pack${packnumber} 
      /varset packslot ${Math.Calc[${inventoryslot}-240]} 
      /goto :foundit 
      } 
   :notinpack 
      /call CastItem ${inventoryslot} 
      /goto :end 
   :foundit 
      /if (!${Window[${pack}].Open}) { 
         /nomod /itemnotify ${pack} rightmouseup 
         /varset leaveopen 0 
         } 
      /call WaitCursor ${packslot} ${pack} 
      /if (${String[${equipslot}].Find[null]}) { 
         /if (${Cursor.WornSlots}>0) { 
            /varset equipslot ${Cursor.WornSlot[1]} 
         } else { 
               /varset equipslot pack1 
         } 
      } 
      /call WaitCursor ${equipslot} 
      /call CastItem ${equipslot} 
      /call WaitCursor ${equipslot} 
      /call WaitCursor ${packslot} ${pack} 
      /if (${leaveopen} == 0) /nomod /itemnotify ${pack} rightmouseup 
      /goto :end 
   :notfound 
      /echo ${item} not found in inventory. 
   :end 
   /if (${leavetwisting} == 1) /twist start 
/return 

Sub CastItem(slot) 
   /nomod /itemnotify ${slot} rightmouseup 
   /echo Casting the effect on your ${InvSlot[${slot}].Item.Name} 
   :castloop 
|| special case composer greaves don't ever stop casting 
      /if (${InvSlot[${slot}].Item.Name.Find["Composers Greaves"]}) { 
         /delay 12 
         /stopsong 
      } 
      /if (${Me.Casting.ID}>0) /goto :castloop 
/return 

Sub WaitCursor(slot, pack) 
   /declare item local 
   /declare timeout timer 30 
   /varset item ${Cursor.ID} 
   /if (${Defined[pack]}) /goto :waitloop2 
   :waitloop1 
   /nomod /itemnotify ${slot} leftmouseup 
   /if ((${item} == ${Cursor.ID}) && (${timeout} > 0)) /goto :waitloop1 
   /goto :donewaiting 
   :waitloop2 
      /nomod /itemnotify in ${pack} ${slot} leftmouseup 
   /if ((${item} == ${Cursor.ID}) && (${timeout} > 0)) /goto :waitloop2 
   :donewaiting 
/return

mackster
a ghoul
a ghoul
Posts: 95
Joined: Mon Sep 09, 2002 3:02 pm

Post by mackster » Mon Jun 28, 2004 5:10 pm

how do you get this macro to recast a spell that is resisted? i remember in the previous version you could change a line of code, but i haven't found it in this one.

also, how do you cast an item? there was an itemcast command in the old version but i havent found out how to use clickies with this one.

thanks

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

Post by frabtik » Wed Jun 30, 2004 11:25 am

itemcast <itemname> - Commands bot to trigger the specified item.
sn <spell|item> - Commands bot to cast the specified spell on master's target.
<spell> - will cast <spell> on master's target.
<item> - will right click item on master's target.
snt <spell|item> on <target> - Commands bot to cast <spell|item> ON <target>,if "on <target>" is not specified, it will cast on bot's target
<spell> - snt brell's stalwart shield on PlayerName
<item> - snt Regent Symbol of Innoruuk on NPCName
You tried looking at the docs? This is just cut and paste from the genbot.txt file, you tried looking at it or just here to have me read it for you?

draco
a ghoul
a ghoul
Posts: 145
Joined: Thu Jan 29, 2004 7:06 pm
Contact:

Post by draco » Wed Jun 30, 2004 5:01 pm

Note: when copying and pasting > and < have been replaced with > and < respectively. You will probably have to do a global replace in your editor. See todays announcement.

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