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


Joined: 09 Feb 2005
Posts: 1

PostPosted: Thu Feb 10, 2005 12:22 am   

Help! Autoroller from H3ll!
 
This is the EXACT way the text on the roll looks:

+---------------------------------+
Strength : 16
Intelligence : 17
Wisdom : 16
Dexterity : 13
Constitution : 17
+---------------------------------+

Do you accept these stats (No to reroll) (y/n)?


With blank space at the bottom and all. Now here's my ATTEMPT at a roller:
#CLASS {Autoroller}
#TR {Strength%s:%s(%d)} {#VA str %1}
#TR {Intelligence%s:%s(%d)} {#VA int %1}
#TR {Wisdom%s:%s(%d)} {#VA wis %1}
#TR {Dexterity%s:%s(%d)} {#VA dex %1}
#TR {Constitution%s:%s(%d)} {#VA con %1}
// My next trigger is "Do you accept these stats" and it is clicked on newline //
#va reroll 0
#if (@str<10 & @int<10 & @wis<10 & @dex<10 & @con=20) {#va reroll 1}
#if (@reroll=1) {yes} {no}

Can someone help me with a roller, because this one doesn't seem to work at all.
Reply with quote
Maelstrom
Apprentice


Joined: 10 Feb 2005
Posts: 158

PostPosted: Thu Feb 10, 2005 3:12 am   
 
For some reason the last trigger with the bitwise &s not working right. Couldnt say for certain why not though. Looks correct. Anyways, cleaned up the multiple triggers with conditionals instead and removed all but one variable. You might have to set last condition to prompt instead of newline to work right depending on how it comes in from the mud.


#TRIGGER {^Strength : (%d)} {#VARIABLE StatsOk {1};#IF %1<10 {#VARIABLE StatsOk {0}}} "Autoroller" {case|notrig}
#COND {^Intelligence : (%d)} {#IF %1<10 {#VA StatsOk {0}}}
#COND {^Wisdom : (%d)} {#IF %1<10 {#VA StatsOk {0}}}
#COND {^Dexterity : (%d)} {#IF %1<10 {#VA StatsOk {0}}}
#COND {^Constitution : (%d)} {#IF %1<10 {#VA StatsOk {0}}}
#COND {^Do you accept these stats ~(No to reroll~) ~(y/n~)~?} {#IF @StatsOk=1 {#SEND {y}} {#SEND {n}}} {case|notrig}

Mr. Green
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