Advanced Follow Script - Follows in 3D w/ queueing

A forum for you to dump all the macros you create, allowing users to use, modify, and comment on your work.

Moderator: MacroQuest Developers

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

Advanced Follow Script - Follows in 3D w/ queueing

Post by ml2517 » Wed Dec 31, 2003 11:11 pm

This follows a player or NPC in 3D and queues up the pathing in case the player or mob gets ahead of you. Give it a try and let me know how it works for you.

I'm going to work on obstacle negotiation in the future but this avoids most needs since it follows the path closely. (**Added)

Edit:
Added a modifier to keep the follower slightly higher while in water to keep your head above water. (This just keeps the z axis slightly higher on the follower. If the player/npc you are following dives down in the water you will still follow.)
Added a modifier to keep you slightly higher while levitated. Its better to be slightly higher than lower.
Changed the targeting to be more graceful when the person you are following zones.
Added auto-door opening if encountered along the path.
Added auto-zoning. Works with zones that you walk through and/or click stones.
Added obstacle negotiation. Should be able to move around objects as well as try to leap an object if its in the way.
Cleaned up the script a little bit.
Tweaked the targeting, zoning and door code.
More tweaks to door code. Think I have it close to perfect now.
Cleaned up the code a bit more and added 'follow me' to follow the master.
Added support for local /echo commands.
Tweaked the obstacle negotiation.
Took care of a zoning problem if the person you are following is a slow zoner.
Cleared variables before follow and stop commands. This could have caused potential problems.

This is retired. Get advpath.inc and the advpath.mac from the snippets forum.
Last edited by ml2517 on Sat Apr 10, 2004 7:02 pm, edited 15 times in total.

User avatar
Elric
Cheese Whore
Cheese Whore
Posts: 466
Joined: Sun Nov 23, 2003 12:31 am
Location: Tampa, Fl
Contact:

Post by Elric » Wed Dec 31, 2003 11:22 pm

Seems like a very nice idea. I'll look into using this after the new year, when I get back onto EQ.
-Elric

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

Post by ml2517 » Thu Jan 01, 2004 5:24 am

Added a swimming modifier to keep the follower slightly higher while swimming. This should keep the followers head above water.
Added a modifier to keep you slightly higher while levitated. Its better to be slightly higher than lower.
Changed the targeting to be more graceful when the person you are following zones.

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

Post by ml2517 » Fri Jan 02, 2004 10:52 pm

Update:
Added auto-door opening if encountered along the path.
Added auto-zoning. Works with zones that you walk through and/or click stones.
Added obstacle negotiation. Should be able to move around objects as well as try to leap an object if its in the way.

Enjoy :D

wassup
Official Guardian and Writer of TFM
Official Guardian and Writer of TFM
Posts: 1487
Joined: Sat Oct 26, 2002 5:15 pm

Post by wassup » Fri Jan 02, 2004 11:20 pm

Sounds nice... wonder if this could be implemented in genbot.

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

Post by ml2517 » Fri Jan 02, 2004 11:26 pm

I intentionally tried to isolate things in Subs for that purpose. :D

I need people to tinker with it to test it for me though. I ran around with it for quite awhile and its works really well for me running at bard speed.

Let me know how it works for ya.

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

Post by ml2517 » Sat Jan 03, 2004 2:18 am

Cleaned up the script a little bit.
Tweaked the targeting, zoning and door code.

I need some feedback how this latest version works for people to see if I need to tweak it any more.

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

Post by ml2517 » Sat Jan 03, 2004 6:24 am

If you are testing this for me please re-grab it. The door code should work much better.

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

Post by ml2517 » Sat Jan 03, 2004 6:26 pm

Added support for /echo'd commands from your local machine.

This will allow you to use it to follow groupmembers or whatever if you are only on one machine.

It will support commands from both local and from a master if you start the macro like this:
/macro advfollow.mac mastername

It will support local /echo commands only if you start the macro like this:
/macro advfollow.mac

Command syntax from local commands is like this:
/echo follow playername
/echo stop

Put this in a hotkey to follow your target:
/echo follow $target(name,clean)

and this to stop:
/echo stop
Last edited by ml2517 on Sat Jan 03, 2004 7:39 pm, edited 1 time in total.

User avatar
Bad Karma
a snow griffon
a snow griffon
Posts: 346
Joined: Sat Nov 22, 2003 9:34 pm
Contact:

Post by Bad Karma » Sat Jan 03, 2004 7:27 pm

Excellent, ml
I was going to ask for this addition last night. Was only playing one box and had to follow group members to a zone. Tried setting it to take commands in chat, but it just sat there. Will try the new /echo support out today. =)

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

Post by ml2517 » Sun Jan 04, 2004 3:19 am

Grab this again if you've downloaded it. Still tweaking some of the routines. I must say it works pretty damn well as is. If I don't get any negative feedback I might start working on my next project.

Midnight
a lesser mummy
a lesser mummy
Posts: 68
Joined: Wed Nov 12, 2003 12:51 pm

Post by Midnight » Sun Jan 04, 2004 10:58 am

CVS this.. this sounds like a solid addition

User avatar
Elric
Cheese Whore
Cheese Whore
Posts: 466
Joined: Sun Nov 23, 2003 12:31 am
Location: Tampa, Fl
Contact:

Post by Elric » Sun Jan 04, 2004 2:23 pm

Much more useful than the original follow.mac, and a better example.

I think it would be a good replacement for it.
-Elric

User avatar
Bad Karma
a snow griffon
a snow griffon
Posts: 346
Joined: Sat Nov 22, 2003 9:34 pm
Contact:

Post by Bad Karma » Sun Jan 04, 2004 8:32 pm

I agree....in fact, I deleted follow.mac, and named this one in it's place. =)

One problem I did notice while using this last night in local mode:

When it catches up to the person, it runs in circles OR takes steps forward then back and repeats, OR spins in circles. If the person continues moving again, it does not follow....it seems to get stuck doing one of these 3 things until I /endmac.

Oh, and when I /echo stop, it stops, but if I zone, it resumes trying to target and follow the last person I was following. Again, I have to /endmac to get control back. If I /echo follow SomeoneElse, I get an initial message that my previous target could not be found before it acquires the new target.

Other than being a little slow to start, it works great. Been playing with it in PoK and a couple other zones. Using it in PoK to track down guildies and people needing buffs, and auto-run to them for testing purposes. Only got stuck on a building once, but the macro let me take control of my character without stopping it to get around the building, then it picked right up and did its thing! Gotta love it!

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

Post by ml2517 » Sun Jan 04, 2004 8:47 pm

Grab the latest version and verify you still see the same things.

Keep in mind that this is mainly designed to be used on group members because the data isn't sent to your client if a player character is outside of a certain radius unless you are grouped with them.

Also it is meant to be started when you are right near the other person. The very first movement after you issue the follow command runs in a straight line toward the y,x,z to the person you are following.

If you still see the running around in circles thing you might have to adjust the SpeedSense variable lower than 15. The speed of your CPU is going to most likely affect this script. If that isn't your problem I have no idea, I haven't seen any problems like that with the latest version.

Make sure you grab the latest version I have posted here. I think I'd already taken care of the "strange things after the person zones" thing.