Request for foraging macro

Got a cool macro idea? Wanna request a macro? Here is the place for you!

Moderator: MacroQuest Developers

reaver
decaying skeleton
decaying skeleton
Posts: 1
Joined: Wed Apr 28, 2004 5:28 pm

Request for foraging macro

Post by reaver » Wed Apr 28, 2004 5:31 pm

hi anyone got a simple foraging macro for a druid. don't want or need any of the aa abilities included. I just want a macro that I can run to leave foraging to get my skill up and inventory all or most of the stuff.

Thanks Reaver

User avatar
Fuergrissa
a grimling bloodguard
a grimling bloodguard
Posts: 607
Joined: Mon Dec 08, 2003 3:46 pm
Location: UK

Post by Fuergrissa » Wed Apr 28, 2004 5:56 pm

try Macro Depot 22 messages down or just click here
http://macroquest2.com/phpBB2/viewtopic.php?t=6621

But with new MQ2DataVars most macros will be broken again for a while.

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

Post by Mckorr » Wed Apr 28, 2004 7:14 pm

Actually I wrote this today. On my other system, will post it later.

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

Post by Mckorr » Thu Apr 29, 2004 11:13 am

Code: Select all

sub Main
	/sit off
	:MainLoop
		/if (${String[${Cursor}].NotEqual[Null]}) /autoinv
		/if (${String[${Cursor}].NotEqual[Null]}) /goto :CursorLoop
		/if (${Me.AbilityReady["Forage"]}) /doability "Forage" 

		:CursorLoop
			/if (${String[${Cursor}].NotEqual[Null]}) /autoinv 
			/if (${String[${Cursor}].NotEqual[Null]}) /goto :CursorLoop
		/goto :MainLoop
/endmacro

s16z
a ghoul
a ghoul
Posts: 97
Joined: Thu Apr 01, 2004 12:03 pm

Post by s16z » Thu Apr 29, 2004 11:29 am

Instead of

Code: Select all

(${String[${Cursor}].NotEqual[Null]})
You could use

Code: Select all

(${Cursor.ID})

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

Post by Mckorr » Thu Apr 29, 2004 11:56 am

Thanks. I'm still learning the new format. Stole that part from one of Khitain's tradeskill macros.

ml2517
a grimling bloodguard
a grimling bloodguard
Posts: 1216
Joined: Wed Nov 12, 2003 1:12 am

Post by ml2517 » Thu Apr 29, 2004 1:54 pm

Yes avoid every comparing against NULL it "gives up" sometimes earlier in the ${String process if it encounters a NULL.

In the case you listed here .ID is the best bet.

I've also stayed away from using the NotEqual because of the NULL issue when testing for false conditions with strings. I just do something like this now:

Code: Select all

/if (!${String[Hi there].Arg[2].Equal[there]) {
    /echo It didn't equal there.
}