Package nl.saxion.app.interaction
Interface GameLoop
public interface GameLoop
Interface for building simple games with the SaxionApp.
The loop method is the main method that should contain the (re)drawing of your application.
-
Method Summary
-
Method Details
-
init
void init()Method that will be executed before the loop starts. Use this method to initialize your state variables. This method can be called again to reset the application. Note: don't do any drawing in this method!!! -
loop
void loop()Method that will be executed every n milliseconds. This amount can be defined when you start the SaxionApp and adjusted by using the `SaxionApp.setGameLoopTimeMs(int ms)` method. -
keyboardEvent
This method will be called when there is keyboard interaction.- Parameters:
e
- details about the keyboard event
-
mouseEvent
This method will be called when there is mouse interaction.- Parameters:
e
- details about the mouse event
-