Package io.github.team6ENG.EscapeUni
Class Main
java.lang.Object
com.badlogic.gdx.Game
io.github.team6ENG.EscapeUni.Main
- All Implemented Interfaces:
com.badlogic.gdx.ApplicationListener
public class Main
extends com.badlogic.gdx.Game
Main class initialises the game
-
Field Summary
FieldsModifier and TypeFieldDescriptioncom.badlogic.gdx.graphics.g2d.SpriteBatchcom.badlogic.gdx.scenes.scene2d.ui.Skinintintintcom.badlogic.gdx.graphics.g2d.BitmapFontfloatfloatcom.badlogic.gdx.graphics.g2d.BitmapFontfloatfloatfinal intfinal intfinal intcom.badlogic.gdx.utils.viewport.FitViewportFields inherited from class com.badlogic.gdx.Game
screen -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcreate()Initialise global game variablesvoiddispose()Called when theApplicationis destroyed.voidrender()Called when theApplicationshould render itself.voidReset game and return to the main menuvoidresize(int width, int height) Called when theApplicationis resized.voidsetInputProcessor(com.badlogic.gdx.InputProcessor processor) Methods inherited from class com.badlogic.gdx.Game
getScreen, pause, resume, setScreen
-
Field Details
-
batch
public com.badlogic.gdx.graphics.g2d.SpriteBatch batch -
gameFont
public com.badlogic.gdx.graphics.g2d.BitmapFont gameFont -
viewport
public com.badlogic.gdx.utils.viewport.FitViewport viewport -
buttonSkin
public com.badlogic.gdx.scenes.scene2d.ui.Skin buttonSkin -
activeSpritePath
-
activeUniIDPath
-
gameTimer
public float gameTimer -
score
public float score -
gameVolume
public float gameVolume -
musicVolume
public float musicVolume -
totalNegativeEvents
public final int totalNegativeEvents- See Also:
-
totalPositiveEvents
public final int totalPositiveEvents- See Also:
-
totalHiddenEvents
public final int totalHiddenEvents- See Also:
-
foundNegativeEvents
public int foundNegativeEvents -
foundPositiveEvents
public int foundPositiveEvents -
foundHiddenEvents
public int foundHiddenEvents
-
-
Constructor Details
-
Main
public Main()
-
-
Method Details
-
create
public void create()Initialise global game variables -
resetGame
public void resetGame()Reset game and return to the main menu -
resize
public void resize(int width, int height) Description copied from interface:com.badlogic.gdx.ApplicationListenerCalled when theApplicationis resized. This can happen at any point during a non-paused state but will never happen before a call toApplicationListener.create().- Specified by:
resizein interfacecom.badlogic.gdx.ApplicationListener- Overrides:
resizein classcom.badlogic.gdx.Game- Parameters:
width- the new width in pixelsheight- the new height in pixels
-
setInputProcessor
public void setInputProcessor(com.badlogic.gdx.InputProcessor processor) -
render
public void render()Description copied from interface:com.badlogic.gdx.ApplicationListenerCalled when theApplicationshould render itself.- Specified by:
renderin interfacecom.badlogic.gdx.ApplicationListener- Overrides:
renderin classcom.badlogic.gdx.Game
-
dispose
public void dispose()Description copied from interface:com.badlogic.gdx.ApplicationListenerCalled when theApplicationis destroyed. Preceded by a call toApplicationListener.pause().- Specified by:
disposein interfacecom.badlogic.gdx.ApplicationListener- Overrides:
disposein classcom.badlogic.gdx.Game
-