This is a big commit. Added mouse cursors and a load bar. Started whit the game. and many many other things

This commit is contained in:
Ziver Koc 2007-03-29 23:21:00 +00:00
parent 448fca2fdf
commit 4e7722fedb
34 changed files with 597 additions and 95 deletions

View file

@ -1,11 +1,24 @@
package ei.engine.state;
import ei.engine.input.InputHandler;
public abstract class GameState {
private String name;
private InputHandler input;
private boolean enabled = false;
public GameState(String name){
this.name = name;
input = new InputHandler();
}
/**
* Returns the input handler of this state
*
* @return The input handler
*/
public InputHandler getInput(){
return input;
}
/**
@ -30,6 +43,24 @@ public abstract class GameState {
return name;
}
/**
* Updates the State
*
*/
public void stateUpdate(){
input.update();
update();
}
/**
* Renders the state
*
*/
public void stateRender(){
render();
input.render();
}
public abstract void update();
public abstract void render();