mirror of
https://github.com/curioustorvald/Terrarum.git
synced 2026-03-07 20:31:51 +09:00
change in ingame config: useamericanunit -> temperatureunit
This commit is contained in:
@@ -82,7 +82,7 @@ object DefaultConfig {
|
||||
|
||||
jsonObject.addProperty("fullframelightupdate", false)
|
||||
|
||||
jsonObject.addProperty("useamericanunit", false) // Metric Masterrace -- Filthy imperials.
|
||||
jsonObject.addProperty("temperatureunit", 1) // -1: american, 0: kelvin, 1: celcius
|
||||
|
||||
|
||||
// "fancy" graphics settings
|
||||
|
||||
@@ -82,11 +82,14 @@ class UIBasicNotifier(private val player: ActorHumanoid?) : UICanvas() {
|
||||
|
||||
sb.append(temperature.abs())
|
||||
|
||||
if (Terrarum.getConfigBoolean("useamericanunit")) {
|
||||
if (Terrarum.getConfigInt("temperatureunit") == 1) {
|
||||
sb.append('"') // celsius superscript
|
||||
}
|
||||
else if (Terrarum.getConfigInt("temperatureunit") == -1) {
|
||||
sb.append('#') // fahrenheit subscript
|
||||
}
|
||||
else {
|
||||
sb.append('"') // celsius superscript
|
||||
sb.append(' ') // display nothing for kelvin
|
||||
}
|
||||
|
||||
return sb.toString()
|
||||
|
||||
Reference in New Issue
Block a user