mirror of
https://github.com/curioustorvald/Terrarum.git
synced 2026-06-10 18:44:05 +09:00
"Continue" button on the titlescreen is working
This commit is contained in:
@@ -5,6 +5,7 @@ import com.badlogic.gdx.graphics.Pixmap
|
||||
import com.badlogic.gdx.graphics.Texture
|
||||
import net.torvald.terrarum.*
|
||||
import net.torvald.terrarum.gameworld.GameWorld
|
||||
import net.torvald.terrarum.ui.Toolkit
|
||||
import kotlin.math.roundToInt
|
||||
|
||||
/**
|
||||
@@ -67,9 +68,11 @@ class WorldgenLoadScreen(screenToBeLoaded: IngameInstance, private val worldwidt
|
||||
|
||||
App.batch.inUse {
|
||||
it.color = Color.WHITE
|
||||
val previewX = (App.scr.width - previewWidth).div(2f).round()
|
||||
val previewY = (App.scr.height - previewHeight.times(1.5f)).div(2f).round()
|
||||
Toolkit.drawBoxBorder(it, previewX.toInt()-1, previewY.toInt()-1, previewWidth+2, previewHeight+2)
|
||||
it.draw(previewTexture,
|
||||
(App.scr.width - previewWidth).div(2f).round(),
|
||||
previewX,
|
||||
previewY
|
||||
)
|
||||
val text = messages.getHeadElem() ?: ""
|
||||
|
||||
Reference in New Issue
Block a user