lightsource randomiser hash will be same even when x < 0

This commit is contained in:
minjaesong
2020-02-24 14:46:37 +09:00
parent 0d8d6ca9fa
commit ad903952cc
4 changed files with 16 additions and 8 deletions

View File

@@ -674,10 +674,12 @@ object LightmapRenderer {
* - sunlight
*/
private fun getLightsAndShades(x: Int, y: Int) {
val (x, y) = world.coerceXY(x, y)
lightLevelThis.set(colourNull)
thisTerrain = world.getTileFromTerrain(x, y)
thisTerrain = world.getTileFromTerrainRaw(x, y)
thisFluid = world.getFluid(x, y)
thisWall = world.getTileFromWall(x, y)
thisWall = world.getTileFromWallRaw(x, y)
// regarding the issue #26
try {