mirror of
https://github.com/curioustorvald/Terrarum.git
synced 2026-06-14 20:44:05 +09:00
finaly fixing 720p bug (issue #36)
This commit is contained in:
@@ -208,10 +208,10 @@ public class AppLoader implements ApplicationListener {
|
||||
|
||||
public static ArrayListMap debugTimers = new ArrayListMap<String, Long>();
|
||||
|
||||
public static final int defaultW = 1116;
|
||||
public static final int defaultH = 744;
|
||||
public static final int minimumW = 1080;
|
||||
public static final int minimumH = 722;
|
||||
public static final int defaultW = 1280;
|
||||
public static final int defaultH = 720;
|
||||
public static final int minimumW = 800;
|
||||
public static final int minimumH = 600;
|
||||
|
||||
public static final String FONT_DIR = "assets/graphics/fonts/terrarum-sans-bitmap";
|
||||
|
||||
|
||||
@@ -51,10 +51,10 @@ object IngameRenderer : Disposable {
|
||||
val shaderAtoGrey: ShaderProgram
|
||||
val shaderPassthru = SpriteBatch.createDefaultShader()
|
||||
|
||||
private val width = AppLoader.screenW
|
||||
private val height = AppLoader.screenH
|
||||
private val widthf = width.toFloat()
|
||||
private val heightf = height.toFloat()
|
||||
private val WIDTH = AppLoader.screenW
|
||||
private val HEIGHT = AppLoader.screenH
|
||||
private val WIDTHF = WIDTH.toFloat()
|
||||
private val HEIGHTF = HEIGHT.toFloat()
|
||||
|
||||
private var initDone = false
|
||||
|
||||
@@ -586,13 +586,13 @@ object IngameRenderer : Disposable {
|
||||
private fun invokeInit() {
|
||||
if (!initDone) {
|
||||
batch = SpriteBatch()
|
||||
camera = OrthographicCamera(widthf, heightf)
|
||||
camera = OrthographicCamera(WIDTHF, HEIGHTF)
|
||||
|
||||
camera.setToOrtho(true, widthf, heightf)
|
||||
camera.setToOrtho(true, WIDTHF, HEIGHTF)
|
||||
camera.update()
|
||||
Gdx.gl20.glViewport(0, 0, width, height)
|
||||
Gdx.gl20.glViewport(0, 0, WIDTH, HEIGHT)
|
||||
|
||||
resize(width, height)
|
||||
resize(WIDTH, HEIGHT)
|
||||
|
||||
initDone = true
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user