VIPMud - Chainwalk

Discussion of different MUD clients, plugins, etc. as well as technical help.
Post Reply
User avatar
Edoras
Member
Posts: 49
Joined: Mon Feb 08, 2016 7:16 am

VIPMud - Chainwalk

Post by Edoras »

Someone mentioned wanting a chainwalk style command for VIPMud today and nerd sniped me hard. Got it to work though.

Note: This is the first thing I've ever created for VIP Mud, so if there's a more effective way to provide it, or something blatantly obvious needs to be added, let me know if you could.


usage: chainwalk east,north,east,go gate,go arch,south,go stables,wander
using chainwalk, provide each direction you would like to go (including go commands e.g. go gate, go arch, wander, out) and chainwalk will incrementally execute the directions with a 1.5 second delay after arriving to the previous room.
usage: chainstop
chainstop will delete any queued chainwalk commands. If you get stuck in combat, find someone you want to talk to, or otherwise need to stop chainwalking, this command is very important to remember.

To use chainwalk for VIPMud:
Paste the following code block into your .set file for your character and/or the Clok mud within VIPmud.

Code: Select all

#Alias chainwalk {
@chainwalkDirections = %0;
@chainwalkStatus = %pos(",",@chainwalkDirections);
@nextDirection = %left(@chainwalkDirections,%pos(",",@chainwalkDirections)-1);
@chainwalkDirections = %right(@chainwalkDirections,%Length(@chainwalkDirections)-%pos(",",@chainwalkDirections));
#trig {<chainwalk1>You head *} {
#If {@chainwalkStatus = 0} {#Alarm 1.5 {@chainwalkDirections};#UnTrigger chainwalk1;#UnTrigger chainwalk2;};
@nextDirection = %left(@chainwalkDirections,%pos(",",@chainwalkDirections)-1);
@chainwalkDirections = %right(@chainwalkDirections,%Length(@chainwalkDirections)-%pos(",",@chainwalkDirections));
@chainwalkStatus = %pos(",",@chainwalkDirections);
#Alarm 1.5 {@nextDirection};
};
#trig {<chainwalk2>You venture *} {
#If {@chainwalkStatus = 0} {#Alarm 1.5 {@chainwalkDirections};#UnTrigger chainwalk1;#UnTrigger chainwalk2;};
@nextDirection = %left(@chainwalkDirections,%pos(",",@chainwalkDirections)-1);
@chainwalkDirections = %right(@chainwalkDirections,%Length(@chainwalkDirections)-%pos(",",@chainwalkDirections));
@chainwalkStatus = %pos(",",@chainwalkDirections);
#Alarm 1.5 {@nextDirection};
};
@nextDirection;
};
#Alias chainstop {
#say {Stopping chainwalking};
#UnTrigger chainwalk1;
#UnTrigger chainwalk2;
};
User avatar
Jirato
DEV
Posts: 3049
Joined: Sat Apr 14, 2012 12:17 pm

Re: VIPMud - Chainwalk

Post by Jirato »

Thanks for sharing.
[GMCHAT Uyoku]: Octum is when the octumbunny comes around and lays pumpkins everywhere right?
[GMCHAT Rias]: Dimmes says "oh hai :) u need healz? ill get u dont worry thaum lasers pew pew pew lol"
[CHAT - GameMaster Rias would totally nuke Rooks]: Here's how elemancy works: The freeblegreeble and the zippoflasm have to be combined with the correct ration of himbleplimp, then you add the gargenheimer and adjust the froopulon for the pattern you want, apply some tarratarrtarr, yibble the wantaban, and let 'er rip!
jilliana
Member
Posts: 936
Joined: Thu Jan 02, 2014 2:51 pm
Location: Texas
Contact:

Re: VIPMud - Chainwalk

Post by jilliana »

You are a miracle-worker! Thank you so much!
CHAT - Sir Alexander Candelori: Truly a man is an abomination that does not dip his french fries into his chocolate frosty.
Bryce flatly says, "Just fair warning: If one of those things webs me, I'm going to scream like a girl."
xavier
Member
Posts: 185
Joined: Wed Jul 31, 2013 7:36 am

Re: VIPMud - Chainwalk

Post by xavier »

You say this is the first thing you've created in VipMud. I'm thorughly impressed. I was scripting in it for months before I managed something that complicated. I had been scripting in vipmud for a few years before I started work on the original clok sound pack. If you don't mind as I update the sound pack for vipmud nwo that I'm playing again, do you mind if I include this code?
Rain falls steadily to the earth.
The gore has been washed from you.
The blood has been washed from you.
You are splattered with gore!
Rain falls steadily to the earth.
The gore has been washed from you.
The blood has been washed from you.
You are splattered with gore!
User avatar
Edoras
Member
Posts: 49
Joined: Mon Feb 08, 2016 7:16 am

Re: VIPMud - Chainwalk

Post by Edoras »

Not at all, the code is yours to do as you wish!

I'm glad you like it: I've done a lot of scripting in MUSH and I'm a coder for a living, so it comes a little easier to me. That said I still spent 3 solid hours on it and almost quit. Realizing that there was a windows help .chm file (as opposed to just the text file) was what saved my bacon.
Post Reply

Return to “Technical Stuff”