Add Chance and chance to window for easier usage in the browser