I can pritty much figure out how to add something, like a mob to the ini list, but how would you make it check against the list for the mob?
Use the Ini TLO.
${Ini[filename,section,key,default]} returns a string.
Macro
The NULL is implied by default even if you don't specify it.
Wed Jun 06, 2012 9:31 pm
Senior Project Member
Uggg
ok been playing with a test macro:
Macro
to try to understand how to use ${Ini}
and
/ini
I can type in MQ2 /ini "Moblist.ini" "ImmuneList" "AKewKey" "${Target}" and get the result of what I have targeted put into an ini file but that is for a single entry.
I see in the:
Macro
what is being done but not sure what values in the /ini command is being used to create the entries.
Sorry, hard to understand when your not 100% sure how it works. I can make sence of it just not sure how it is done (sucks not ever righting code before and trying to figure it out)
it's funny, when that light bulb comes on you feel so stupid for seeing how simple it actualy is... but it is untill that light bulb finaly comes on that the problem seems alot more complex then what it actualy is.
Thu Jun 07, 2012 3:41 pm
Your test macro uses ${Target.DisplayName} to check for the /echo but places mobs in the ini using ${Target}. The echo won't fire because the two should give different results for the same mob.
Using "" for a value might be telling MQ2 to delete that key rather than place it there with an empty value (INI file maintenance). Try putting something, anything not an empty string, there.
/ini "MobList.ini" "${Zone.ID}" "${Target}" ""
Using "" for a value might be telling MQ2 to delete that key rather than place it there with an empty value (INI file maintenance). Try putting something, anything not an empty string, there.
Thu Jun 07, 2012 7:43 pm
Senior Project Member
Sorry. I haven't been paying enough attention.
Both the ${Ini[]} and /ini commands are extremely versatile. They can do a whole lot, but they also have to match. I haven't been giving examples that match.
The following are examples of matching ${Ini[]} and /ini commands (crossing my fingers this time).
Play around with echo statements to see what the ${Ini[]} command will return.
/echo ${Ini[MobList.ini]}
/echo ${Ini[MobList.ini, ${Zone.ID}]}
/echo ${Ini[MobList.ini, ${Zone.ID}, ${Target.CleanName}]}
/echo ${Ini[MobList.ini, ${Zone.ID}, ${Target.CleanName}, NULL]}
/echo ${Ini[MobList.ini, ${Zone.ID}, ${Target.Name}, NULL]}
Both the ${Ini[]} and /ini commands are extremely versatile. They can do a whole lot, but they also have to match. I haven't been giving examples that match.
The following are examples of matching ${Ini[]} and /ini commands (crossing my fingers this time).
Macro
Macro
Macro
Play around with echo statements to see what the ${Ini[]} command will return.
/echo ${Ini[MobList.ini]}
/echo ${Ini[MobList.ini, ${Zone.ID}]}
/echo ${Ini[MobList.ini, ${Zone.ID}, ${Target.CleanName}]}
/echo ${Ini[MobList.ini, ${Zone.ID}, ${Target.CleanName}, NULL]}
/echo ${Ini[MobList.ini, ${Zone.ID}, ${Target.Name}, NULL]}
Fri Jun 08, 2012 12:17 am
Senior Project Member
EURICA!
Ok found what works. Using the Ini coding and playing around with it, I have found I think a perfect combanation to play around with in the main enchanter macro.
The way this is it does 2 things:
1st
It will check for the mobs name in the ini. If it isn't there it will continue without any [MQ] messages or errors. I played around with different ways to do it and most of the other ways I tried would either give off an error if the mob wasn't in the list or keep repeating a [MQ] of NULL or something.
2nd
ok figures.. daughter calls and I lose my train of thought. Um I guess the other thing was I figured out how to edit the /ini code to make the list how ever I want.
Point is I think this bit of code, now that I understand it better, helps greatly in NOT trying to mezz mobs that are immune. Also I thought about adding a "MaxLevel" to the code so it doesn't try mezzing mobs that resist because they are just to high level. I will play around with it when I have it this perfected some.
New Code:
Macro
This was for the test code... now to just apply it to the Echanter code and start testing.
Fri Jun 08, 2012 11:09 am
In failure lies success
Well after a few posts that I have deleted about my loop I was trying to create I decided to scrap it. It did what it was suppose to do but when there where no mobs in range it would get stuck then if mobs meeting the critiria were in range it would still be stuck. I tried many different ways to write it but just couldn't get it. After another post on another forum I am a member of from someone with a little more technical expertice then I, I see I was on the right track with what I was trying to create but this snippet is much better written then what I was trying to come up with. I don't take credit for this one but it was written to solve this loop topic.
Macro
I have edited it a little for testing. It works exactly the way I'm needing it to. My /if conditions can be added to it easily and if you get out of range it just stops targeting. If you get back into range it continues to cycle. PLUS it is a loop in it's self so it should be able to be merged into an existing macro.
I will continue the editing and testing and will post results....
UPDATE
Ok after a many fail, fail, fail and fail.. I finaly found something that works.
Macro
This bit of code works well.
It will cycle through targets, Mezz any that meets the conditions, Not mezz mobs that meets those conditions and remezzes mobs if they break mez. Right now you can adjust the range and MobHPs (won't mezz if HPs are under but you can adjust how you want that to work as well) and other things.
There is only one thing I haven't been able to figure out so far. How to make the tanks target an exception to mezzing. I have been playing with the /alert command. I can check what target is the tanks target easy enough. just not adding the alert conditions in the right place I think. Not real familuar yet with the alert. For now if the mob gets under 90% HPs she won't try to mezz it. That would work in most cases except of you have DS on or have done damage to other mobs which I'm a little iffy about.
Sat Jun 09, 2012 2:04 pm
Ok I think I got it!
Ok, After some work I finaly got it.
It does everything you need it to do as far as mezzing from what I can see. I have been running it through some testing. I still have not taken it into the field for major testing, only stuff in an easy areas so far. BUT so far it's working great. Now keep in mind I usualy start my macros when I get where I'm going and/or am ready to start fighting. It may or maynot mez stuff that wonders into it's radius. Still haven't gotten that far on testing yet. That is why I have it's radius low, but it can be adjusted as needed. I have started incorperaiting it into my echanters main code as an event. I may change this though I will play around with it. Not sure if I like it running all the time due to the fact it "may" mez things that just wonder into it's radius. If I set it as an event where someone in the group says "mez" then I only have to set up a simple hot butting for it and hit it when I need things mezzed. I can also set up an event to run this when it detects a mez broken which would be nice also.
Anyway, I figured out how to make it check Tanks (or assists or group members) target. I figured out how to use NetBots. Handy little plugin. The only thing you have to change is this part:
Macro
Need to change "Backbreaker" to who ever you want that will be fighting the mobs.
This is the working product so far:
Enchanter Mez
Macro
Have fun =)
Fri Jun 15, 2012 6:20 am