Class: Randomizer

Randomizer()

Helper class that manages randomization of controllers marked as randomizable. Handles toggling, adding/removing controllers, and triggering randomization.

Constructor

new Randomizer()

Constructs a new Randomizer instance.

Source:

Members

controllers :Array.<Controller>

Type:
Source:

Methods

addController(controller, doRandomize)

Adds a controller to the randomizer and attaches a DieIcon.

Parameters:
Name Type Description
controller Controller

The controller to add.

doRandomize boolean

Whether this controller should be randomized.

Source:

randomize()

Randomizes all controllers marked as randomizable and not hidden.

Source:

removeController(controller)

Removes a controller from the randomizer.

Parameters:
Name Type Description
controller Controller

The controller to remove.

Source:

toggleDoRandomize(die)

Toggles the randomization state for a controller via its DieIcon.

Parameters:
Name Type Description
die DieIcon

The DieIcon instance to toggle.

Source: