|
mdvbilt Beginner
Joined: 21 Jul 2005 Posts: 13 Location: Encinitas, CA
|
Posted: Fri Aug 12, 2005 1:42 pm
Please help with a script. |
Hello,
I am an absolute moron when it comes to coding, so I need some serious help. Would someone be kind enough to write a script for me that would execute the command "who" every ten minutes?
And could you tell me how to implement it?
I don't know why, but when it comes to programming of any kind, it eludes me.
Thanks very much,
mdvbilt |
|
|
|
TonDiening GURU
Joined: 26 Jul 2001 Posts: 1958 Location: Canada
|
Posted: Fri Aug 12, 2005 3:40 pm |
You are looking for an alarm trigger.
#ALARM TenMinuteWhoTrigger *10:00 {who}
Depending how you want to control it.. how about 2 aliases:
#alias onwho {#T+ TenMinuteWhoTrigger;#SH TenMinuteWhoTrigger On}
#alias offwho {#T- TenMinuteWhoTrigger;#SH TenMinuteWhoTrigger Off} |
|
|
|
mdvbilt Beginner
Joined: 21 Jul 2005 Posts: 13 Location: Encinitas, CA
|
Posted: Sun Aug 14, 2005 8:25 pm |
Hey, that's wonderful, it works beautifully. Now, is there any way that I can have that script load automatically when I load that MUD?
Thanks,
mdvbilt |
|
|
|
Aarlot Adept
Joined: 30 Dec 2003 Posts: 226
|
Posted: Sun Aug 14, 2005 8:36 pm |
It should be a part of your settings now, and will always be there unless you delete it.
|
|
_________________ Everyone is entitled to their beliefs - until they die. Then only the truth matters. |
|
|
|
Private Adept
Joined: 10 Jan 2002 Posts: 264 Location: USA
|
Posted: Sun Aug 14, 2005 8:36 pm |
put the trigger in a class folder say "AutoWho", then set that class to enable on connect... use this alias instead:
#alias autowho {#IF {%1=on} {#CLASS AutoWho 1;#SH TenMinuteWhoTrigger On} {#CLASS AutoWho 0;#SH TenMinuteWhoTrigger Off}}
Use the alias to manually turn it on and off.
useage: autowho <on|off> |
|
|
|
mdvbilt Beginner
Joined: 21 Jul 2005 Posts: 13 Location: Encinitas, CA
|
Posted: Sun Aug 14, 2005 9:02 pm |
Thanks, I'll try that. I'm a little lost as to exactly where the triggers and aliases go, however. (See "coding moron" above.)
Sincerely,
mdvbilt |
|
|
|
Guinn Wizard
Joined: 03 Mar 2001 Posts: 1127 Location: London
|
Posted: Sun Aug 14, 2005 9:17 pm |
Just paste it into the command line. You can then see the result in the settings, when you click on triggers/aliases etc
|
|
_________________ CMUD Pro, Windows Vista x64
Core2 Q6600, 4GB RAM, GeForce 8800GT
Because you need it for text... ;) |
|
|
|
mdvbilt Beginner
Joined: 21 Jul 2005 Posts: 13 Location: Encinitas, CA
|
Posted: Sun Aug 14, 2005 9:53 pm |
Oh, alright. Thanks very much to everybody who's helped out here. Finally, I'm not getting dumped off the MUSH anymore!
|
|
|
|
mdvbilt Beginner
Joined: 21 Jul 2005 Posts: 13 Location: Encinitas, CA
|
Posted: Sun Aug 14, 2005 9:58 pm Still doing something wrong. |
Okay, wait, I'm still managing to screw things up. I've opened up "Classes" and went to the "Class Script" tab and copied the trigger into it. But everytime I hit "Save" it erases the trigger and goes back to being a blank script.
What am I doing wrong this time?
Thanks,
mdvbilt |
|
|
|
|
|