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
Zalhain
Newbie


Joined: 05 Aug 2005
Posts: 3

PostPosted: Fri Aug 05, 2005 12:08 pm   

Autoroller for Realms of Despair
 
I just downloaded the trial version of zMud last night, and I'm wanting to make sure that it can do everything that I am wanting it to do before I buy it. I figure that if it can do an autoroller script that is a great start along the path of progress. :)

Anyway, here is the output of the mud:
Code:
Your character's base stats have been rerolled...
                     New             Previous
Strength              XX                   XX
Dexterity             XX                   XX
Intelligence          XX                   XX
Wisdom                XX                   XX
Charisma              XX                   XX
Constitution          XX                   XX
Luck                  XX                   XX


obviously I don't really care what the previous values are, I'm just wanting to be able to set conditions on the new values to where if they do not fall into a given range, it will reroll untill they do.
Reply with quote
Guinn
Wizard


Joined: 03 Mar 2001
Posts: 1127
Location: London

PostPosted: Fri Aug 05, 2005 1:28 pm   
 
Code:
#REGEX {(Strength|Dexterity|Intelligence|Wisdom|Charisma|Constitution|Luck)\s+(\d+)\s+\d+$} {
  #var roll%1 {%2} {}
  #if (%1 = "Luck") {#var rollAccept {1} {0}
    #if (@rollStrength < 10) {rollAccept = 0}
    #if (@rollDexterity < 10) {rollAccept = 0}
    #if (@rollIntelligence < 10) {rollAccept = 0}
    #if (@rollWisdom < 10) {rollAccept = 0}
    #if (@rollCharisma < 10) {rollAccept = 0}
    #if (@rollConstitution < 10) {rollAccept = 0}
    #if (@rollLuck < 10) {rollAccept = 0}
    #if (@rollAccept = 1) {accept} {reroll}
    }
  }


Then change the values from 10 to whatever you need.
_________________
CMUD Pro, Windows Vista x64
Core2 Q6600, 4GB RAM, GeForce 8800GT
Because you need it for text... ;)
Reply with quote
Zalhain
Newbie


Joined: 05 Aug 2005
Posts: 3

PostPosted: Fri Aug 05, 2005 5:32 pm   
 
Sorry for the newbness here but I can't seem to get this one to work. When I type reroll into the MUD it returns this:


Code:
Your character's base stats have been rerolled...
                     New             Previous
Strength              13                   14
{ #var rollStrength {13} {} #if (Strength = Luck) {#var rollAccept {1} {0} #if ( < 16) {rollAccept = 0} #if ( < 16) {rollAccept = 0} #if ( < 16) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( < 19) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( = 1) {accept} {reroll} } }
Dexterity             18                   18
{ #var rollDexterity {18} {} #if (Dexterity = Luck) {#var rollAccept {1} {0} #if ( < 16) {rollAccept = 0} #if ( < 16) {rollAccept = 0} #if ( < 16) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( < 19) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( = 1) {accept} {reroll} } }
Intelligence          14                   15
{ #var rollIntelligence {14} {} #if (Intelligence = Luck) {#var rollAccept {1} {0} #if ( < 16) {rollAccept = 0} #if ( < 16) {rollAccept = 0} #if ( < 16) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( < 19) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( = 1) {accept} {reroll} } }
Wisdom                12                   13
{ #var rollWisdom {12} {} #if (Wisdom = Luck) {#var rollAccept {1} {0} #if ( < 16) {rollAccept = 0} #if ( < 16) {rollAccept = 0} #if ( < 16) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( < 19) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( = 1) {accept} {reroll} } }
Charisma              11                    9
{ #var rollCharisma {11} {} #if (Charisma = Luck) {#var rollAccept {1} {0} #if ( < 16) {rollAccept = 0} #if ( < 16) {rollAccept = 0} #if ( < 16) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( < 19) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( = 1) {accept} {reroll} } }
Constitution          13                   11
{ #var rollConstitution {13} {} #if (Constitution = Luck) {#var rollAccept {1} {0} #if ( < 16) {rollAccept = 0} #if ( < 16) {rollAccept = 0} #if ( < 16) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( < 19) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( = 1) {accept} {reroll} } }
Luck                  14                   15
{ #var rollLuck {14} {} #if (Luck = Luck) {#var rollAccept {1} {0} #if ( < 16) {rollAccept = 0} #if ( < 16) {rollAccept = 0} #if ( < 16) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( < 19) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( < 10) {rollAccept = 0} #if ( = 1) {accept} {reroll} } }

Followed by a swift disconnect from the MUD server.
Reply with quote
Zalhain
Newbie


Joined: 05 Aug 2005
Posts: 3

PostPosted: Fri Aug 05, 2005 6:02 pm   
 
Okay, so I have that problem figured out, now for the next one Realms of Despair rerolls ALL stats at the same time, so it can look something like this:
Code:

Your character's base stats have been rerolled...
                     New             Previous
Strength              16                   12
Dexterity             18                   18
Intelligence          13                   14
Wisdom                12                   13
Charisma              10                    9
Constitution          12                   13
Luck                  14                   16

Then the next one would be:

Your character's base stats have been rerolled...
                     New             Previous
Strength              13                   16
Dexterity             18                   18
Intelligence          14                   14
Wisdom                15                   12
Charisma               9                    9
Constitution          11                   12
Luck                  15                   14



My character needs a high strength, dex, and int. So I want those to be 16 or higher. How do I go about configuring this trigger to only send one reroll per loop? As well as recognizing when to stop when the values are at the right levels.
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