Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
Maximus
Wanderer


Joined: 21 May 2001
Posts: 59
Location: USA

PostPosted: Mon Feb 18, 2002 3:19 pm   

Advanced scripting concept
 
Okay, for about half a year now I've been working on what I like to refer to as a "queue system." The idea is to give zMud a recognition for my character's ability to perform certain actions (based on what balances he currently possesses, and there are many). So, I have string-list variables (which are the queue lists), and rather complex string-concatinating aliases to queue a command to that list. Basically, I can record all of the commands required for a menial, repetitive task into a text file, read that text file in and queue each command in turn, and the character on the mud will execute them sequentially as he is able (as opposed to trying to do so all at once).

Well, anyway, to accomplish this, I have to have an alarm that triggers every second, checks balances and character state and, if able, executes the first command from each queue. The problem lies in that this approach is rather a burden on zMud. I get exception errors every time I close, and just yesterday I tried to make 2 more 1 second alarms for an affliction test/cure and that ended up corrupting my settings file (and somehow my backup was from two months ago).

I've got a grand scheme for all the functionality I'd like to add to it, but the more I try, the more I run into road-blocks in zMud's capabilities. Now, I'm not denying that zMud is a powerful client, but everything I do seems to give it trouble. Maybe there's a more efficient way to go about this?

Or will I have to wait for some improved alarm functionality? After all, as far as I know there is no other way to constantly run a script unless it's with an alarm.

Basically, I'm almost thinkin it'd be easier to make a COM program to control zMud, but that's way out of my league...zMud scripting is something I can handle for now.

Eh, lemme know what you think. I'll elaborate more if I've been too vague.



-Maximus
Reply with quote
Kjata
GURU


Joined: 10 Oct 2000
Posts: 4379
Location: USA

PostPosted: Mon Feb 18, 2002 3:55 pm   
 
Try first following the steps in the Migration Guide to uncorrupt settings. This may clear up a lot of the problems you are having.

Kjata
Reply with quote
Maximus
Wanderer


Joined: 21 May 2001
Posts: 59
Location: USA

PostPosted: Mon Feb 18, 2002 4:54 pm   
 
Umm...no, I don't think you understand. The very processing of this 1 second alarm is causing the errors, but only when I close. My settings became corrupted when I tried to make two more 1 second alarms within the same class (something that definately needs to be fixed). I -know- it is the alarm that is causing the erros because if I remove it, there are none. However, the alarm's script is bug-free and essential to the system. I honestly don't think zMud was meant to handle this kind of script.


-Maximus
Reply with quote
Troubadour
GURU


Joined: 14 Oct 2000
Posts: 556
Location: USA

PostPosted: Mon Feb 18, 2002 5:53 pm   
 
Rather than use an alarm, have you tried placing your balancing checks and such in your prompt trigger?

Troubadour
Reply with quote
Maximus
Wanderer


Joined: 21 May 2001
Posts: 59
Location: USA

PostPosted: Mon Feb 18, 2002 6:02 pm   
 
I have. The problem with using the prompt trigger is that something has to -happen- before the prompt will show up. So basically, if a certain command is executed that doesn't necessarily result in a prompt, the process is halted until something occurs. The idea is for the queue system to "think" rather than "react," for one.

-Maximus
Reply with quote
Kjata
GURU


Joined: 10 Oct 2000
Posts: 4379
Location: USA

PostPosted: Mon Feb 18, 2002 7:17 pm   
 
Yes, I understood you. Getting errors when you close zMUD is a sign of corrupted settings. Perhaps not enough for zMUD to tell you that it can't open you settings, but the problem is there. Maybe this isn't what's causing your problem, maybe it is. However, I think that it would not hurt to try it just to ensure that you are working with a completly uncorrupted settings file.

I use an alarm like the one you described and it doesn't give me any problems, so I don't think that it is because zMUD can't handle an alarm that fires every second.

Kjata
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net