ManiaMap.Godot
Procedural generation of metroidvania style maps for Godot .NET.
Rand Class Reference

Contains the random number generator used for ID and random seed assignments. More...

Static Public Member Functions

static int AutoAssignId (int id)
 If the specified ID is less than or equal to zero, returns a new random positive integer ID. Otherwise, returns the ID. More...
 
static RandomSeed CreateRandomSeed (int seed)
 Returns a new RandomSeed object for the given seed. If the specified seed is less than or equal to zero, a random positive integer seed is used instead. More...
 
static int GetRandomId ()
 Returns a random positive integer ID. More...
 

Properties

static Random Random = new Random() [get]
 

Detailed Description

Contains the random number generator used for ID and random seed assignments.

Definition at line 9 of file Rand.cs.

Member Function Documentation

◆ AutoAssignId()

static int AutoAssignId ( int  id)
static

If the specified ID is less than or equal to zero, returns a new random positive integer ID. Otherwise, returns the ID.

Parameters
idThe input ID.

Definition at line 18 of file Rand.cs.

◆ CreateRandomSeed()

static RandomSeed CreateRandomSeed ( int  seed)
static

Returns a new RandomSeed object for the given seed. If the specified seed is less than or equal to zero, a random positive integer seed is used instead.

Parameters
seedThe random seed.

Definition at line 36 of file Rand.cs.

◆ GetRandomId()

static int GetRandomId ( )
static

Returns a random positive integer ID.

Definition at line 26 of file Rand.cs.

Property Documentation

◆ Random

Random Random = new Random()
staticget

Definition at line 11 of file Rand.cs.


The documentation for this class was generated from the following file: