mirror of
https://github.com/yairm210/Unciv.git
synced 2025-07-22 13:49:54 +07:00
Natural wonders (and other terrains with no RGB) now have a golden color on the minimap
This commit is contained in:
@ -2,8 +2,8 @@ package com.unciv.models.ruleset.tile
|
|||||||
|
|
||||||
import com.badlogic.gdx.graphics.Color
|
import com.badlogic.gdx.graphics.Color
|
||||||
import com.unciv.models.ruleset.Ruleset
|
import com.unciv.models.ruleset.Ruleset
|
||||||
import com.unciv.models.translations.tr
|
|
||||||
import com.unciv.models.stats.NamedStats
|
import com.unciv.models.stats.NamedStats
|
||||||
|
import com.unciv.models.translations.tr
|
||||||
import com.unciv.ui.utils.colorFromRGB
|
import com.unciv.ui.utils.colorFromRGB
|
||||||
|
|
||||||
class Terrain : NamedStats() {
|
class Terrain : NamedStats() {
|
||||||
@ -61,5 +61,8 @@ class Terrain : NamedStats() {
|
|||||||
var impassable = false
|
var impassable = false
|
||||||
var rough = false
|
var rough = false
|
||||||
|
|
||||||
fun getColor(): Color = colorFromRGB(RGB!![0], RGB!![1], RGB!![2])
|
fun getColor(): Color {
|
||||||
|
if (RGB == null) return Color.GOLD
|
||||||
|
return colorFromRGB(RGB!![0], RGB!![1], RGB!![2])
|
||||||
|
}
|
||||||
}
|
}
|
Reference in New Issue
Block a user