fake gradient background for menu buttons on titlescreen to increase contrast

This commit is contained in:
minjaesong
2021-09-09 10:08:29 +09:00
parent 8f834fe869
commit 7386181cff
2 changed files with 7 additions and 6 deletions

View File

@@ -148,14 +148,14 @@ class TitleScreen(batch: SpriteBatch) : IngameInstance(batch) {
val off3 = cameraNodes[(i+3) fmod cameraNodes.size] * 0.025f
cameraNodes[i] = offM3 + offM2 + offM1 + off0 + off1 + off2 + off3
println(cameraNodes[i])
// println(cameraNodes[i])
}
cameraPlayer = CameraPlayer(demoWorld, cameraAI)
demoWorld.worldTime.timeDelta = 100
demoWorld.worldTime.timeDelta = 0//100
IngameRenderer.setRenderedWorld(demoWorld)
@@ -168,6 +168,8 @@ class TitleScreen(batch: SpriteBatch) : IngameInstance(batch) {
// fake UI for gradient overlay
val uiFakeGradOverlay = UIFakeGradOverlay()
uiFakeGradOverlay.setPosition(0, 0)
uiContainer.add(uiFakeGradOverlay)
uiMenu = UIRemoCon(UITitleRemoConYaml())//UITitleRemoConRoot()

View File

@@ -27,11 +27,10 @@ class UIFakeGradOverlay : UICanvas() {
override fun updateUI(delta: Float) {}
override fun renderUI(batch: SpriteBatch, camera: Camera) {
gdxSetBlendMul()
blendMul(batch)
batch.draw(tex, 0f, 0f, App.scr.halfwf * 1.5f, App.scr.hf)
batch.draw(tex, 0f, 0f, App.scr.wf, App.scr.hf)
gdxSetBlendNormal()
blendNormal(batch)
}
override fun doOpening(delta: Float) {}