working world-glow blend

This commit is contained in:
minjaesong
2017-07-11 13:34:14 +09:00
parent 3ffdd7233f
commit 1e9c04d7c0
25 changed files with 391 additions and 234 deletions

View File

@@ -268,7 +268,7 @@ object LightmapRenderer {
val thisWall = Terrarum.ingame!!.world.getTileFromWall(x, y)
val thisTileLuminosity = BlockCodex[thisTerrain].luminosity // already been div by four
val thisTileOpacity = BlockCodex[thisTerrain].opacity // already been div by four
val sunLight = Terrarum.ingame!!.world.globalLight.cpy().mul(DIV_FLOAT, DIV_FLOAT, DIV_FLOAT, 1f)
val sunLight = Terrarum.ingame!!.world.globalLight.cpy().mul(DIV_FLOAT, DIV_FLOAT, DIV_FLOAT, DIV_FLOAT)
// MIX TILE
// open air
@@ -478,7 +478,7 @@ object LightmapRenderer {
* @param rgb2
* @return
*/
private infix fun Color.maxBlend(other: Color): Color {
infix fun Color.maxBlend(other: Color): Color {
return Color(
if (this.r > other.r) this.r else other.r,
if (this.g > other.g) this.g else other.g,