Skip to content

__Randomizer__

Hyomoto edited this page Jun 24, 2021 · 1 revision
Jump To Go Back Methods Variables

Randomizer( )

Implements: Struct

A template for creating psuedorandom number generators. By itself it produces no output, as it must be extended to produce a result.

Methods

Jump To top next seed next_int next_range

next( )

Returns: int

Name Type Purpose
None

Returns the next random integer from the generator.


seed( seed )

Returns: self

Name Type Purpose
seed int The seed to set the number generator to.

Sets the starting seed for the randomizer.


next_int( end )

Returns: int

Name Type Purpose
end int The end number

Returns a number between 0 and end inclusive.


next_range( start, end )

Returns: int

Name Type Purpose
start int The start number
end int The end number

Returns a number between start and end inclusive.


Variables

Jump To top
Name Type Initial Purpose
__State int 0 The internal state of the randomizer
Clone this wiki locally