Dynamic stick command

Third party software discussion goes here.
Noren
Posts: 1053

Dynamic stick command

Post#1 » Mon Mar 24, 2014 4:50 am

If any of the follow has happened, then this is for you. Have you...
*Sent one or more boxes running to their doom because they were at the zone-in or in another zone all together?
*Not realized one of your boxes is lost because they never actually started following you (perhaps because they were behind a wall or object)?
*Painstakingly made a unique /stick <blablabla> hotkey for each and every character?


Simply paste this line into your MacroQuest2.ini file under the [Aliases] section (thanks goes to an old friend who taught me what aliases are, some time ago!), save it, restart MQ2 (this may require you to restart your EQ clients in some instances), and then access it with /stickme when in game.

It's not a short command, but it should do exactly what you want it to (and then some).

Code: Select all

/stickme=/multiline @ /echo [${Time.Time24}] Command issued: /stickme@/noparse /bca //multiline ; /if (!${Defined[StickZone]}) /declare StickZone string global;/if (!${Defined[StickTar]}) /declare StickTar int global;/if (!${Defined[Listening]}) /declare Listening bool global TRUE@/bca //varset StickZone ${Zone.Name}@/bca //varset StickTar ${Me.ID}@/noparse /bca //if (${Listening} && ${Zone.Name.Equal[${StickZone}]} && ${Spawn[${StickTar}].ID} && ${Spawn[${StickTar}].Distance}<200 && ${LineOfSight[${Me.Y},${Me.X},${Me.Z}:${Spawn[${StickTar}].Y},${Spawn[${StickTar}].X},${Spawn[${StickTar}].Z}]}) /multiline ; /echo [${Time.Time24}] Sticking to ${Spawn[${StickTar}].CleanName};/face ID ${StickTar} fast;/stick ID ${StickTar} 10@/noparse /bca //timed 3 /if (${Stick.Status.Equal[OFF]} && ${Listening}) /bc [${Time.Time24}] Stick target isn't nearby. Staying put.


/stickme Will broadcast commands to your boxes to do the following...
[1] Declare two global variables if they do not exist. They are StickZone and StickTar. Global variables do not need an actively running macro to be created, accessed, or modified. This should meet the needs of both people that run macros and people that just do basic hotkeys with EQBCServer and plugins.
[2] Set those variables to the zone name (string) and ID (int) of the broadcasting character.
[3] Check if they are in the same zone, within range (200 units), and within line of sight of the broadcasting character. Then proceed to stick if these are all true.
[4] If anything in [3] is false, then they will broadcast that they cannot stick to this character in the MQ2 window.

I hope it makes some people's lives a little bit easier! Feel free to modify this to your needs if you know how. You can remove LoS requirements, change the range req, and of course change the type and distance of the /stick command.
Last edited by Noren on Wed Apr 02, 2014 8:02 pm, edited 2 times in total.

Ydiss
Posts: 1193

Re: Dynamic stick command

Post#2 » Mon Mar 24, 2014 11:53 am

Cool, thanks. I might try this out. I currently use netbots to check the broadcasting characters zone so I avoid most stick of doom scenarios. I also use the same logic with attack/attack off code so I can manage two or more camps in multiple zones, without conflict.

Stickybuds
Posts: 883

Re: Dynamic stick command

Post#3 » Mon Mar 24, 2014 1:17 pm

wow noren! very good work!
Image

User avatar
Grey
Posts: 1101

Re: Dynamic stick command

Post#4 » Mon Mar 24, 2014 8:16 pm

Creative use of global variables and the alias section of Macroquest.ini
I like seeing other people do stuff like this. Rate this a 12 out of 10!

User avatar
Rude
Posts: 454

Re: Dynamic stick command

Post#5 » Tue Mar 25, 2014 12:23 am

Yup! Very good work. Has rekindled my desire to delete my normal mac and start from scratch, using this and simple bc commands as the follow routine ;)

ikaf
Posts: 129
Contact:

Re: Dynamic stick command

Post#6 » Tue Apr 01, 2014 6:56 pm

I tried this, new to MQ2 and all , figured it would be a good first step and a really usefull one :D

sadly cant get it to work, says for all chars : "Stick target isn't nearby. Staying put". even when on top of each other.

Any advice ?
Ikaf [SHD] - Buttler [CLR] - Mikaf [MNK] - Bikaf [BRD] - Rikaf [ROG] - And Friends

Noren
Posts: 1053

Re: Dynamic stick command

Post#7 » Wed Apr 02, 2014 4:45 pm

ikaf wrote:I tried this, new to MQ2 and all , figured it would be a good first step and a really usefull one :D

sadly cant get it to work, says for all chars : "Stick target isn't nearby. Staying put". even when on top of each other.

Any advice ?


We may be using a different version of MQ2. I would try breaking down each requirement individually to see which one is holding you up.

[1] Issue the /stickme command (expecting no sticking to actually happen) and then do the following on another character than the one that issued the command.
[2] /echo ${StickZone}
[3] /echo ${StickTar}
If [2] and [3] are defined and hold values, then move on to [4].
[4] /echo ${Zone.Name.Equal[${StickZone}]}
[5] /echo ${Spawn[${StickTar}].ID}
[6] /echo ${Spawn[${StickTar}].Distance}<200
[7] /echo ${LineOfSight[${Me.Y},${Me.X},${Me.Z}:${Spawn[${StickTar}].Y},${Spawn[${StickTar}].X},${Spawn[${StickTar}].Z}]}
[8] /echo ${Stick.Status.Equal[ON]}
[9] /echo ${Stick.Status.Equal[OFF]}

Please report back with the value MQ2 gives you for each line. None of them should return errors or NULL. They should all have a value.

Oh and a tip!
If you didn't know (at least for the UF client), you can enable the Windows clipboard in-game for pasting. See pic.
clipboard.png
clipboard.png (303.73 KiB) Viewed 1359 times

ikaf
Posts: 129
Contact:

Re: Dynamic stick command

Post#8 » Wed Apr 02, 2014 9:34 pm

Here's what i get.
Command issued from SK and failed on both cleric and monk ( only had those loged ). they only turn to the SK.

Not sure on the MQ2 version , but using Titanium client.

Great tip on the clipboard option btw, never knew that was possible.


[2] /echo ${StickZone} * Icewell Keep
[3] /echo ${StickTar} * 332
If [2] and [3] are defined and hold values, then move on to [4].
[4] /echo ${Zone.Name.Equal[${StickZone}]} * TRUE
[5] /echo ${Spawn[${StickTar}].ID} * 332
[6] /echo ${Spawn[${StickTar}].Distance}<200 * 18.38<200
[7] /echo ${LineOfSight[${Me.Y},${Me.X},${Me.Z}:${Spawn[${StickTar}].Y},${Spawn[${StickTar}].X},${Spawn[${StickTar}].Z}]} * TRUE
[8] /echo ${Stick.Status.Equal[ON]} * FALSE
[9] /echo ${Stick.Status.Equal[OFF]} * TRUE
Ikaf [SHD] - Buttler [CLR] - Mikaf [MNK] - Bikaf [BRD] - Rikaf [ROG] - And Friends

Noren
Posts: 1053

Re: Dynamic stick command

Post#9 » Wed Apr 02, 2014 9:44 pm

For whatever reason, yours might need a longer delay before checking if stick is on. If you find where it says "//timed 3" try increasing that. That is in 1/10ths of a second. You can try //timed 10 to be very conservative, or //timed 6 for middle of the road.

Hope that works.

Tristhan
Posts: 293

Re: Dynamic stick command

Post#10 » Wed Apr 02, 2014 9:54 pm

Guildmember has the same problem, result:

1-Guild Hall
3 - 43
4 - TRUE
5 - 43
6 - 64.87<200
7 - TRUE
8 - FALSE (Sticking on ?)
9 - TRUE

Couldnt find any error in the command, couldnt check ingame tho.
Thank you Noren for the idea, he will try with higher delay, for me the command is working.

Return to “Third party software”

Who is online

Users browsing this forum: No registered users and 1 guest