Add update loop

This commit is contained in:
Matt Low 2018-11-10 21:40:13 +04:00
parent dd6aa7da5f
commit c9fda66879

View File

@ -18,11 +18,12 @@ public class BrickBuster extends ApplicationAdapter {
@Override @Override
public void create () { public void create () {
this.shapeRenderer = new ShapeRenderer(); this.shapeRenderer = new ShapeRenderer();
} }
@Override @Override
public void render () { public void render () {
update(Gdx.graphics.getDeltaTime());
Gdx.gl.glClearColor(0.5f,1,1,1); Gdx.gl.glClearColor(0.5f,1,1,1);
Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT); Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT);
this.shapeRenderer.begin(ShapeType.Filled); this.shapeRenderer.begin(ShapeType.Filled);
@ -31,7 +32,12 @@ public class BrickBuster extends ApplicationAdapter {
this.shapeRenderer.end(); this.shapeRenderer.end();
} }
@Override
public void update(float dt) {
}
@Override @Override
public void dispose () { public void dispose () {