Modulus is so not fun enough.
Randomizing with Sortvalue
PHP Code:
// Loop through each player in the level
for (temp.pl: players) {
// Make sure they aren't part of the ET
if (temp.pl.guild != "Events Team") {
// Add Player to Temp Players Array
temp.plyrs.add(temp.pl);
// Assign the Player a Random Sortvalue
temp.plyrs[temp.plyrs.size()-1].sortvalue = random(0, 100);
}
}
// Sort the Array by Value
temp.plyrs.sortbyvalue("sortvalue", "float", false);
// Split the Array Appropriately and Assign Guild Tags
for (temp.pl: temp.plyrs) {
// Your other code here
}
It's not really necessary to use a randomizer since the order of the players array isn't exactly public knowledge but for a queuing system it might be something to prevent players from stacking teams.