Beispiel #1
0
  // for VC
  // MORE FOR VC
  @Override
  public void render() {
    // Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT);
    batch.begin();

    if (ScreenManager.getCurrentScreen() != null) {
      ScreenManager.getCurrentScreen().render(batch);
    }
    if (ScreenManager.getCurrentScreen() != null) {
      ScreenManager.getCurrentScreen().update();
    }
    batch.end();
  }
Beispiel #2
0
 public void resize(int width, int height) {
   if (ScreenManager.getCurrentScreen() != null) {
     ScreenManager.getCurrentScreen().resize(width, height);
   }
 }
Beispiel #3
0
 public void dispose() {
   if (ScreenManager.getCurrentScreen() != null) {
     ScreenManager.getCurrentScreen().dispose();
   }
   batch = new SpriteBatch();
 }
Beispiel #4
0
 @Override
 public void create() { // batch is what lets images exist..I think. Rest of names are intuitive.
   batch = new SpriteBatch();
   ScreenManager.setScreen(new GameScreen());
 }