Quantum Engineering
Public Member Functions | Public Attributes | Private Member Functions | Private Attributes | List of all members
MainMenu Class Reference
Inheritance diagram for MainMenu:

Public Member Functions

void Start ()
 Called by unity engine on start up to initialize variables. More...
 
void Update ()
 Called once per frame by unity engine. More...
 
void OnGUI ()
 Called by unity engine for rendering and handling GUI events. More...
 

Public Attributes

GUISkin thisGUIskin
 
Texture2D titleTexture
 
Texture2D title2Texture
 
Texture2D titleTextureSD
 
Texture2D guiBackground
 
Texture2D worldListBackground
 
Texture2D playerModel
 
GameObject videoPlayer
 
GameObject menuSoundObject
 
GameObject ambientSoundObject
 
bool worldSelected
 
bool finishedLoading
 

Private Member Functions

string GetLocalAddress ()
 Gets the local address for LAN games. More...
 
string GetExternalAddress ()
 Gets external IP address for online games. More...
 
void SetupDedicatedServer (string[] commandLineOptions)
 Sets up a dedicated server. More...
 
void StartServer ()
 Starts the external server program. More...
 
void DownloadWorld ()
 Downloads saved world from server. More...
 
void SelectWorld ()
 Confirms world selection and loads the world. More...
 
void PreStart ()
 Selects the scene and starts the game. More...
 
void ChangeScene ()
 Called when Kepler-1625 or Kepler-452b is selected and the scene needs to be changed. More...
 
void StartGame ()
 Called when Gliese 876 is selected and the scene does not need to be changed. More...
 
Vector2 GetStringSize (string str)
 Gets the size of in pixels of text so it can be positioned on the screen accordingly. More...
 
bool GuiFree ()
 Returns true if the GUI is available. More...
 
bool LoadingWorld ()
 Returns true if the world is currently being loaded. More...
 

Private Attributes

Texture2D colorSelectTexture
 
string worldName = "Enter world name."
 
string username = "Enter user name."
 
string serverURL = "Enter server IP address."
 
string [] worlds
 
StateManager stateManager
 
List< string > worldList
 
AudioSource buttonSounds
 
AudioSource ambient
 
int scene
 
bool local
 
float waitForVideoTimer
 
bool notWideScreen
 
bool worldSelectPrompt
 
bool playingVideo
 
bool hosting
 
bool downloadPrompt
 
bool worldNamePrompt
 
bool deletePrompt
 
bool escapePrompt
 
bool multiplayerPrompt
 
bool localPrompt
 
bool playerColorPrompt
 
bool userNamePrompt
 
bool networkAddressPrompt
 
float playerRed = 1.0f
 
float playerGreen = 1.0f
 
float playerBlue = 1.0f
 

Member Function Documentation

◆ ChangeScene()

void MainMenu.ChangeScene ( )
inlineprivate

Called when Kepler-1625 or Kepler-452b is selected and the scene needs to be changed.

◆ DownloadWorld()

void MainMenu.DownloadWorld ( )
inlineprivate

Downloads saved world from server.

◆ GetExternalAddress()

string MainMenu.GetExternalAddress ( )
inlineprivate

Gets external IP address for online games.

◆ GetLocalAddress()

string MainMenu.GetLocalAddress ( )
inlineprivate

Gets the local address for LAN games.

◆ GetStringSize()

Vector2 MainMenu.GetStringSize ( string  str)
inlineprivate

Gets the size of in pixels of text so it can be positioned on the screen accordingly.

◆ GuiFree()

bool MainMenu.GuiFree ( )
inlineprivate

Returns true if the GUI is available.

◆ LoadingWorld()

bool MainMenu.LoadingWorld ( )
inlineprivate

Returns true if the world is currently being loaded.

◆ OnGUI()

void MainMenu.OnGUI ( )
inline

Called by unity engine for rendering and handling GUI events.

◆ PreStart()

void MainMenu.PreStart ( )
inlineprivate

Selects the scene and starts the game.

◆ SelectWorld()

void MainMenu.SelectWorld ( )
inlineprivate

Confirms world selection and loads the world.

◆ SetupDedicatedServer()

void MainMenu.SetupDedicatedServer ( string []  commandLineOptions)
inlineprivate

Sets up a dedicated server.

◆ Start()

void MainMenu.Start ( )
inline

Called by unity engine on start up to initialize variables.

◆ StartGame()

void MainMenu.StartGame ( )
inlineprivate

Called when Gliese 876 is selected and the scene does not need to be changed.

◆ StartServer()

void MainMenu.StartServer ( )
inlineprivate

Starts the external server program.

◆ Update()

void MainMenu.Update ( )
inline

Called once per frame by unity engine.

Member Data Documentation

◆ ambient

AudioSource MainMenu.ambient
private

◆ ambientSoundObject

GameObject MainMenu.ambientSoundObject

◆ buttonSounds

AudioSource MainMenu.buttonSounds
private

◆ colorSelectTexture

Texture2D MainMenu.colorSelectTexture
private

◆ deletePrompt

bool MainMenu.deletePrompt
private

◆ downloadPrompt

bool MainMenu.downloadPrompt
private

◆ escapePrompt

bool MainMenu.escapePrompt
private

◆ finishedLoading

bool MainMenu.finishedLoading

◆ guiBackground

Texture2D MainMenu.guiBackground

◆ hosting

bool MainMenu.hosting
private

◆ local

bool MainMenu.local
private

◆ localPrompt

bool MainMenu.localPrompt
private

◆ menuSoundObject

GameObject MainMenu.menuSoundObject

◆ multiplayerPrompt

bool MainMenu.multiplayerPrompt
private

◆ networkAddressPrompt

bool MainMenu.networkAddressPrompt
private

◆ notWideScreen

bool MainMenu.notWideScreen
private

◆ playerBlue

float MainMenu.playerBlue = 1.0f
private

◆ playerColorPrompt

bool MainMenu.playerColorPrompt
private

◆ playerGreen

float MainMenu.playerGreen = 1.0f
private

◆ playerModel

Texture2D MainMenu.playerModel

◆ playerRed

float MainMenu.playerRed = 1.0f
private

◆ playingVideo

bool MainMenu.playingVideo
private

◆ scene

int MainMenu.scene
private

◆ serverURL

string MainMenu.serverURL = "Enter server IP address."
private

◆ stateManager

StateManager MainMenu.stateManager
private

◆ thisGUIskin

GUISkin MainMenu.thisGUIskin

◆ title2Texture

Texture2D MainMenu.title2Texture

◆ titleTexture

Texture2D MainMenu.titleTexture

◆ titleTextureSD

Texture2D MainMenu.titleTextureSD

◆ username

string MainMenu.username = "Enter user name."
private

◆ userNamePrompt

bool MainMenu.userNamePrompt
private

◆ videoPlayer

GameObject MainMenu.videoPlayer

◆ waitForVideoTimer

float MainMenu.waitForVideoTimer
private

◆ worldList

List<string> MainMenu.worldList
private

◆ worldListBackground

Texture2D MainMenu.worldListBackground

◆ worldName

string MainMenu.worldName = "Enter world name."
private

◆ worldNamePrompt

bool MainMenu.worldNamePrompt
private

◆ worlds

string [] MainMenu.worlds
private

◆ worldSelected

bool MainMenu.worldSelected

◆ worldSelectPrompt

bool MainMenu.worldSelectPrompt
private

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