C# Class Sharpex2D.GameRandom

Afficher le fichier Open project: ThuCommix/Sharpex2D Class Usage Examples

Méthodes publiques

Méthode Description
GameRandom ( ) : System

Initializes a new GameRandom.

Next ( ) : int

Returns Int32 between Int32 min - and max value.

Next ( int max ) : int

Returns Int32 between 0 and max.

Next ( int min, int max ) : int

Returns Int32 between min and max.

NextBoolean ( ) : bool

Returns true or false.

NextBoolean ( double probability ) : bool

Returns true or false based on the probability.

NextDouble ( ) : double

Returns a double between 0 and 1.

NextFloat ( ) : float

Returns a float between 0 and 1.

Method Details

GameRandom() public méthode

Initializes a new GameRandom.
public GameRandom ( ) : System
Résultat System

Next() public méthode

Returns Int32 between Int32 min - and max value.
public Next ( ) : int
Résultat int

Next() public méthode

Returns Int32 between 0 and max.
public Next ( int max ) : int
max int The Maximum.
Résultat int

Next() public méthode

Returns Int32 between min and max.
public Next ( int min, int max ) : int
min int The Minimum.
max int The Maximum.
Résultat int

NextBoolean() public méthode

Returns true or false.
public NextBoolean ( ) : bool
Résultat bool

NextBoolean() public méthode

Returns true or false based on the probability.
public NextBoolean ( double probability ) : bool
probability double The Probability.
Résultat bool

NextDouble() public méthode

Returns a double between 0 and 1.
public NextDouble ( ) : double
Résultat double

NextFloat() public méthode

Returns a float between 0 and 1.
public NextFloat ( ) : float
Résultat float