The scrWeightedRandom function exists to choose a value with uneven/unequal probability. The function requires 3 parameters and has 1 optional parameter, which defaults to false, but can be changed to true for debugging purposes at runtime.
As a use case example, if you are making an RPG, and would like an enemy to drop certain item(s), but DON'T want the item(s) to all have the exact same chance of dropping for the player, you can use this function to change the likelihood that a particular item will drop, or even nothing at all, if you like.
End User Licence Agreement (EULA).
Updated README Documentation and Comments for better readability.