1
0
mirror of https://github.com/Klagarge/PokeHES.git synced 2025-07-07 17:01:10 +00:00

switch screen

This commit is contained in:
2022-06-10 18:49:02 +02:00
parent df732ad57f
commit 697c9e659f
6 changed files with 44 additions and 22 deletions

View File

@ -79,8 +79,13 @@ public class ScreenMap extends RenderingScreen{
// Render the tileMap
g.zoom(zoom);
g.moveCamera(player.getPosition().x, player.getPosition().y, width * tileWidth, height * tileHeight);
try {
g.zoom(zoom);
g.moveCamera(player.getPosition().x, player.getPosition().y, width * tileWidth, height * tileHeight);
} catch (Exception e) {
//TODO: handle exception
}
tMapRenderer.get(map).setView(g.getCamera());
tMapRenderer.get(map).render();