Midnight Blue Game and Engine
Public Member Functions | Properties | List of all members
MidnightBlue.GalaxyBuilder Class Reference
Collaboration diagram for MidnightBlue.GalaxyBuilder:
Collaboration graph

Public Member Functions

 GalaxyBuilder (ContentManager content, int size, int seed=0)
 Initializes a new instance of the T:MidnightBlue.GalaxyBuilder class. Does not actually generate the galaxy - that's done via Generate() More...
 
List< StarSystemGenerate (int maxDistance)
 Generates the galaxy with a specified max distance between stars. Takes a while so should be called only once per gameplay session. More...
 

Properties

Rectangle Bounds [get]
 Gets the bounding rectangle of the galaxy. More...
 
int Size [get]
 Gets the number of star systems the galaxy has. More...
 
bool Done [get]
 Gets a value indicating whether this T:MidnightBlue.GalaxyBuilder is done generating. More...
 
List< StarSystemStarSystems [get]
 Gets the star system list. More...
 

Constructor & Destructor Documentation

§ GalaxyBuilder()

MidnightBlue.GalaxyBuilder.GalaxyBuilder ( ContentManager  content,
int  size,
int  seed = 0 
)
inline

Initializes a new instance of the T:MidnightBlue.GalaxyBuilder class. Does not actually generate the galaxy - that's done via Generate()

Parameters
contentContent manager to use for loading resources.
sizeNumber of star systems to generate.
seedSeed to use for generation.

Member Function Documentation

§ Generate()

List<StarSystem> MidnightBlue.GalaxyBuilder.Generate ( int  maxDistance)
inline

Generates the galaxy with a specified max distance between stars. Takes a while so should be called only once per gameplay session.

Parameters
maxDistanceMax distance between generated star systems.
Here is the caller graph for this function:

Property Documentation

§ Bounds

Rectangle MidnightBlue.GalaxyBuilder.Bounds
get

Gets the bounding rectangle of the galaxy.

The bounds.

§ Done

bool MidnightBlue.GalaxyBuilder.Done
get

Gets a value indicating whether this T:MidnightBlue.GalaxyBuilder is done generating.

true if done; otherwise, false.

§ Size

int MidnightBlue.GalaxyBuilder.Size
get

Gets the number of star systems the galaxy has.

The number of star systems.

§ StarSystems

List<StarSystem> MidnightBlue.GalaxyBuilder.StarSystems
get

Gets the star system list.

The star systems.


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