dynamic macros?

Need some help with that macro you're working on or aren't quite sure how to get your macro to do something? Ask here!

Moderator: MacroQuest Developers

User avatar
Curious
a ghoul
a ghoul
Posts: 88
Joined: Wed Aug 27, 2003 5:19 am

dynamic macros?

Post by Curious » Tue Oct 07, 2003 9:27 am

What's the best way of updating a macro mid-execution?

Would like to modify a mob list while the macro is still running. The two ways I can think of would be to either stop and re-start the macro after the change, or to have a chat event that looks for something like:
You say: add "orc pawn"
which seems like a stupid move.

Mckorr
Developer
Developer
Posts: 2326
Joined: Fri Oct 18, 2002 1:16 pm
Location: Texas

Post by Mckorr » Tue Oct 07, 2003 10:00 am

Pause the macro, type /add alert # npc orc, unpause?
MQ2: Think of it as Evolution in action.

FlashG
Contributing Member
Contributing Member
Posts: 104
Joined: Thu Jul 11, 2002 6:38 pm

tip

Post by FlashG » Tue Oct 07, 2003 1:14 pm

Though not directly related, using the /varset command to control program flow and varible that the user may want to change is a usefull idea. /echo what varible does what so the user knows what vairble does what.

Though untested /varset v1 "uber_mob_01" then use v1 in the program. No need to pause or stop the program.

Flash

User avatar
Curious
a ghoul
a ghoul
Posts: 88
Joined: Wed Aug 27, 2003 5:19 am

Post by Curious » Tue Oct 07, 2003 8:15 pm

That's sweet! Just to make sure I understand correctly, I can type at the command line (chat window):

Code: Select all

/varset NewMobToHunt "Orc Pawn"
or
/ini INIFile MobsToKill OrcPawn "Orc Pawn"
while the macro is still running and the variable/ini file will be updated and the changes will be reflected in the running macro?

Valerian
a grimling bloodguard
a grimling bloodguard
Posts: 709
Joined: Sun Jul 28, 2002 3:29 am

Post by Valerian » Tue Oct 07, 2003 10:47 pm

with /varset, yes. with /ini, maybe not -- that would depend on how the macro is written. ini = initialization... most people use ini files to initialize variables, and then forget about it... if the macro is made to read from the ini every time it does something, then that would work.