text input pane wip

This commit is contained in:
minjaesong
2021-10-20 23:00:25 +09:00
parent 8a8e97d4b2
commit 9326b87909
34 changed files with 320 additions and 163 deletions

View File

@@ -26,9 +26,9 @@ import net.torvald.terrarum.gamecontroller.IngameController
import net.torvald.terrarum.gameworld.fmod
import net.torvald.terrarum.itemproperties.ItemCodex
import net.torvald.terrarum.itemproperties.MaterialCodex
import net.torvald.terrarum.serialise.Common
import net.torvald.terrarum.savegame.ByteArray64Reader
import net.torvald.terrarum.savegame.DiskSkimmer
import net.torvald.terrarum.serialise.Common
import net.torvald.terrarum.ui.UICanvas
import net.torvald.terrarum.worlddrawer.WorldCamera
import net.torvald.terrarumsansbitmap.gdx.GameFontBase
@@ -358,21 +358,6 @@ inline fun FrameBuffer.inAction(camera: OrthographicCamera?, batch: SpriteBatch?
}
// ShapeRenderer alternative for rects
fun SpriteBatch.fillRect(x: Float, y: Float, w: Float, h: Float) {
this.draw(App.textureWhiteSquare, x, y, w, h)
}
fun SpriteBatch.fillCircle(x: Float, y: Float, w: Float, h: Float) {
this.draw(App.textureWhiteCircle, x, y, w, h)
}
fun SpriteBatch.drawStraightLine(x: Float, y: Float, otherEnd: Float, thickness: Float, isVertical: Boolean) {
if (!isVertical)
this.fillRect(x, y, otherEnd - x, thickness)
else
this.fillRect(x, y, thickness, otherEnd - y)
}
infix fun Color.mul(other: Color): Color = this.cpy().mul(other)
infix fun Color.mulAndAssign(other: Color): Color {