rename RunConfiguration::VERSION_STRING

This commit is contained in:
Bixilon 2022-10-25 09:53:28 +02:00
parent e5a362e718
commit 6ba4928b1f
No known key found for this signature in database
GPG Key ID: 5CAD791931B09AC4
8 changed files with 8 additions and 8 deletions

View File

@ -86,7 +86,7 @@ class MainErosController : JavaFXWindowController() {
override fun init() {
logoFX.image = JavaFXUtil.MINOSOFT_LOGO
versionTextFX.text = RunConfiguration.VERSION_STRING
versionTextFX.text = RunConfiguration.APPLICATION_NAME
iconMap = mapOf(
ErosMainActivities.PLAY to playIconFX,
ErosMainActivities.PROFILES to profilesIconFX,

View File

@ -44,7 +44,7 @@ class AboutController : EmbeddedJavaFXController<HBox>() {
bixilonLogoFX.children.setAll(JavaFXUtil.BIXILON_LOGO)
createCrashReportFX.ctext = CRASH_REPORT
versionStringFX.text = RunConfiguration.VERSION_STRING
versionStringFX.text = RunConfiguration.APPLICATION_NAME
aboutTextFX.text = TEXT
}

View File

@ -295,7 +295,7 @@ class RenderWindow(
}
if (RenderConstants.SHOW_FPS_IN_WINDOW_TITLE) {
window.title = "Minosoft ${RunConfiguration.VERSION_STRING} | FPS: ${renderStats.smoothAvgFPS.rounded10}"
window.title = "${RunConfiguration.APPLICATION_NAME} | FPS: ${renderStats.smoothAvgFPS.rounded10}"
}
renderStats.endFrame()
}

View File

@ -34,7 +34,7 @@ import de.bixilon.minosoft.terminal.RunConfiguration
class PauseMenu(guiRenderer: GUIRenderer) : Menu(guiRenderer) {
init {
add(TextElement(guiRenderer, RunConfiguration.VERSION_STRING, HorizontalAlignments.CENTER, false, scale = 3.0f))
add(TextElement(guiRenderer, RunConfiguration.APPLICATION_NAME, HorizontalAlignments.CENTER, false, scale = 3.0f))
add(SpacerElement(guiRenderer, Vec2i(0, 20)))
add(ButtonElement(guiRenderer, "menu.pause.back_to_game".i18n()) { guiRenderer.gui.pause(false) })
add(ButtonElement(guiRenderer, "menu.pause.options.debug".i18n()) { guiRenderer.gui.push(DebugMenu) })

View File

@ -93,7 +93,7 @@ class DebugHUDElement(guiRenderer: GUIRenderer) : Element(guiRenderer), Layouted
private fun initLeft(): Element {
val layout = RowLayout(guiRenderer)
layout.margin = Vec4i(2)
layout += TextElement(guiRenderer, TextComponent(RunConfiguration.VERSION_STRING, ChatColors.RED))
layout += TextElement(guiRenderer, TextComponent(RunConfiguration.APPLICATION_NAME, ChatColors.RED))
layout += AutoTextElement(guiRenderer, 1) { "FPS §d${renderWindow.renderStats.smoothAvgFPS.rounded10}" }
renderWindow.renderer[WorldRenderer]?.apply {
layout += AutoTextElement(guiRenderer, 1) { "C v=$visibleSize, m=${loadedMeshesSize.format()}, cQ=${culledQueuedSize.format()}, q=${queueSize.format()}, pT=${preparingTasksSize.format()}/${maxPreparingTasks.format()}, l=${meshesToLoadSize.format()}/${maxMeshesToLoad.format()}, w=${connection.world.chunks.size.format()}" }

View File

@ -183,7 +183,7 @@ class GLFWWindow(
glfwWindowHint(GLFW_VISIBLE, false.glfw)
window = glfwCreateWindow(size.x, size.y, "Minosoft ${RunConfiguration.VERSION_STRING}", MemoryUtil.NULL, MemoryUtil.NULL)
window = glfwCreateWindow(size.x, size.y, RunConfiguration.APPLICATION_NAME, MemoryUtil.NULL, MemoryUtil.NULL)
if (window == MemoryUtil.NULL) {
try {
destroy()

View File

@ -28,7 +28,7 @@ object MinosoftPropertiesLoader {
val json = Minosoft.MINOSOFT_ASSETS_MANAGER[minosoft("version.json")].readJson<MinosoftP>()
MinosoftProperties = json
RunConfiguration.VERSION_STRING = "Minosoft ${MinosoftProperties.general.name}"
RunConfiguration.APPLICATION_NAME = "Minosoft ${MinosoftProperties.general.name}"
Log.log(LogMessageType.OTHER, LogLevels.INFO) { "This is minosoft version ${MinosoftProperties.general.name}${MinosoftProperties.git?.let { ", built on ${it.commitShort}/${it.branch}" }}!" }
}
}

View File

@ -58,7 +58,7 @@ object RunConfiguration {
val X_START_ON_FIRST_THREAD_SET = System.getenv("JAVA_STARTED_ON_FIRST_THREAD_${ProcessHandle.current().pid()}") == "1"
var VERSION_STRING = "Minosoft"
var APPLICATION_NAME = "Minosoft"
var SKIP_RENDERERS: List<ResourceLocation> = emptyList()