• You've discovered RedGuides 📕 an EverQuest multi-boxing community 🛡️🧙🗡️. We want you to play several EQ characters at once, come join us and say hello! 👋
  • IS THIS SITE UGLY? Change the look. To dismiss this notice, click the X --->

Macro help (1 Viewer)

armysoldier

Well-known member
Joined
Jun 26, 2005
RedCents
101¢
Rich (BB code):
Sub Main
    /declare CombItemName string outer
    /declare ItemTo string outer

    /varset CombItemName "FPB"
    /varset ItemTo "Fine Plate Breastplate"

/echo ${ItemTo}

/echo ${ItemTo.Equal["Fine Plate Breastplate"]}

/echo ${ItemTo.Equal[Fine Plate Breastplate]}

    /if (${ItemTo.Equal[Fine Plate Breastplate]}) /echo FPB

    /if (${ItemTo.NotEqual[Fine Plate Breastplate]}) /echo  not FPB

/return


This should

echo "Fine Plate Breastplate"
echo true
echo false
echo FPB


But instead i get


echo "Fine Plate Breastplate"
echo false
echo false
echo not FPB

Can someone tell me WTF i am doing wrong.. i am fustrated as hell ..

and with out a string comparison ... i am Foooked


thanks

ARMY
 
What happens when you do /varset ItemTo Fine Plate Breastplate
?

I've been doing a lot of these types of comparisons in my macros, but with mob types/names, etc. and I definitely feel your pain. Sometimes it takes a while to figure out what will parse correctly.

My guess is that the first echo always does it right because ItemTo is "Fine Plate Breastplate" in your example. That would explain why the third echo returns the correct value also and the /if statements are parsing normally as well, you have ItemTo set to "Fine Plate Breastplate" not Fine Plate Breastplate.

What I do not understand is why the second echo is returning false, it should be true. My guess is the quotes are f'n it up. I'd try your variable setting line with no quotes around the value and see what happens.

Good luck!
 
yeah thats my problem .. one of those should return True.. and neither one is ..

and i don't understand why?

anyone have an idea?

its making my brain really hurt!!!

ARMY
 
Have you tryed removing the " " they are not needed according to the wikki, but the logic looks good... sorry i don't have a better solution. :(
 
i posted on MQ forum .. and DKAA told me to take the "" out of the variale declares...

so i will go back and mod my codes to remove those and put them in else where if "" are needed

like for buy or sell functions

8-)

ARMY
 
try this
Rich (BB code):
Sub Main
	/declare CombItemName string outer
	/declare ItemTo string outer
 
	/varset CombItemName "FPB"
	/varset ItemTo "Fine Plate Breastplate"
 
/echo ${ItemTo}
 
/echo ${FindItem[${ItemTo}]}
 
/echo !${FindItem[${ItemTo}]}
 
 
 
/if (${FindItem[${ItemTo}].ID}) /echo FPB
 
/if (!${FindItem[${ItemTo}].ID}) /echo not FPB
 
/if (${FindItem[Fine Plate Breastplate].ID}) /echo FPB
 
/if (!${FindItem[Fine Plate Breastplate].ID}) /echo not FPB
 
/return
 
Macro help

Users who are viewing this thread

Back
Top