Dice Roll

Be sure your league is setup properly before installing any scripts.Setup Video
To create a random draft order , install the Dice Roll script into any of your homepagemessage and display on your site where you want. This radon generator will roll virtual dice and give each owner a number which can be used to determine your leagues draft order. You can use the included "var" settings and set your icon sizing and how many dice and number of side per dice.
This script can be installed in a homepagemessage and linked to or placed on home page.
The directory contains an "uncompressed" version of this script to allow for editing and self hosting. See below for instructions
All scripts require cache.js and font awesome file to be placed in a header message as the 1st line. Please review the section "Custom Scripts" Here
This script is already included in our custom template. Do not install it again. Custom template users do not need to load cache.js or font awesome.

Dice Roll JSPlace in any HPM

<!-- DICE ROLL -->

<!--- START DICE ROLL HTML --->
<div class="mobile-wrap">
    <table class="homepagemodule report" id="dice_roll" cellspacing="1" align="center">
                  <!--- EDIT HERE TO RENAME CAPTION FOR DICE ROLL --->
        <caption><span>Draft Dice Roll</span></caption>  
        <tr>
                  <!--- EDIT HERE TO RENAME TH FOR DICE ROLL --->
          <th>Official Dice Roll</th>   
        </tr>
        <tr class="oddtablerow">
          <td>  
                  <!--- EDIT HERE FOR INSTRUCTION OF YOUR DICE ROLL --->
            When you click the "Roll the Dice" button you will be rolling 20/5000 sided dice randomly to determine your position in this years draft.<br>Each owner can roll the dice 1 time , once rolled your results will display in the table below and you will not be able to roll again.<br><br>Highest roll gets 1st pick and so on and so fourth.<br><br>Good Luck!
          </td>
        </tr>
        <tr id="dicebtn_here" class="eventablerow">
          <td id="diceRollResult" align="center" style="display:none"></td>
        </tr>
    </table>
</div>

<script>
var numOfDices              = 20;     //Enter number of dice
var numOfSides              = 5000;   //Enter how many sides each dice have
var diceFranchiseIconHeight = 25;     //Must enter height of icon
var diceFranchiseIconWidth  = 150;    //Must enter width of icon
</script>

<script src="https://www.mflscripts.com/mfl-apps/diceRoll/script.js"></script>

<script>
setInterval(function() {
            showLeagueDiceRollResultsForCommish();
}, 5000);
</script>

Dice Roll CSSPlace in CSS

<style>
/***************************************/


/*           DICE ROLL SCRIPT          */


/***************************************/

td#diceRollResult table th,
td#diceRollResult table td {
  text-align:center
}

td#diceRollResult table th:first-of-type,
td#diceRollResult table td:first-of-type {
  text-align:left
}

td#diceRollResult table td:last-of-type {
  font-weight:bold;
  color:#ff4200;
  
}

td#diceRollResult table tr:nth-child(2) > td:nth-child(1):before {
  content:"1.";
  padding-right:5px;
}

td#diceRollResult table tr:nth-child(3) > td:nth-child(1):before {
  content:"2.";
  padding-right:5px;
}

td#diceRollResult table tr:nth-child(4) > td:nth-child(1):before {
  content:"3.";
  padding-right:5px;
}

td#diceRollResult table tr:nth-child(5) > td:nth-child(1):before {
  content:"4.";
  padding-right:5px;
}

td#diceRollResult table tr:nth-child(6) > td:nth-child(1):before {
  content:"5.";
  padding-right:5px;
}

td#diceRollResult table tr:nth-child(7) > td:nth-child(1):before {
  content:"6.";
  padding-right:5px;
}

td#diceRollResult table tr:nth-child(8) > td:nth-child(1):before {
  content:"7.";
  padding-right:5px;
}

td#diceRollResult table tr:nth-child(9) > td:nth-child(1):before {
  content:"8.";
  padding-right:5px;
}

td#diceRollResult table tr:nth-child(10) > td:nth-child(1):before {
  content:"9.";
  padding-right:5px;
}

td#diceRollResult table tr:nth-child(11) > td:nth-child(1):before {
  content:"10.";
  padding-right:5px;
}

td#diceRollResult table tr:nth-child(12) > td:nth-child(1):before {
  content:"11.";
  padding-right:5px;
}

td#diceRollResult table tr:nth-child(13) > td:nth-child(1):before {
  content:"12.";
  padding-right:5px;
}

td#diceRollResult table tr:nth-child(14) > td:nth-child(1):before {
  content:"13.";
  padding-right:5px;
}

td#diceRollResult table tr:nth-child(15) > td:nth-child(1):before {
  content:"14.";
  padding-right:5px;
}

td#diceRollResult table tr:nth-child(16) > td:nth-child(1):before {
  content:"15.";
  padding-right:5px;
}

td#diceRollResult table tr:nth-child(17) > td:nth-child(1):before {
  content:"16.";
  padding-right:5px;
}

td#diceRollResult table td:first-of-type:before {
  width:24px;
  display:inline-block;
  text-align:center;
  vertical-align:middle
}
</style>