MostFunGuy

MFG's Randomized letter stuff

Feb 17th, 2014
172
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
YAML 1.34 KB | None | 0 0
  1. command /randomizethatshityo:
  2.   trigger:
  3.  
  4.     # #!This will add all of our letters into the list variable, for easy randomization
  5.     add "a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y" and "z" to {_letters::*}
  6.    
  7.     # #! This is just to get the variable started, so the loops can take over
  8.     #set {_randomized} to a random element of {_letters::*}
  9.    
  10.     # #! This defaults the string to blank, so "<none>" doesn't appear for the first one
  11.     set {_randomized} to ""
  12.    
  13.     # #! This is to prevent the last dash from happening after the
  14.     set {_dashcap} to 3
  15.     set {_dashcount} to 0
  16.    
  17.     # #! Set this loop to however many sections of letters you want
  18.     loop 4 times:
  19.      # #! Set this loop to however many letters you want in each section
  20.       loop 5 times:
  21.        # #! This adds the newest letter into the string of text were creating
  22.         set {_randomized} to "%{_randomized}%<gold>%random element of {_letters::*}%"
  23.       set {_dashcount} to {_dashcount} + 1
  24.       if {_dashcount} is less or equal to {_dashcap}:
  25.        # #! This adds the dash into the string of text we're creating
  26.         set {_randomized} to "%{_randomized}%<purple>-"
  27.        
  28.     # #! This simply sends you the formatted message
  29.     message "%{_randomized}%"
Advertisement
Add Comment
Please, Sign In to add comment