mirror of
https://github.com/collinsmith/riiablo.git
synced 2025-01-30 01:20:25 +07:00
Set conditional for debug rendering to improve performance on mobile
This commit is contained in:
parent
7b70ff819b
commit
4e374c946d
@ -592,11 +592,13 @@ public class GameScreen extends ScreenAdapter implements LoadingScreen.Loadable
|
||||
mapRenderer.draw(delta);
|
||||
b.end();
|
||||
|
||||
Riiablo.shapes.setAutoShapeType(true);
|
||||
Riiablo.shapes.begin(ShapeRenderer.ShapeType.Line);
|
||||
mapRenderer.drawDebug(Riiablo.shapes);
|
||||
mapRenderer.drawDebugPath(Riiablo.shapes, player.path());
|
||||
Riiablo.shapes.end();
|
||||
if (Gdx.app.getType() == Application.ApplicationType.Desktop) {
|
||||
Riiablo.shapes.setAutoShapeType(true);
|
||||
Riiablo.shapes.begin(ShapeRenderer.ShapeType.Line);
|
||||
mapRenderer.drawDebug(Riiablo.shapes);
|
||||
mapRenderer.drawDebugPath(Riiablo.shapes, player.path());
|
||||
Riiablo.shapes.end();
|
||||
}
|
||||
|
||||
b.setProjectionMatrix(viewport.getCamera().combined);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user