• You've discovered RedGuides, an EverQuest multi-boxing and scripting community 🧙‍♀️⚙️. We want you to play several EQ characters at once, come join us and say hello! 👋

  • A TLP without truebox has thawed (Very Vanilla ready)
    Frostreaver

Very Vanilla 09/17/2018 - Live server #bind fix. Macros will break, please test!

Status
Not open for further replies.

Redbot

💻❤️
Moderator
Joined
Oct 15, 2004
RedCents
104,028¢
Pronouns
He/Him
Welcome to Very Vanilla - bind fixed edition!

This is an alpha compile, not ready for normal use. While it will greatly reduce CPU usage and improve macro performance, it will also break many macros.

If you have time, please help us out by testing your favorite macros and reporting any issues.



to fix an old macro add the word #warning at the top of the macro, like where #turbo is
typing /invoke ${Macro.Undeclared} while a macro is running will also display a list of all errors



18 Sep 2017 by eqmule
Fixed an infinite loop bug and a variable parse bug in Eval functions. -cred bug report: creamo
Eval functions that take multiple arguments MUST separate those with comma(s) from now on
Example: (run with a cleric, war or shaman)
Rich (BB code):
  Sub Main
	/declare c_argueString string outer shm clr war
	/declare ChatSender string local ${Me} 

	/if (!${checkbot["shm war clr", ${ChatSender}]}) { <-NOTE the COMMA
		/echo ${Time} Only Func3: FALSE, this should be TRUE
	} else {
		/echo ${Time} Only Func3: TRUE, this should be TRUE
	}
  /return

  Sub checkbot(selectedBots, chatSender)
    /declare botSelected bool local FALSE
	/echo ${Time} in Sub checkbot selectedBots=${selectedBots} chatSender=${chatSender}
    /if (${Select[${Me.Class.ShortName},${selectedBots}]}) /varset botSelected TRUE
  /return ${botSelected}

17 Sep 2017 by eqmule
- Fixed ${Me.GukEarned}, ${Me.MMEarned}, ${Me.RujEarned}, ${Me.TakEarned}, ${Me.MirEarned} and ${Me.LDoNPoints}
- Added a new TLO PointMercant it only have one member : Item which is a pPointMerchantItemType.
The pPointMerchantitemType has the following members: Name, ItemID, Price, ThemeID, IsStackable, IsLore, RaceMask, ClassMask, bCanUse
Usage:
/echo ${PointMercant} returns true if the LDON Mercant window is open and FALSE if not.
/echo ${PointMercant.Item[1].Price} OR /echo ${PointMercant.Item[Ebon Hammer].Price}
returns the Price for index 1 or whatever index Ebon Hammer is in if you do it by name.
etc.

15 Sep 2017 starring rswiders as "the captain", eqmule as "crew member number 6" and special guest star: eqholic
- Updated to handle the new SPA's
- Fixed a bug in /next not taking its argument into account for nested for loops.
- Fix for labels
- Fixed the CSIDLWND struct (the SIDL define...) so since we have never had this right it was time, but note that
if your plugin uses stuff like: pwnd->SidlText and its NOT an actual CSidlScreenWnd then you need to change it to whatever window it actually is.
I guess questions about this should be directed to me (eqmule)

plugins changed outside of core are attached here:
http://www.macroquest2.com/phpBB3/viewtopic.php?f=29&t=11451&p=174467#p174467
MQ2AutoAccept,MQ2Rez

14 Sep 2017 by redguides
- Please report broken macros in the macro forum, this update will break many.
- New Plugin! MQ2FindItem (Sym) - type "/finditem name" with a merchant window open, and it will select that item.
- KissAssist 10.0.5 (Maskoi, TreeHuginDruid, ctaylor22) - Updated for new bind/warning changes
- Ninjadvloot 6.0.7 (Maskoi) - Updated for new bind/warning changes

14 Sep 2017 by eqmule
- Updated for TEST
- Fixed ${Familiar[x].} it will return familiars and not illusions now...
-
- Fixed a bunch of window structs that we where completely misusing anyway.
this could require some plugin changes, contact me for help if you get errors.
-
- Fix: Variables that are undeclared but supplied as paramters now default to an actual NULL or 0 not the string "NULL"
-
- Inspecting the Blessed Spiritstaff of the Heyokah will no longer ctd you.
- Added Math.Clamp ${Math.Clamp[Min, N, Max]} will clamp N between Min and Max. - cred derple
Example:
${Math.Clamp[1, 15, 30]} => 15
${Math.Clamp[20, 15, 30]} => 20
${Math.Clamp[1, 15, 10]} => 10
Practical usage:
/bct ranger //stick id ${Target.ID} ${Math.Clamp[25,${Target.Distance},150]}
this will make your ranger stay put if he is already between 25-150 meters away
otherwise it will move him at most 150 away and at least 25 away.

12 Sep 2017 by eqmule and eqholic
All plugin sources for this zip are attached to this post:
http://www.macroquest2.com/phpBB3/viewtopic.php?f=29&t=11451&p=174415#p174415
Changed MQ2MoveUtils to save stuff faster.
MQ2ChatWnd got a new tlo /echo ${ChatWnd.Title}
MQ2ChatWnd got a new command /setchattitle
MQ2Melee updated - it has flags for down and holyshits called downflag0-60 and holyflag0-60
you SHOULD set those flag to 2 if you parse ANY macro variables.
Example:
Rich (BB code):
  downflag0=2
  downshit0=/if (${Macro.Paused}) /echo ${Macro} is PAUSED!
MQ2Hud now updated with a new type HUDTYPE_MACRO which is 16
This means you can now set the type to any combination of 1 2 4 8 and 16
see http://www.macroquest2.com/wiki/index.php/MQ2HUD for more info.
Basically using a hud that tries to parse variables that are used in macros, before they are declared will fail.
This new flag lets mq2hud know to not even try unless its set.

Adding events from a macro will now also automatically /declare variable as outer if used.
Example: #Event Burn "[MQ2] |${BurnText}|"
As you can see this event uses the variable ${BurnText} and it will therefor /declare it as well.
This means you can remove /declare BurnText in your Sub Main since adding the event did it for you already.

Added ${Macro.IsOuterVariable[xxx]} which returns TRUE/FALSE, it checks if a outer variable exists. (read is declared)
I would recommend NOT using this in macros unless its for debug purposes because it can get quickly get expensive in terms of cpu cycles.

Added ${Macro.IsTLO[xxx]} which returns TRUE/FALSE, it checks if a Top Level Object exists. This should be faster than checking if a plugin is loaded. *should*
Usage:
Rich (BB code):
    /if (${Macro.IsTLO[Melee]}) {
        /echo yes there is a Melee Top Level Object loaded...
		/echo this means I CAN actually do stuff with it without it throwing the Undeclared warning:
		/delay 25 !${Melee.Combat}
    } else {
        /echo no there is no such TLO, maybe you should load mq2melee?
		/end
    }

07 Sep 2017 by eqmule
- using namespace std; has been removed from mq2main.h
THIS MEANS your plugins will ERROR!
To fix: Find #include "../MQ2Plugin.h" in your plugin and add using namespace std; under it.
Example:
Rich (BB code):
	#include "../MQ2Plugin.h"
	using namespace std;
- The reason for that change is that right now we litter ALL projects with the std namespace and it is just not good.
Let everyone that needs that namespace use it in their own projects from now on.
-
- #bind(s) are now fixed and won't screw up the macrostack anymore.
- Todays update is significant because I rebuilt the macro engine to improve performance,
it was well overdue. The biggest change is that gMacroBlock is now a map.
- Undeclared Variables are no longer tolerated, and the macroengine will not run at optimal speed
if they exist. I have added a TLO to check for them because of this and a new macro keyword #warning as well
so there is no good reason to run old macros where these kinds of variables hog cpu power:
AGAIN: IMPORTANT: Undeclared variables will slow down macro performance a LOT if they are used over and over, so, fix your macros.
-
- The Macro TLO has a new method: .Undeclared
Usage: /invoke ${Macro.Undeclared} and it will list all undeclared variables.
- New macro keyword: #warning
add it at the top of your macro, and you will get warnings if there are undeclared variables used in it.
-
- /while loops can now be nested inside /while and /for loops.
- /continue and /break should work properly inside /for loops now.
- /break works in /while loops now.
- /for loops can now have nested /for loops inside them
-
- Updated MQ2Rez and MQ2Cast to not hog the cpu looking up windows over and over.
- Other stuff to optimize and cut down on cpu intensive tasks.

Files changed outside of core:
\MQ2Cast\MQ2Cast.cpp
\MQ2Rez\MQ2Rez.cpp

01 Sep 2017 by eqmule
- You can now call functions inside if statements in your macros - cred eqholic
Example:
Rich (BB code):
Sub Testsub
    /echo Enter Testsub
    /return Hello world
/return

Sub Testargs(int arg1,int arg2)
    /if (${arg1} > ${arg2}) {
        /return Testargs: ${arg1} > ${arg2}
    } else {
        /return Testargs: ${arg1} <= ${arg2}
    }
/return

Sub IsHuuge(int arg1)
    /echo IsHuuge ${arg1} ?
    /if (${arg1} > 1000) {
        /echo TRUE
        /return TRUE
    } else {
        /echo FALSE
        /return FALSE
    }
/return

Sub Main 
    /echo ${Testsub}
    /echo ${Testargs[10 9]}
    /if (${IsHuuge[2000]} && !${IsHuuge[1]}) /echo Huuge and smaaal
/return
 

Attachments

Last edited:
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

kissassist1004e15 changes
Rich (BB code):
[*] Line 59: moved #Event Burn              "[MQ2] |${BurnText}|" to line 157 because ${BurnText} is not defined
	and them Defined BurnText on line 159
[*] /halfmoon now calculates the offset by itself, so you just specify a radius
	Example: /halfmoon 20 will position everyone in group 20 feet behind you in a halfcircle facing your heading.
[*] Fixed: The following list are variables that where used but not declared:
    ${Twist} is declared and defaults to 0 now if the mq2twist plugin is not loaded.
    ${GroupEscapeOn} is declared and defaults to 0 now
    ${BeforeCombat} is declared and defaults to 0 now
    ${TwistOn} is declared and defaults to 0 now
    ${MeleeTwistOn} is declared and defaults to 0 now
    ${AutoRezOn} is declared and defaults to 0 now
    ${PetForceHealOnMed} is declared and defaults to 0 now
    ${PetOn} is declared and defaults to 0 now
    ${PetFocus} is declared and defaults to 0 now
    ${PetToysGave} is declared and defaults to 0 now
    ${PetToysOn} is declared and defaults to 0 now
    ${MezOn} is declared and defaults to 0 now
    ${MPetToysGave} is declared and defaults to 0 now
    ${MPetToysGave} is declared and defaults to 0 now

[*] All calls to PParse are now paramchecked instead of hardcoded to 12
[*] A few instances where /if ${Debug} /echo blah has been changed to {/echo blah} to
    prevent usage of undeclared variables and to speed up the processing of the lines.
    instead of checking the full line every iteration, it now just checks if ${Debug} is actually set before
    it moves on and parses the echo line...
    There are many more of these that should be fixed in a similar manner to increase speed.

[*] BugFix: ${ChaseAssit} has been renamed to ${ChaseAssist}
[*] BugFix: WaitCast now properly defines the sentFrom parameter
[*] BugFix: ${Pull} has been renamed to ${Pulling}
[*] The LoadIni Sub has been rewritten to take all its parameters into account as they now default to NULL
[*] BugFix: /if (${GameState.Equal[CHARSELECT]}) has been changed to /if (${EverQuest.GameState.Equal[CHARSELECT]})
[*] BugFix: /if (${Hovering}) has been changed to /if (${Me.Hovering})

[*] BugFix:

	
	





Rich (BB code):
/if (${Spell[SHealSpell].TargetType.Find[Group v]})  /varset SHealRange ${Spell[${1stPart}].AERange}
has been changed to
Rich (BB code):
/if (${Spell[SHealSpell].TargetType.Find[Group v]}) /varset SHealRange ${Spell[${SHealSpell}].AERange}
[*] BugFix:
Rich (BB code):
/if (${Spawn[${SHealThem}].Type.Equal[Pet]}  && (${HealSpell.Find[Aegis of Superior Divinity]} || ${HealSpell.Find[Harmony of the Soul]} ||  ${HealSpell.Find[Divine Arbitration]})) /goto :SNextHeal
/if (!${Spawn[${SHealName} ${SHealType} group].ID} && (${HealSpell.Find[Aegis of Superior Divinity]} || ${HealSpell.Find[Harmony of the Soul]} ||  ${HealSpell.Find[Divine Arbitration]})) /goto :SNextHeal
has been changed to
Rich (BB code):
/if (${Spawn[${SHealThem}].Type.Equal[Pet]}  && (${SHealSpell.Find[Aegis of Superior Divinity]} || ${SHealSpell.Find[Harmony of the Soul]} ||  ${SHealSpell.Find[Divine Arbitration]})) /goto :SNextHeal
/if (!${Spawn[${SHealName} ${SHealType} group].ID} && (${SHealSpell.Find[Aegis of Superior Divinity]} || ${SHealSpell.Find[Harmony of the Soul]} ||  ${SHealSpell.Find[Divine Arbitration]})) /goto :SNextHeal
and
Rich (BB code):
/if (!${Spawn[${SHealName} ${SHealType} group].ID} && ${Select[${Me.Class.Name},Druid,Shaman]} && (${HealSpell.Find[Intervention]} || ${HealSpell.Find[Survival]})) /goto :SNextHeal
has been changed to
Rich (BB code):
/if (!${Spawn[${SHealName} ${SHealType} group].ID} && ${Select[${Me.Class.Name},Druid,Shaman]} && (${SHealSpell.Find[Intervention]} || ${SHealSpell.Find[Survival]})) /goto :SNextHeal
[*] BugFix:
Rich (BB code):
/if (${If[${GHCond[${i}]},1,0]}) {
has been changed to
Rich (BB code):
/if (${If[${GHCond[${j}]},1,0]}) {
[*] ${PVPullMobName. has been renamed to ${PVPullMob. [*] /if (!${ComabtMed}) has been renamed to /if (!${MedCombat}) [*] BugFix: The undeclared ZDist variable in Sub Event_TooFar has been declared. [*] The undeclared variable GoMTimer used in Sub Event_GoMOn is now declared as an outer in sub main. [*] BugFix: All instances of the non existant variable ${DebugHeals} has been renamed to the existing one, ${DebugHeal} [*] BugFix: All instances of ${int has been renamed to ${Int [*] BugFix: The undefined and unused variable ${rkTemp1} has been removed. [*] BugFix:
Rich (BB code):
/call LoadIni General RezAcceptOn           string      0|98
changed to
Rich (BB code):
/call LoadIni General RezAcceptOn           string      0|96
[*] BugFix: changed all /moveto stop to /moveto off (cause there is no stop arg for moveto) [*] Feature: if the puller has mana and its below 100 and he is looking for mobs to pull, he will sit while doing so [*] BugFix: Other undeclared variables, more than i can list. [*] PullDance now only dances once and only if mob is further out than 80 feet
 

Attachments

Last edited by a moderator:
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

I feel I should explain the changes a bit, but first of all, don't come here on patchday and say I didn't give you enough time to fix your macros.

Ok, now that that's settled, what's the deal with this?

Technical details:

Well, while implementing a new feature for calling functions within /if statements with eqholic (thanks)
I wanted to see how much of an impact this new functionality had on the performance.

Doing that I noticed a huge performance hog when mq2 deals with undeclared variables.

Ill give you an example:
Using the new functionality we can have a macro that looks like this:
Rich (BB code):
Sub Main
    /echo hi there
    /if (${AmIRiding}) {
         /echo yes I am
    } else {
        /echo no I'm not
    }
/return

Sub AmIRiding
    /if (${Me.Mount.ID}) {
        /return 1
    }
/return 0
As you can see this is all nice and well, until someone accidently adds a variable that's ALSO named AmIRiding
at that point the interpreter wont know if it should check the variable or call the function so we came up with the idea of just adding [] to functions.
so it now becomes
Rich (BB code):
Sub Main
    /echo hi there
    /if (${AmIRiding[]}) {
         /echo yes I am
    } else {
        /echo no I'm not
    }
/return

Sub AmIRiding
    /if (${Me.Mount.ID}) {
        /return 1
    }
/return 0
well that solved it, however, then a bigger problem arose, undeclared variables.
so in kiss (I'm using kiss because its 10000 lines of a beast and it has plenty of examples)
there was a line of code that said
Rich (BB code):
/if (${MyTargeID}) /dostuff
now as you can see that's misspelled, it should be MyTargetID
the problem with that is that the macro interpreter cant find that variable (its not declared)
and it would then send it on to the code that checks if its a function and then finally fail.

THAT whole process would be called OVER and OVER thousands of times, and mq2 would previously just silently take that and swallow it.
I ran cpu profiling on it and 40% or more of the cpu cycles where used up on trying to find undeclared and misspelled variables!

SO... THAT is the reason I HAD to make these changes, this has been going on for YEARS...

With this change, I no longer silently take it, now mq2 will display errors for these kind of things as well as logging it to a undeclared variables list.

That list can be displayed when a macro is running by doing /invoke ${Macro.Undeclared}

I know its a total PITA to go over every single macro and run them and fix these things by either declareing the variables or rename them if misspelled, but trust me once you get
it done, you will go from 40% cpu cycles dealing with them to 0 cycles, and you macros will run so much smoother and faster.
The increase in performance is night and day.

Ok so how to actually fix an error, first of all, you want to just run your macro and after a min or so click your hotkey where you have your /invoke ${Macro.Undeclared} line setup

then pause the macro and copy down the list, now go edit the macro, save start, rinse repeat until you get no more errors, then add a line #warning to the top of you macro and start it up again.

if you get any more errors it will warn u and pause the macro,

Here is an example warning and its fix:
Warning: ${ChaseAssit} is undeclared.
Fix: rename it to ${ChaseAssist}

Example 2:
ZDist in Sub Event_TooFar is undeclared
FIX: add /declare ZDist int local 0
to the beginning of that sub...

third problem is undeclared function parameters
for example we have this
Rich (BB code):
Sub DoStuff(string str1,string str2, string str3)
    ...
/return
now, if you call that with just /call DoStuff 1 2
and don't supply the third argument, EMPTY ARGS WILL ALWAYS DEFAULT TO NULL FROM NOW ON.
this break macros like Ninjaadvloot.inc which has a function:
Rich (BB code):
Sub SetupAdvLootVars(string ChangeIniFile)
now Kiss and other macros just always call it like /call SetupAdvLootVars
without supplying a parameter... lets see what that do:
Rich (BB code):
 /if (${ChangeIniFile.Length}) {
        /varset NinjaIniFile ${ChangeIniFile}
    }
as you now know, an EMPTY arg is now always "NULL" so the length will therefor be 4...
the fix is to change it to
Rich (BB code):
/if (${ChangeIniFile.NotEqual[NULL]}) {
        /varset NinjaIniFile ${ChangeIniFile}
    }
mkay... makes sense?

well I hope so, and ill be available both here and on skype to help out.
This is something that WILL take time, there will be blood sweat and tears I'm sure of it, but trust me in the end it will be worth it.
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

I feel I should explain the changes a bit, but first of all, don't come here on patchday and say I didn't give you enough time to fix your macros.

Ok, now that that's settled, what's the deal with this?

Technical details:

Well, while implementing a new feature for calling functions within /if statements with eqholic (thanks)
I wanted to see how much of an impact this new functionality had on the performance.

Doing that I noticed a huge performance hog when mq2 deals with undeclared variables.

Ill give you an example:
Using the new functionality we can have a macro that looks like this:
Rich (BB code):
Sub Main
    /echo hi there
    /if (${AmIRiding}) {
         /echo yes I am
    } else {
        /echo no I'm not
    }
/return

Sub AmIRiding
    /if (${Me.Mount.ID}) {
        /return 1
    }
/return 0
As you can see this is all nice and well, until someone accidently adds a variable that's ALSO named AmIRiding
at that point the interpreter wont know if it should check the variable or call the function so we came up with the idea of just adding [] to functions.
so it now becomes
Rich (BB code):
Sub Main
    /echo hi there
    /if (${AmIRiding[]}) {
         /echo yes I am
    } else {
        /echo no I'm not
    }
/return

Sub AmIRiding
    /if (${Me.Mount.ID}) {
        /return 1
    }
/return 0
well that solved it, however, then a bigger problem arose, undeclared variables.
so in kiss (I'm using kiss because its 10000 lines of a beast and it has plenty of examples)
there was a line of code that said
Rich (BB code):
/if (${MyTargeID}) /dostuff
now as you can see that's misspelled, it should be MyTargetID
the problem with that is that the macro interpreter cant find that variable (its not declared)
and it would then send it on to the code that checks if its a function and then finally fail.

THAT whole process would be called OVER and OVER thousands of times, and mq2 would previously just silently take that and swallow it.
I ran cpu profiling on it and 40% or more of the cpu cycles where used up on trying to find undeclared and misspelled variables!

SO... THAT is the reason I HAD to make these changes, this has been going on for YEARS...

With this change, I no longer silently take it, now mq2 will display errors for these kind of things as well as logging it to a undeclared variables list.

That list can be displayed when a macro is running by doing /invoke ${Macro.Undeclared}

I know its a total PITA to go over every single macro and run them and fix these things by either declareing the variables or rename the if misspelled, but trust me once you get
it done, you will go from 40% cpu cycles dealing with them to 0 cycles, and you macros will run so much smoother and faster.
The increase in performance is night and day.

Ok so how to actually fix an error, first of all, you want to just run your macro and after a min or so click your hotkey where you have your /invoke ${Macro.Undeclared} line setup

then pause the macro and copy down the list, now go edit the macro, save start, rinse repeat until you get no more errors, then add a line #warning to the top of you macro and start it up again.

if you get any more errors it will warn u and pause the macro,

Here is an example warning and its fix:
Warning: ${ChaseAssit} is undeclared.
Fix: rename it to ${ChaseAssist}

Example 2:
ZDist in Sub Event_TooFar is undeclared
FIX: add /declare ZDist int local 0
to the beginning of that sub...

mkay... makes sense?

well I hope so, and ill be available both here and on skype to help out.
This is something that WILL take time, there will be blood sweat and tears I'm sure of it, but trust me in the end it will be worth it.

You didn't give me enough time to fix my macros!?! Haha, JK. I write clean macros so its a very welcomed change. Great work as always man. Look forward to the performance bump.
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

awesome work!
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

Is this not on the auto-updater yet? Do I just copy over my base directory?
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

Is this not on the auto-updater yet? Do I just copy over my base directory?

Correct, I'm not releasing it until we get our most used macros fixed.

Copying it over your base directory might overwrite some settings, I'd avoid copying .ini files, or make a backup copy of your folder.
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

Thanks to Hurricane Irma, I won't be able to even put in any serious time until after next weekend. I am referring to the 16th and 17th. I am in the middle of evacuations as well as bringing down the company network for both our locations. I still have to go into the physical locations tomorrow morning and turn off all power to the system. On top of that I still have to Evacuate my family, Late I might add.

I will do what I can, when I can, even though you think you gave plenty of notice to everyone.
 
Concerning the examples of function calls

/echo ${Testsub} is from the first proposal and won't work. A function call requires at least an empty argument list like so /echo ${Testsub[]}.
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

Getting an error on line 2760 using chase on. Undefined variable for ${Navigation.MeshLoaded}
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

Thanks to Hurricane Irma, I won't be able to even put in any serious time until after next weekend. I am referring to the 16th and 17th. I am in the middle of evacuations as well as bringing down the company network for both our locations. I still have to go into the physical locations tomorrow morning and turn off all power to the system. On top of that I still have to Evacuate my family, Late I might add.

I will do what I can, when I can, even though you think you gave plenty of notice to everyone.

BE SAFE!

I have friends and family in the Florida, it's scary. I've been through 3 or 4 hurricanes in Florida and I can't even imagine how this one will be.
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

Getting an error on line 2760 using chase on. Undefined variable for ${Navigation.MeshLoaded}


Thank you!

That's exactly the feedback we need from testers. I think there might be more of these and they need to all be checked by first checking
Rich (BB code):
/if (${mq2navloaded}) {
    /if (Navigation.MeshLoaded) { ...
Not everyone uses mq2nav so we can't rely on specific plugins being loaded or not when using such variables in our macros, thus the check.
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

getting this when using it ?

Rich (BB code):
[2017/09/09 07:43:16] WARNING: Undefined Variable TargetID used on line [email protected] /if (${DebugCombat}) ${Me} ${MainAssist} ${Spawn[=${MainAssist}].Distance} ${MobCount} ${AggroTargetID} ${TargetID} ${MyTargetID} ${Melee} ${MeleeCombat} ${MeleeTarget} ${MeleeStatus})  \agLine#: ${Macro.CurLine}Macro Paused.


Casters and healer's seem to work fine , only issue I see is with melee , Say it works fine pulling the mob , but the engaging the mob is the issue ,

- - - Updated - - -

I seem to have temp fixed that line by replacing it with
Rich (BB code):
  /if (${BlurredMobID} && ${Math.Distance[${Spawn[${BlurredMobID}].Y},${Spawn[${BlurredMobID}].X}:${CampYLoc},${CampXLoc}]}<${MeleeDistance}) {
seems to have worked... maybe not right but seems to have worked now I'm getting a line 1997 break of

Rich (BB code):
[2017/09/09 08:01:08] WARNING: Undefined Variable castWhat used on line [email protected] /if (${Me.AltAbility[${MashThis}]} && ${Me.AltAbilityReady[${MashThis}]} && ${Me.AltAbility[${MashThis}].Type}!=5 && ${castWhat.NotEqual[twincast]})  {Macro Paused.

- - - Updated - - -

Fixed that line by Removing
Rich (BB code):
${CastWhat.NotEqual[twincast]})  { 
                    /alt act "${MashThis}

making it
Rich (BB code):
${Cast.NotEqual[twincast]})  { 
                    /alt act "${MashThis}

now line 1658 broke ....


Rich (BB code):
[2017/09/09 08:15:14] WARNING: Undefined Variable Melee used on line [email protected] /if (${Spawn[${MyTargetID}].Type.NotEqual[Corpse]} || ${Spawn[${MyTargetID}].ID} || ${Melee.Status.NotEqual[FEIGNING]}) /goto :AttackMacro Pause
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

Change TargetID to Target.ID
it is a typo

castWhat is indeed undeclared in that sub, it needs to be changed from:
Rich (BB code):
                /if (${Me.AltAbility[${MashThis}]} && ${Me.AltAbilityReady[${MashThis}]} && ${Me.AltAbility[${MashThis}].Type}!=5 && ${castWhat.NotEqual[twincast]})  {
to
Rich (BB code):
                /if (${Me.AltAbility[${MashThis}]} && ${Me.AltAbilityReady[${MashThis}]} && ${Me.AltAbility[${MashThis}].Type}!=5 && ${MashThis.NotEqual[twincast]})  {

The last one is trickier, you can /plugin mq2melee but one fix would be to change it to:
Rich (BB code):
/if (${Spawn[${MyTargetID}].Type.NotEqual[Corpse]} || ${Spawn[${MyTargetID}].ID}) /goto :Attack
/if (${Bool[${Plugin[MQ2Melee]}]}) {
    /if (${Melee.Status.NotEqual[FEIGNING]}) /goto :Attack
}
Crowdfixing a macro! I love it!
 
Last edited:
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

Rich (BB code):
[2017/09/09 08:49:08] Unparsable in Calculation: 'S'
[2017/09/09 08:49:08] kissassist.mac@1669 (CombatTargetCheck): /if (${Spawn[${MyTarget.ID}].Type.Equal[Corpse]} || Spawn[${MyTarget.ID}].ID} || ${DPSPaused}) /return
[2017/09/09 08:49:08] kissassist.mac@1726 (CombatCast): /call CombatTargetCheck
[2017/09/09 08:49:08] kissassist.mac@1589 (Combat): /if (${DPSOn} && (!${Role.Equal[puller]} || !${ChainPull})) /call CombatCast
[2017/09/09 08:49:08] kissassist.mac@1159 (CheckForCombat(int SkipCombat, string FromWhere)): /call Combat
[2017/09/09 08:49:08] kissassist.mac@1044 (Main): /call CheckForCombat 0 MainLoop
[2017/09/09 08:49:08] The current macro has ended.
[2017/09/09 08:49:08] Failed to parse /if condition '(NULL || Spawn[NULL].ID} || 0)', non-numeric encountered

did that and now got this
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

I was talking about that one instance of TargetID not MyTargetID

this:
Rich (BB code):
/if (${DebugCombat}) ${Me} ${MainAssist} ${Spawn[=${MainAssist}].Distance} ${MobCount} ${AggroTargetID} ${TargetID} ${MyTargetID} ${Melee} ${MeleeCombat} ${MeleeTarget} ${MeleeStatus})  \agLine#: ${Macro.CurLine}Macro Paused.
should be changed to
Rich (BB code):
/if (${DebugCombat}) ${Me} ${MainAssist} ${Spawn[=${MainAssist}].Distance} ${MobCount} ${AggroTargetID} ${Target.ID} ${MyTargetID} ${Melee} ${MeleeCombat} ${MeleeTarget} ${MeleeStatus})  \agLine#: ${Macro.CurLine}Macro Paused.

what weird though is that I don't have that typo in the version I downloaded from the post above...
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

Kept running into a Healing Issue that was causing my Sham and Druid to stop healing. Was calling for a HealThem and HealPct Variable that wasn't there. What i changed was these 2 lines and it seemed to stop it from happening.

Line 2941
Rich (BB code):
/if (${Debug}) /echo \amDEBUG DoPetMedStuff (${SingleHeal[${j}].Arg[3,|].Find[PET]} && ${HealThem}==${Me.ID} && ${Me.Pet.PctHPs}<=${HealPct} && ${Me.Pet.ID} && ${Me.Pet.Distance}<${Spell[${SingleHeal[${j}].Arg[1,|]}].Range}) \agLine#: ${Macro.CurLine}
to
Rich (BB code):
/if (${Debug}) /echo \amDEBUG DoPetMedStuff (${SingleHeal[${j}].Arg[3,|].Find[PET]} && ${SHealThem}==${Me.ID} && ${Me.Pet.PctHPs}<=${SHealPct} && ${Me.Pet.ID} && ${Me.Pet.Distance}<${Spell[${SingleHeal[${j}].Arg[1,|]}].Range}) \agLine#: ${Macro.CurLine}
and Line 4599
Rich (BB code):
 /if (${DebugHeal}) /echo \amDEBUGHEALS DoPetHealStuff (${SingleHeal[${j}].Arg[3,|].Find[PET]} && ${HealThem}==${Me.ID} && ${Me.Pet.PctHPs}<=${HealPct} && ${Me.Pet.ID} && ${Me.Pet.Distance}<${Spell[${SingleHeal[${j}].Arg[1,|]}].Range}) \agLine#: ${Macro.CurLine}
to
Rich (BB code):
/if (${DebugHeal}) /echo \amDEBUGHEALS DoPetHealStuff (${SingleHeal[${j}].Arg[3,|].Find[PET]} && ${SHealThem}==${Me.ID} && ${Me.Pet.PctHPs}<=${SHealPct} && ${Me.Pet.ID} && ${Me.Pet.Distance}<${Spell[${SingleHeal[${j}].Arg[1,|]}].Range}) \agLine#: ${Macro.CurLine}
All I did was add the missing S infront of the HealThem and HealPct to both lines but that seemed to Help me out.

Also on my Druid im receiving another Variable issue that I can't seem to find. It says
Rich (BB code):
Undefined Variable ME used on line [email protected]
I went through my Condition's also and I don't even have a condition with anything that has ME in it.

I Also changed the file name to just Kiss.Mac for me
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

those changes will still fail, instead just remove the faulty and non existant variable, like this:
Rich (BB code):
/if (${Debug}) {
    /echo \amDEBUG DoPetMedStuff (${SingleHeal[${j}].Arg[3,|].Find[PET]} && ${Me.Pet.PctHPs}<=${HealPct} && ${Me.Pet.ID} && ${Me.Pet.Distance}<${Spell[${SingleHeal[${j}].Arg[1,|]}].Range}) \agLine#: ${Macro.CurLine}
}
and
Rich (BB code):
/if (${DebugHeal}) {
    /echo \amDEBUGHEALS DoPetHealStuff (${SingleHeal[${j}].Arg[3,|].Find[PET]} && ${Me.Pet.PctHPs}<=${HealPct} && ${Me.Pet.ID} && ${Me.Pet.Distance}<${Spell[${SingleHeal[${j}].Arg[1,|]}].Range}) \agLine#: ${Macro.CurLine}
}

this: Undefined Variable ME used on line [email protected]

post your druids DPS section
 
Last edited:
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

Rich (BB code):
[DPS]
DPSOn=1
DPSSkip=20
DPSInterval=2
DPS1=Blessing of Ro|100
DPS2=Skin to Seedlings|0
DPS3=Sunfire Blessing|0
DPS4=Remote Sunflash|98
DPS5=Nature's Fiery Wrath|95
DPS6=Fire storm|91|Weave
DPS7=Anabatic Roar|87
DPS8=Winter's Wildflame|82
DPS9=Katabatic Roar|79
DPS10=Spirit's of Nature|75|Weave
DPS11=Banestrike|70
DPS12=Spirit of the Black Wolf|99
DPS13=Group Spirit of the Black Wolf|99
DPS14=NULL
DPS15=NULL
DPS16=NULL
DPS17=NULL
DPS18=NULL
DPS19=NULL
DPS20=NULL
DebuffAllOn=0
DPSCOn=1
DPSSize=20
and
Rich (BB code):
[DPS]
DPSCOn=1
DPS1=Blessing of Ro|100
DPSCond1=${Int[${Target.ID}]} && ${Int[${Target.Buff[Blessing of Ro].ID}]}==0
DPS2=Skin to Seedlings|0
DPSCond2=FALSE
DPS3=Sunfire Blessing|99|MA
DPSCond3=${Math.Calc[!${Me.Song[Healing Twincast].ID}].Int}
DPS4=Remote Sunflash|98
DPSCond4=${Math.Calc[${Target.Buff[Blessing of Ro].ID} && ${Target.PctHPs} > 20].Int}
DPS5=Nature's Fiery Wrath|95
DPSCond5=${Math.Calc[${Target.Buff[Blessing of Ro].ID} && !${Target.Buff[Nature's Fiery Wrath].ID} && ${Target.PctHPs} > 35].Int}
DPS6=Fire storm|91|Weave
DPSCond6=${Math.Calc[${Target.Buff[Blessing of Ro].ID} && ${Target.PctHPs} > 50].Int}
DPS7=Anabatic Roar|87
DPSCond7=TRUE
DPS8=Winter's Wildflame|82
DPSCond8=${Math.Calc[${Target.Buff[Blessing of Ro].ID}].Int}
DPS9=Katabatic Roar|79
DPSCond9=TRUE
DPS10=Spirit's of Nature|75|Weave
DPSCond10=${Math.Calc[${Target.Named}].Int}
DPS11=Banestrike|70
DPSCond11=${Math.Calc[${Me.AltAbilityReady[Banestrike]} && ${Target.PctHPs} > 20].Int}
DPS12=Spirit of the Black Wolf|99
DPSCond12=${Math.Calc[${Me.AltAbilityReady[Spirit of the Black Wolf IV].ID} && !${Me.Buff[Group Spirit of the Black Wolf IV].ID}].Int}
DPS13=Group Spirit of the Black Wolf|99
DPSCond13=${Math.Calc[!${Me.AltAbilityReady[Spirit of the Black Wolf IV].ID} && !${ME.BUFF[Spirit of the Black Wolf IV].ID} || ${Target.Named}  && !${ME.BUFF[Spirit of the Black Wolf IV].ID}].Int}

I've also tried DPSCond12=TRUE and DPSCond13=TRUE with the same results
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

I may be wrong, but you capitalised the E in ME

Rich (BB code):
DPSCond13=${Math.Calc[!${Me.AltAbilityReady[Spirit of the Black Wolf IV].ID} && !${ME.BUFF[Spirit of the Black Wolf IV].ID} || ${Target.Named}  && !${ME.BUFF[Spirit of the Black Wolf IV].ID}].Int}

try changing to

Rich (BB code):
DPSCond13=${Math.Calc[!${Me.AltAbilityReady[Spirit of the Black Wolf IV].ID} && !${Me.Buff[Spirit of the Black Wolf IV].ID} || ${Target.Named}  && !${Me.Buff[Spirit of the Black Wolf IV].ID}].Int}
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

you are correct its indeed this that's wrong
Rich (BB code):
!${ME.BUFF[
change to
Rich (BB code):
!${Me.Buff[

I took the liberty to just fix your whole section, there are multiple things that are wrong in it or can be streamlined for better performance.

For example there is no need to check if stuff is ready to use or cast as kiss already check these things internally always. so...:

Rich (BB code):
[DPS]
DPSCOn=1
DPS1=Blessing of Ro|100
DPSCond1=${Target.ID} && !${Target.Buff[Blessing of Ro].ID}
DPS2=Skin to Seedlings|0
DPSCond2=FALSE
DPS3=Sunfire Blessing|99|MA
DPSCond3=!${Me.Song[Healing Twincast].ID}
DPS4=Remote Sunflash|98
DPSCond4=${Target.Buff[Blessing of Ro].ID} && ${Target.PctHPs} > 20
DPS5=Nature's Fiery Wrath|95
DPSCond5=${Target.Buff[Blessing of Ro].ID} && !${Target.Buff[Nature's Fiery Wrath].ID} && ${Target.PctHPs} > 35
DPS6=Fire storm|91|Weave
DPSCond6=${Target.Buff[Blessing of Ro].ID} && ${Target.PctHPs} > 50
DPS7=Anabatic Roar|87
DPSCond7=TRUE
DPS8=Winter's Wildflame|82
DPSCond8=${Target.Buff[Blessing of Ro].ID}
DPS9=Katabatic Roar|79
DPSCond9=TRUE
DPS10=Spirit's of Nature|75|Weave
DPSCond10=${Target.Named}
DPS11=Banestrike|70
DPSCond11=${Target.PctHPs} > 20
DPS12=Spirit of the Black Wolf|99
DPSCond12=!${Me.Buff[Group Spirit of the Black Wolf IV].ID} && !${Me.Buff[Spirit of the Black Wolf IV].ID}
DPS13=Group Spirit of the Black Wolf|99
DPSCond13=${Target.Named} && !${Me.Buff[Group Spirit of the Black Wolf IV].ID}
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

DPS13=Group Spirit of the Black Wolf|99
DPSCond13=${Math.Calc[!${Me.AltAbilityReady[Spirit of the Black Wolf IV].ID} && !${ME.BUFF[Spirit of the Black Wolf IV].ID} || ${Target.Named} && !${ME.BUFF[Spirit of the Black Wolf IV].ID}].Int}
As he said, ME.BUFF to Me.Buff
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

The post with the macro in has been updated with fixes for the bugs so far reported.
redownload.

mwilliam found another one:
Rich (BB code):
            /if (${PFlag} && ${PVPullMobDistance}<=360 && ${Target.ID}!=${PVPullMob}) {
needs to be changed to
Rich (BB code):
            /if (${PFlag} && ${Spawn[${PVPullMob}].Distance} <= 360 && ${Target.ID} != ${PVPullMob}) {

macro in the macro post updated again. Expect more of these during the next few days. Check back often.
 
Last edited:
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

I am debugging the Official Kiss 10.0.4 Release currently. I will post it here in about an hour or so.

Thanks to everyone posting on this.
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

Here is the first draft.

Kiss Official 10.0.4 for bind fix and warnings strict syntax

If you are posting errors please tell us if its Official or Eqmule's version

Tested on
SK
Bard
Cleric
Zerker
Beastlord
Mage
Warrior

New Kiss upload #4
Bard Fix -GomSpell
Chanter fix - Petfocus

Kiss upload #3
Bard Fix
DPSMeter Fix

Ninjadvloot 6.06
has an edit in line 85
Rich (BB code):
   /if (${ChangeIniFile.Length}) {
needs to be
Rich (BB code):
   /if (${ChangeIniFile.Length} && ${ChangeIniFile.NotEqual[null]}) {
 
Last edited:
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

eqmule you mentioend that kiss checks readyness of spells skills and such so no need to check for that , but if i dont check when i got conditions on, all i see in the mq2 window is spam about kiss trying to cast things that arent ready, specially noticeable when using your build.
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

Never seen it do that, I would have to see your ini to determine why that is. Kiss has had the SpellReady and AltAbilityReady checks in its cast sub for years... I haven't even touched that stuff as I have 6 chars running with DPS conditions turned on without any types of ready checks for months now...

I know my version has more debug turned on to show when conditions fire or not so it should be easy to spot failures... (also easy to mistake that spam for failures when really it's just information)
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

bazaar.mac

Line 228
Rich (BB code):
/if (${B}==1) /varset minprice 2

Change to:

/if (${minprice }==1) /varset minprice 2

Line 297
Rich (BB code):
/if (${GameState.Equal[CHARSELECT]}) /endmac

Change to:

/if (${EverQuest.GameState.Equal[CHARSELECT]}) /endmac

- - - Updated - - -

hmm it might just be information spam then lol, i just noticed igot less of it f i had checks in for it

Rich (BB code):
[DPS]
DPSOn=2
DPSCOn=1
DPSSize=10
DPSSkip=2
DPSInterval=0
DPS1=Sha's Reprisal
DPSCond1=!${Target.Slowed.ID} && ${Me.SpellReady[${Spell[Sha's Reprisal].RankName}]}
DPS2=Feral Swipe
DPSCond2=${Me.AltAbilityReady[Feral Swipe]}
DPS3=Barrage
DPSCond3=${Me.CombatAbilityReady[${Spell[Barrage].RankName}]}
DPS4=Bestial Rending
DPSCond4=${Me.CombatAbilityReady[${Spell[Bestial Rending].RankName}]}
DPS5=Banestrike
DPSCond5=${Me.AltAbilityReady[Banestrike]}
DPS6=Growl of the Lion
DPSCond6=!${Me.Song[Growl of the Lion].ID} || !${Me.Song[Growl of the Tiger II].ID}
DPS7=Tuzil's Feralgia
DPSCond7=${Me.SpellReady[${Spell[Tuzil's Feralgia].RankName}]} && ${Target.PctHPs} > 20
DPS8=Frostrift Lance
DPSCond8=${Me.SpellReady[${Spell[Frostrift Lance].RankName}]}
DPS9=Rotsil's Bite
DPSCond9=${Me.SpellReady[${Spell[Rotsil's Bite].RankName}]}
DPS10=Companion's Sacrifice
DPSCond10=${Me.AltAbilityReady[Companion's Sacrifice]}  && ${Me.PctHPs} < 30
DebuffAllOn=0
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

The new compile is having issues with params when here is only 1.

Rich (BB code):
/mac kissassist pullertank
does not work but
Rich (BB code):
/mac kissassist pullertank maskoi
does work
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

I'm not sure where the broken part is in this but this is what I'm getting

Rich (BB code):
[2017/09/10 23:09:58] WARNING: Undefined Variable BOOL{Target used on line [email protected] /if (${Me.CombatAbility[${MashThis}]} && !${Me.CombatAbilityTimer[${MashThis}]} && ${Me.CombatAbilityReady[${MashThis}]} && ${Spell[MashThis].EnduranceCost}<${Me.Endurance}) {Macro Paused.

this is my current line


Rich (BB code):
 /if (${Me.CombatAbility[${MashThis}]} && !${Me.CombatAbilityTimer[${MashThis}]} && ${Me.CombatAbilityReady[${MashThis}]} && ${Spell[MashThis].EnduranceCost}<${Me.Endurance}) {


using this on my Shadowknight as a puller tank , this is the only error I am getting now , everything seems to be working on my enchanter wizard cleric and bard , I take that back I am getting a GOM error on bard
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

whose version Official or Eqmules?
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

The rest of the warnings needs a new compile I will release that in the morning. Thanks for the reports so far, that BOOL looks like it might be a condition that needs to be changed to Bool instead.
 
Re: Very Vanilla 09/08/2017 - Live server #bind fix. Macros will break, please test!

First post compile updated with today's source
 
Re: Very Vanilla 09/12/2017 - Live server #bind fix. Macros will break, please test!

Hmm this is my 666 post, maybe I should stop now...

Now that the new zip is uploaded, I have updated Kissassist1004e15 to version 1.52.

It has many updates and fixes,one of them being that kiss now takes all parameters again.

Example: /mac kissassist1004e15 tank works as well as any other combination of parameters.

/mac kissassist1004e15 ini kissassist_${EverQuest.Server}_${Me}_${Me.Level} tank ${Me}

etc...

enjoy and pls report more variable warnings.

link to post above that has the updated macro: https://www.redguides.com/forums/th...s-will-break-please-test!?p=334851#post334851


and btw... how awesome is /halfmoon 30? pretty cool huh? (cred to derple for helping me with the math for that one actually!)
.
 
Re: Very Vanilla 09/12/2017 - Live server #bind fix. Macros will break, please test!

I will update the official kiss 10.0.4 test version soon as I get home with the new changes and upload it later tonight for testing.
 
Re: Very Vanilla 09/12/2017 - Live server #bind fix. Macros will break, please test!

KissAssist 10.0.5 - Updated for new bind/warning changes
Ninjadvloot 6.0.7 - Updated for new bind/warning changes
 

Attachments

Re: Very Vanilla 09/12/2017 - Live server #bind fix. Macros will break, please test!

seem to be having issues with RG version , SK will not agro mob within range now if pulling multiple , before this fix SK would agro anything that came into camp outside of what was targeted

Rich (BB code):
Role=Pullertank
CampRadius=30
CampRadiusExceed=400
 
Very Vanilla 09/17/2018 - Live server #bind fix. Macros will break, please test!
Status
Not open for further replies.

Users who are viewing this thread

Back
Top
Cart