Register forum user name Search FAQ

Gammon Forum

Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to verify your details, confirm your email, resolve issues, making threats, or asking for money, are spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the password reset link.
 Entire forum ➜ MUSHclient ➜ VBscript ➜ Imperian curing system

Imperian curing system

It is now over 60 days since the last post. This thread is closed.     Refresh page


Posted by Ren0   (6 posts)  Bio
Date Sat 10 Jul 2004 10:53 AM (UTC)

Amended on Sat 10 Jul 2004 10:55 AM (UTC) by Ren0

Message
I'm sitting here, everything but a newbie at programming, and trying to make a script to cure afflictions in Imperian. The way I decided to create the script was create variables that are either 0 or 1, and then have the script cure on herb balance, whatever I deem to be the most dangerous affliction (such as making a list with the afflictions in order of most dangerous to least dangerous).

I have a few problems with this, mostly the fact that I need MUSHclient to practically continuously check what afflictions i have on me, so that it actually initiates the curing process so that I get the herb balance message. I could use a timer that checks each second, but that seems like an excess. Also, if indeed you super intelligent coders out there think I should use a timer, then I need to know how to script the timer to make it check what variables are set to "1". A thought hit me, out of the blue, saying that this would be so much easier if you could put variables in groups, as well as triggers. In that case, you could check if, for example, world.variablegroup ("affliction", "stupid", "1") is true, perhaps even scrollable by a counter with every variable being assigned a number. Perhaps something worth pondering, Nick? This could also make it easy to make lists, even if they wouldn't look like ordinary lists.
Top

Posted by Flannel   USA  (1,230 posts)  Bio
Date Reply #1 on Sat 10 Jul 2004 05:44 PM (UTC)
Message
Just assign your variables numbers instead of names.

You could also script your variable checking a little, and achieve your grouping. Just have two parts to your variables, strung together with an underscore. Its been covered in the past if I remember correctly. Or at least, someone talked about it in the past, you could probably find the code if you searched for it.

You could also use an array. If you preset your afflictions in a certain order, then the array name would be your 'variable group' and youd have an indexed list already.

Are you sure theres no other way? Is there a score/status/whatever screen to tell you? and then does it give wear off (or whatever) messages? Id hate to think a timer would be the only way.

~Flannel

Messiah of Rose
Eternity's Trials.

Clones are people two.
Top

Posted by Poromenos   Greece  (1,037 posts)  Bio
Date Reply #2 on Sat 10 Jul 2004 11:59 PM (UTC)
Message
Could you tell us a bit about how afflictions work? I have no idea what they are...

Vidi, Vici, Veni.
http://porocrom.poromenos.org/ Read it!
Top

Posted by Magnum   Canada  (580 posts)  Bio
Date Reply #3 on Sun 11 Jul 2004 03:33 AM (UTC)
Message
Is this thread appropriate for you too?

http://www.gammon.com.au/forum/bbshowpost.php?bbsubject_id=4347&page=1

Get my plugins here: http://www.magnumsworld.com/muds/

Constantly proving I don't know what I am doing...
Magnum.
Top

The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).

To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.


18,757 views.

It is now over 60 days since the last post. This thread is closed.     Refresh page

Go to topic:           Search the forum


[Go to top] top

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.