From 5d80bf75afb2443e73e12094a2e0a02f90bab5a9 Mon Sep 17 00:00:00 2001 From: Liplum Date: Wed, 6 Dec 2023 20:10:49 +0800 Subject: [PATCH 1/6] migrate welcome list from json to kotlin --- main/src/net/liplum/CioMod.kt | 2 - main/src/net/liplum/ui/CioUI.kt | 9 +- main/src/net/liplum/welcome/Welcome.kt | 6 +- main/src/net/liplum/welcome/WelcomeList.kt | 69 ----------- main/src/net/liplum/welcome/WelcomeTip.kt | 25 ++++ main/src/net/liplum/welcome/Welcomes.kt | 127 +++++++++++++++++++++ meta/Welcomes.json | 110 ------------------ 7 files changed, 160 insertions(+), 188 deletions(-) delete mode 100644 main/src/net/liplum/welcome/WelcomeList.kt create mode 100644 main/src/net/liplum/welcome/WelcomeTip.kt create mode 100644 main/src/net/liplum/welcome/Welcomes.kt delete mode 100644 meta/Welcomes.json diff --git a/main/src/net/liplum/CioMod.kt b/main/src/net/liplum/CioMod.kt index 42d3ab3f..6264f8f1 100644 --- a/main/src/net/liplum/CioMod.kt +++ b/main/src/net/liplum/CioMod.kt @@ -31,7 +31,6 @@ import net.liplum.script.NpcSystem import net.liplum.update.Updater import net.liplum.welcome.FirstLoaded import net.liplum.welcome.Welcome -import net.liplum.welcome.WelcomeList import plumy.core.ClientOnly import plumy.core.HeadlessOnly import java.io.File @@ -129,7 +128,6 @@ class CioMod : Mod() { Core.app.post { CioShaderLoader.init() safeCall { - WelcomeList.loadList() Welcome.load() } DebugOnly { diff --git a/main/src/net/liplum/ui/CioUI.kt b/main/src/net/liplum/ui/CioUI.kt index 8553cc13..2e28781c 100644 --- a/main/src/net/liplum/ui/CioUI.kt +++ b/main/src/net/liplum/ui/CioUI.kt @@ -24,16 +24,17 @@ import net.liplum.common.util.getF import net.liplum.common.util.randomExcept import net.liplum.event.CioInitEvent import net.liplum.function.MapCleaner -import net.liplum.utils.IsLocal -import net.liplum.utils.safeCall import net.liplum.ui.settings.* import net.liplum.ui.settings.AnySetting.Companion.addAny import net.liplum.ui.settings.CheckSettingX.Companion.addCheckPref import net.liplum.ui.settings.SliderSettingX.Companion.addSliderSettingX import net.liplum.update.Updater +import net.liplum.utils.IsLocal +import net.liplum.utils.safeCall import net.liplum.welcome.Conditions import net.liplum.welcome.Welcome -import net.liplum.welcome.WelcomeList +import net.liplum.welcome.Welcomes +import net.liplum.welcome.findAll import plumy.core.ClientOnly import plumy.core.NonSteamOnly import plumy.dsl.bundle @@ -166,7 +167,7 @@ object CioUI { Updater.accessJob?.join() if (!failed) { if (Updater.requireUpdate) { - val updateTips = WelcomeList.findAll { tip -> + val updateTips = Welcomes.findAll { tip -> tip.condition == Conditions.CheckUpdate } if (updateTips.isEmpty()) { diff --git a/main/src/net/liplum/welcome/Welcome.kt b/main/src/net/liplum/welcome/Welcome.kt index 5ca1ed9d..ef2c0039 100644 --- a/main/src/net/liplum/welcome/Welcome.kt +++ b/main/src/net/liplum/welcome/Welcome.kt @@ -10,12 +10,12 @@ import mindustry.game.EventType.Trigger import mindustry.io.JsonIO import net.liplum.CioMod import net.liplum.Meta -import net.liplum.Var import net.liplum.Settings.CioVersion import net.liplum.Settings.ClickWelcomeTimes import net.liplum.Settings.LastWelcomeID import net.liplum.Settings.ShouldShowWelcome import net.liplum.Settings.ShowUpdate +import net.liplum.Var import net.liplum.annotations.Only import net.liplum.annotations.SubscribeEvent import net.liplum.blocks.tmtrainer.RandomName @@ -52,7 +52,7 @@ object Welcome { } @JvmStatic fun judgeWelcome() { - val allTips = info.scenes.map { WelcomeList[it] }.distinct().toList() + val allTips = info.scenes.map { Welcomes[it] }.distinct().toList() val tipsCanShow = allTips.filter { it.condition.canShow(it) } val allCandidates = tipsCanShow.allMaxBy { it.condition.priority(it) } if (allCandidates.isEmpty()) { @@ -198,7 +198,7 @@ object Welcome { companion object { fun Entity.showTipByID(id: String): Entity { - tip = WelcomeList[id] + tip = Welcomes[id] showTip() return this } diff --git a/main/src/net/liplum/welcome/WelcomeList.kt b/main/src/net/liplum/welcome/WelcomeList.kt deleted file mode 100644 index adfeb8a5..00000000 --- a/main/src/net/liplum/welcome/WelcomeList.kt +++ /dev/null @@ -1,69 +0,0 @@ -package net.liplum.welcome - -import arc.struct.Seq -import arc.util.serialization.JsonValue -import mindustry.io.JsonIO -import net.liplum.common.Res -import net.liplum.common.util.getValue - -object WelcomeList { - var list: Map = emptyMap() - @JvmStatic - @Suppress("UNCHECKED_CAST") - fun loadList() { - val json = Res("Welcomes.json").readAllText() - val array = JsonIO.json.fromJson(Seq::class.java, json) as Seq - val all = HashMap() - for (entry in array) { - val id = entry.get("ID").asString() - val iconPath: String? = entry.get("IconPath")?.asString() - val template: String? = entry.get("Template")?.asString() - val condition: String? = entry.get("Condition")?.asString() - val chance: Int? = entry.get("Chance")?.asInt() - val data: JsonValue? = entry.get("Data") - all[id] = WelcomeTip().apply { - this.id = id - iconPath?.let { this.iconPath = it } - template?.let { this.templateID = it } - data?.let { j -> - this.data = j.associate { it.name to it.getValue() } - } - condition?.let { this.conditionID = it } - chance?.let { this.chance = it } - } - } - list = all - } - - operator fun get(id: String) = list[id] ?: WelcomeTip.Default - inline fun find(filter: (WelcomeTip) -> Boolean): WelcomeTip? { - return list.values.find(filter) - } - - inline fun findAll(filter: (WelcomeTip) -> Boolean): List { - return list.values.filter(filter) - } -} - -class WelcomeTip { - @JvmField var id: String = DefaultID - @JvmField var conditionID: String = DefaultCondition - @JvmField var templateID: String = DefaultTemplateID - @JvmField var iconPath: String = DefaultIconPath - @JvmField var chance: Int = DefaultChance - @JvmField var data: Map = emptyMap() - override fun toString() = id - val template: WelcomeTemplate - get() = TemplateRegistry[templateID] - val condition: Condition - get() = ConditionRegistry[conditionID] - - companion object { - val Default = WelcomeTip() - const val DefaultID = "Default" - const val DefaultCondition = "ShowWelcome" - const val DefaultTemplateID = "Story" - const val DefaultChance = 1000 - const val DefaultIconPath = "icon" - } -} diff --git a/main/src/net/liplum/welcome/WelcomeTip.kt b/main/src/net/liplum/welcome/WelcomeTip.kt new file mode 100644 index 00000000..d221b591 --- /dev/null +++ b/main/src/net/liplum/welcome/WelcomeTip.kt @@ -0,0 +1,25 @@ +package net.liplum.welcome + +class WelcomeTip( + @JvmField var id: String = DefaultID, + @JvmField var conditionID: String = DefaultCondition, + @JvmField var templateID: String = DefaultTemplateID, + @JvmField var iconPath: String = DefaultIconPath, + @JvmField var chance: Int = DefaultChance, + @JvmField var data: Map = emptyMap(), +) { + override fun toString() = id + val template: WelcomeTemplate + get() = TemplateRegistry[templateID] + val condition: Condition + get() = ConditionRegistry[conditionID] + + companion object { + val Default = WelcomeTip() + const val DefaultID = "Default" + const val DefaultCondition = "ShowWelcome" + const val DefaultTemplateID = "Story" + const val DefaultChance = 1000 + const val DefaultIconPath = "icon" + } +} diff --git a/main/src/net/liplum/welcome/Welcomes.kt b/main/src/net/liplum/welcome/Welcomes.kt new file mode 100644 index 00000000..c13e0ec7 --- /dev/null +++ b/main/src/net/liplum/welcome/Welcomes.kt @@ -0,0 +1,127 @@ +package net.liplum.welcome + +object Welcomes { + val tips = listOf( + WelcomeTip( + id = "Default", + templateID = "Story", + ), + WelcomeTip( + id = "EmploymentVerification", + templateID = "SpecialDishes", + ), + WelcomeTip( + id = "Discord", + templateID = "DoAction", + data = mapOf( + "YesAction" to "OpenLink", + "Link" to "@link", + ), + iconPath = "discord", + chance = 750, + ), + WelcomeTip( + id = "UpdateECHO", + templateID = "Update", + data = mapOf( + "ActionA" to "UpdateCyberIO", + "ActionC" to "@SkipThisUpdate", + ), + iconPath = "update-icon", + conditionID = "CheckUpdate", + ), + WelcomeTip( + id = "ResearchProject", + iconPath = "welcome-holo-project", + conditionID = "SpecialDishes", + ), + WelcomeTip( + id = "TheSHIP", + ), + WelcomeTip( + id = "ECHO", + ), + WelcomeTip( + id = "NewBrains", + iconPath = "heimdall", + ), + WelcomeTip( + id = "AdBlock", + templateID = "DoAction", + iconPath = "ad-block", + data = mapOf( + "NoAction" to "StopReceiveWelcome", + ), + chance = 300, + ), + WelcomeTip( + id = "404NotFound", + templateID = "PlainText", + iconPath = "ad-block", + conditionID = "SettingsReq", + data = mapOf( + "FontSize" to 1.2, + "ShowPoliteWelcome" to false, + "CExpression" to "@ClickWelcomeTimes > 5 && @ShouldShowWelcome", + ), + chance = 200, + ), + WelcomeTip( + id = "OhNo", + iconPath = "@error", + data = mapOf( + "ShowPoliteWelcome" to false, + ), + chance = 200, + ), + WelcomeTip( + id = "RateUs", + templateID = "RateStar", + iconPath = "@error", + data = mapOf( + "StarNumber" to 5, + "InactiveStarIconPath" to "star-inactive", + "ActiveStarIconPath" to "star", + "StarSize" to 60.0, + ), + chance = 200, + ), + WelcomeTip( + id = "ErekirDetected", + iconPath = "spec-erekir", + conditionID = "SpecialDishes", + ), + WelcomeTip( + id = "SetOutErekir", + templateID = "DoAction", + conditionID = "SettingsReq", + iconPath = "spec-erekir", + data = mapOf( + "ShowPoliteWelcome" to true, + "CExpression" to "@ContentSpecific == vanilla && @ShouldShowWelcome", + "YesAction" to "Navigation", + "Locator" to "/CyberIO/ContentSpecific", + ), + ), + WelcomeTip( + id = "CyberionForErekir", + conditionID = "SettingsReq", + iconPath = "cyberion-for-erekir", + data = mapOf( + "ShowPoliteWelcome" to true, + "CExpression" to "@ContentSpecific == erekir && @ShouldShowWelcome", + ), + ), + ) + val id2Tips = tips.associateBy { it.id } + +} + +operator fun Welcomes.get(id: String) = id2Tips[id] ?: WelcomeTip.Default +inline fun Welcomes.find(filter: (WelcomeTip) -> Boolean): WelcomeTip? { + return id2Tips.values.find(filter) +} + +inline fun Welcomes.findAll(filter: (WelcomeTip) -> Boolean): List { + return id2Tips.values.filter(filter) +} \ No newline at end of file diff --git a/meta/Welcomes.json b/meta/Welcomes.json deleted file mode 100644 index 51770421..00000000 --- a/meta/Welcomes.json +++ /dev/null @@ -1,110 +0,0 @@ -[ - { - "ID": "Default", - "Template": "Story" - }, - { - "ID": "EmploymentVerification", - "Template": "SpecialDishes" - }, - { - "ID": "Discord", - "Template": "DoAction", - "Data": { - "YesAction": "OpenLink", - "Link": "@link" - }, - "IconPath": "discord", - "Chance": 750 - }, - { - "ID": "UpdateECHO", - "IconPath": "update-icon", - "Template": "Update", - "Data": { - "ActionA": "UpdateCyberIO", - "ActionC": "SkipThisUpdate" - }, - "Condition": "CheckUpdate" - }, - { - "ID": "ResearchProject", - "Condition": "SpecialDishes", - "IconPath": "welcome-holo-project" - }, - { - "ID": "TheSHIP" - }, - { - "ID": "ECHO" - }, - { - "ID": "NewBrains", - "IconPath": "heimdall" - }, - { - "ID": "AdBlock", - "Template": "DoAction", - "IconPath": "ad-block", - "Data": { - "NoAction": "StopReceiveWelcome" - }, - "Chance": 300 - }, - { - "ID": "404NotFound", - "Template": "PlainText", - "Condition": "SettingsReq", - "Data": { - "FontSize": 1.2, - "ShowPoliteWelcome": false, - "CExpression": "@ClickWelcomeTimes > 5 && @ShouldShowWelcome" - }, - "Chance": 200 - }, - { - "ID": "OhNo", - "IconPath": "@error", - "Data": { - "ShowPoliteWelcome": false - }, - "Chance": 200 - }, - { - "ID": "RateUs", - "Template": "RateStar", - "Data": { - "StarNumber": 5, - "InactiveStarIconPath": "star-inactive", - "ActiveStarIconPath": "star", - "StarSize": 60.0 - }, - "Chance": 200 - }, - { - "ID": "ErekirDetected", - "Condition": "SpecialDishes", - "IconPath": "spec-erekir" - }, - { - "ID": "SetOutErekir", - "Condition": "SettingsReq", - "IconPath": "spec-erekir", - "Template": "DoAction", - "Data": { - "ShowPoliteWelcome": true, - "CExpression": "@ContentSpecific == vanilla && @ShouldShowWelcome", - "YesAction": "Navigation", - "Locator": "/CyberIO/ContentSpecific" - } - }, - { - "ID": "CyberionForErekir", - "Condition": "SettingsReq", - "IconPath": "cyberion-for-erekir", - "Data": { - "ShowPoliteWelcome": true, - "CExpression": "@ContentSpecific == erekir && @ShouldShowWelcome" - } - } -] \ No newline at end of file From 1eb63c90589b7d7506bffa7ec237063ef27d2ec5 Mon Sep 17 00:00:00 2001 From: Liplum Date: Thu, 7 Dec 2023 02:25:17 +0800 Subject: [PATCH 2/6] migrate welcome info list from json to kotlin --- main/build.gradle.kts | 4 -- main/src/net/liplum/welcome/Scenes.kt | 45 +++++++++++++++ main/src/net/liplum/welcome/Welcome.kt | 68 ++++------------------- main/src/net/liplum/welcome/WelcomeTip.kt | 27 +++++++++ meta/WelcomeInfo.json | 65 ---------------------- 5 files changed, 83 insertions(+), 126 deletions(-) create mode 100644 main/src/net/liplum/welcome/Scenes.kt delete mode 100644 meta/WelcomeInfo.json diff --git a/main/build.gradle.kts b/main/build.gradle.kts index cbb0b164..9d46bc14 100644 --- a/main/build.gradle.kts +++ b/main/build.gradle.kts @@ -105,10 +105,6 @@ tasks.jar { archiveBaseName.set("CyberIO") includeEmptyDirs = false exclude("**/**/*.java") - - from("$rootDir/meta") { - include("*.json") - } } java { diff --git a/main/src/net/liplum/welcome/Scenes.kt b/main/src/net/liplum/welcome/Scenes.kt new file mode 100644 index 00000000..fd97ef2d --- /dev/null +++ b/main/src/net/liplum/welcome/Scenes.kt @@ -0,0 +1,45 @@ +package net.liplum.welcome + +object Scenes { + val common = WelcomeTipPack( + scenes = listOf( + "UpdateECHO", + "TheSHIP", + "ECHO", + "NewBrains", + "Discord", + "AdBlock", + "404NotFound", + "OhNo", + "RateUs", + "SetOutErekir", + "CyberionForErekir" + ) + ) + val v2 = WelcomeTipPack( + default = "EmploymentVerification", + scenes = listOf( + "EmploymentVerification" + ) + ) + val v3 = common.inherit( + default = "ResearchProject", + scenes = listOf( + "EmploymentVerification" + ) + ) + val v4 = common.inherit( + default = "ErekirDetected", + scenes = listOf( + "ErekirDetected", + "SetOutErekir" + ) + ) + val v4_1 = v4.inherit( + scenes = listOf( + "CyberionForErekir" + ) + ) + val v5 = v4_1.inherit() + val v5_1 = v5.inherit() +} \ No newline at end of file diff --git a/main/src/net/liplum/welcome/Welcome.kt b/main/src/net/liplum/welcome/Welcome.kt index ef2c0039..8aa01a0e 100644 --- a/main/src/net/liplum/welcome/Welcome.kt +++ b/main/src/net/liplum/welcome/Welcome.kt @@ -2,12 +2,8 @@ package net.liplum.welcome import arc.Core import arc.Events -import arc.struct.ObjectMap -import arc.util.ArcRuntimeException import arc.util.Time -import arc.util.serialization.JsonValue import mindustry.game.EventType.Trigger -import mindustry.io.JsonIO import net.liplum.CioMod import net.liplum.Meta import net.liplum.Settings.CioVersion @@ -20,7 +16,6 @@ import net.liplum.annotations.Only import net.liplum.annotations.SubscribeEvent import net.liplum.blocks.tmtrainer.RandomName import net.liplum.cio -import net.liplum.common.Res import net.liplum.common.util.ReferBundleWrapper import net.liplum.common.util.allMaxBy import net.liplum.common.util.randomExcept @@ -33,10 +28,11 @@ import plumy.dsl.sprite @ClientOnly object Welcome { var bundle = ReferBundleWrapper.create() - private var info = Info() - fun genEntity() = Entity(bundle, info) + private var version = Scenes.v5_1 + fun genEntity() = Entity(bundle, version) private var entity = genEntity() private var showWelcome = false + @JvmStatic @ClientOnly fun showWelcomeDialog() { @@ -50,9 +46,10 @@ object Welcome { tip?.condition?.canShow(tip)*/ //entity.showTipByID("SetOutErekir") } + @JvmStatic fun judgeWelcome() { - val allTips = info.scenes.map { Welcomes[it] }.distinct().toList() + val allTips = version.scenes.map { Welcomes[it] }.distinct().toList() val tipsCanShow = allTips.filter { it.condition.canShow(it) } val allCandidates = tipsCanShow.allMaxBy { it.condition.priority(it) } if (allCandidates.isEmpty()) { @@ -79,6 +76,7 @@ object Welcome { showWelcome = true } } + @JvmStatic @SubscribeEvent(CioInitEvent::class, Only.client) fun modifierModInfo() { @@ -90,6 +88,7 @@ object Welcome { } } } + @JvmStatic fun checkLastVersion() { val lastVersion = CioVersion @@ -101,20 +100,22 @@ object Welcome { } CioVersion = Meta.Version } + @JvmStatic fun recordClick() { ClickWelcomeTimes += 1 } + @JvmStatic @ClientOnly fun load() { loadBundle() - loadInfo() //To load all templates and actions Templates Actions Conditions } + @JvmStatic fun loadBundle() { bundle.loadMoreFrom("welcomes") @@ -123,53 +124,6 @@ object Welcome { } } - lateinit var infoJson: ObjectMap - @Suppress("UNCHECKED_CAST") - @JvmStatic - fun loadInfo() { - val json = Res("WelcomeInfo.json").readAllText() - infoJson = JsonIO.json.fromJson(ObjectMap::class.java, json) as ObjectMap - val curInfo = infoJson.get(Meta.Version) - ?: throw ArcRuntimeException("The welcome message information of Cyber IO ${Meta.Version} not found.") - val default = curInfo.get("Default")?.asString() ?: "Default" - val scenes = curInfo.get("Scene")?.asStringArray() ?: emptyArray() - val parent: String? = curInfo.get("Parent")?.asString() - info.default = default - val allScenes = HashSet() - allScenes.addAll(scenes) - fun loadParent(parent: String) { - val parentInfo = infoJson.get(parent) - val parentScenes = parentInfo.get("Scene").asStringArray() - val parentParent: String? = parentInfo.get("Parent")?.asString() - allScenes.addAll(parentScenes) - if (parentParent != null) - loadParent(parentParent) - } - if (parent != null) { - loadParent(parent) - } - info.scenes = allScenes.toList() - } - - class Info { - var default = "Default" - var scenes: List = emptyList() - val sceneSize: Int - get() = scenes.size - - operator fun get(index: Int) = - if (index !in scenes.indices) - default - else - scenes[index] - - fun indexOf(tipID: String): Int = - scenes.indexOf(tipID) - - val defaultIndex: Int - get() = indexOf(default) - } - fun String.handleTrRefer(): TR = if (startsWith('@')) removePrefix("@").sprite @@ -177,7 +131,7 @@ object Welcome { class Entity( val bundle: ReferBundleWrapper, - val info: Info, + val info: WelcomeTipPack, ) { var tip: WelcomeTip = WelcomeTip.Default operator fun get(key: String) = diff --git a/main/src/net/liplum/welcome/WelcomeTip.kt b/main/src/net/liplum/welcome/WelcomeTip.kt index d221b591..9ee06325 100644 --- a/main/src/net/liplum/welcome/WelcomeTip.kt +++ b/main/src/net/liplum/welcome/WelcomeTip.kt @@ -23,3 +23,30 @@ class WelcomeTip( const val DefaultIconPath = "icon" } } + +class WelcomeTipPack( + var default: String = "Default", + var scenes: List = emptyList(), +) { + operator fun get(index: Int) = + if (index !in scenes.indices) + default + else + scenes[index] + + fun indexOf(tipID: String): Int = + scenes.indexOf(tipID) + + val defaultIndex: Int + get() = indexOf(default) + + fun inherit( + default: String? = null, + scenes: List = emptyList(), + ): WelcomeTipPack { + return WelcomeTipPack( + default = default ?: this.default, + scenes = this.scenes + scenes, + ) + } +} \ No newline at end of file diff --git a/meta/WelcomeInfo.json b/meta/WelcomeInfo.json deleted file mode 100644 index 2399aa7d..00000000 --- a/meta/WelcomeInfo.json +++ /dev/null @@ -1,65 +0,0 @@ -{ - "common": { - "Scene": [ - "UpdateECHO", - "TheSHIP", - "ECHO", - "NewBrains", - "Discord", - "AdBlock", - "404NotFound", - "OhNo", - "RateUs", - "SetOutErekir", - "CyberionForErekir" - ] - }, - "common-erekir": { - "Parent": "common", - "Scene": [ - "SetOutErekir", - "CyberionForErekir" - ] - }, - "v0": {}, - "v2": { - "Default": "EmploymentVerification", - "Scene": [ - "EmploymentVerification" - ] - }, - "v3": { - "Default": "ResearchProject", - "Parent": "common", - "Scene": [ - "ResearchProject" - ] - }, - "v4": { - "Default": "ErekirDetected", - "Parent": "common", - "Scene": [ - "ErekirDetected", - "SetOutErekir" - ] - }, - "v4.1": { - "Default": "ErekirDetected", - "Parent": "v4", - "Scene": [ - "CyberionForErekir" - ] - }, - "v5.0": { - "Default": "ErekirDetected", - "Parent": "v4.1", - "Scene": [ - ] - }, - "v5.1": { - "Default": "ErekirDetected", - "Parent": "v4.1", - "Scene": [ - ] - } -} \ No newline at end of file From 95ae354d76c6ddada4b2640bda2496cc94b86dc5 Mon Sep 17 00:00:00 2001 From: Liplum Date: Thu, 7 Dec 2023 02:58:12 +0800 Subject: [PATCH 3/6] using typed ref instead of string ID --- main/src/net/liplum/welcome/Condition.kt | 8 +- main/src/net/liplum/welcome/Conditions.kt | 16 +- main/src/net/liplum/welcome/Scenes.kt | 45 ---- main/src/net/liplum/welcome/Welcome.kt | 8 +- .../{WelcomeTip.kt => WelcomeScene.kt} | 25 +- .../net/liplum/welcome/WelcomeScenePacks.kt | 44 ++++ main/src/net/liplum/welcome/Welcomes.kt | 228 ++++++++++-------- 7 files changed, 192 insertions(+), 182 deletions(-) delete mode 100644 main/src/net/liplum/welcome/Scenes.kt rename main/src/net/liplum/welcome/{WelcomeTip.kt => WelcomeScene.kt} (71%) create mode 100644 main/src/net/liplum/welcome/WelcomeScenePacks.kt diff --git a/main/src/net/liplum/welcome/Condition.kt b/main/src/net/liplum/welcome/Condition.kt index deb6386b..c5651409 100644 --- a/main/src/net/liplum/welcome/Condition.kt +++ b/main/src/net/liplum/welcome/Condition.kt @@ -27,16 +27,16 @@ abstract class Condition( this.register() } - abstract fun canShow(tip: WelcomeTip): Boolean - abstract fun priority(tip: WelcomeTip): Int + abstract fun canShow(tip: WelcomeScene): Boolean + abstract fun priority(tip: WelcomeScene): Int companion object { val Default = object : Condition("Default") { - override fun canShow(tip: WelcomeTip): Boolean { + override fun canShow(tip: WelcomeScene): Boolean { return false } - override fun priority(tip: WelcomeTip) = Int.MIN_VALUE + override fun priority(tip: WelcomeScene) = Int.MIN_VALUE } } } \ No newline at end of file diff --git a/main/src/net/liplum/welcome/Conditions.kt b/main/src/net/liplum/welcome/Conditions.kt index cb99c779..29588721 100644 --- a/main/src/net/liplum/welcome/Conditions.kt +++ b/main/src/net/liplum/welcome/Conditions.kt @@ -8,39 +8,39 @@ import opengal.experssion.ExpressionParser object Conditions { val ShowWelcome = object : Condition("ShowWelcome") { - override fun canShow(tip: WelcomeTip): Boolean { + override fun canShow(tip: WelcomeScene): Boolean { return Settings.ShouldShowWelcome } - override fun priority(tip: WelcomeTip) = 0 + override fun priority(tip: WelcomeScene) = 0 } val CheckUpdate = object : Condition("CheckUpdate") { - override fun canShow(tip: WelcomeTip): Boolean { + override fun canShow(tip: WelcomeScene): Boolean { return !Vars.steam && Settings.ShowUpdate && Updater.requireUpdate && !Updater.latestVersion.equalsString(Settings.LastSkippedUpdate) && Updater.matchMinGameVersion } - override fun priority(tip: WelcomeTip) = 10 + override fun priority(tip: WelcomeScene) = 10 } val SpecialDishes = object : Condition("SpecialDishes") { - override fun canShow(tip: WelcomeTip): Boolean { + override fun canShow(tip: WelcomeScene): Boolean { return Settings.ShouldShowWelcome } - override fun priority(tip: WelcomeTip) = + override fun priority(tip: WelcomeScene) = if (Settings.ClickWelcomeTimes == 0) 5 else 0 } val SettingsReq = object : Condition("SettingsReq") { - override fun canShow(tip: WelcomeTip): Boolean { + override fun canShow(tip: WelcomeScene): Boolean { val data = tip.data val exprRaw = data["CExpression"] as? String ?: "" val expr = ExpressionParser.by(exprRaw).parse() return expr.calculate(ExprSettingsWrapper) } - override fun priority(tip: WelcomeTip) = 0 + override fun priority(tip: WelcomeScene) = 0 } object ExprSettingsWrapper : IExpressionReceiver { diff --git a/main/src/net/liplum/welcome/Scenes.kt b/main/src/net/liplum/welcome/Scenes.kt deleted file mode 100644 index fd97ef2d..00000000 --- a/main/src/net/liplum/welcome/Scenes.kt +++ /dev/null @@ -1,45 +0,0 @@ -package net.liplum.welcome - -object Scenes { - val common = WelcomeTipPack( - scenes = listOf( - "UpdateECHO", - "TheSHIP", - "ECHO", - "NewBrains", - "Discord", - "AdBlock", - "404NotFound", - "OhNo", - "RateUs", - "SetOutErekir", - "CyberionForErekir" - ) - ) - val v2 = WelcomeTipPack( - default = "EmploymentVerification", - scenes = listOf( - "EmploymentVerification" - ) - ) - val v3 = common.inherit( - default = "ResearchProject", - scenes = listOf( - "EmploymentVerification" - ) - ) - val v4 = common.inherit( - default = "ErekirDetected", - scenes = listOf( - "ErekirDetected", - "SetOutErekir" - ) - ) - val v4_1 = v4.inherit( - scenes = listOf( - "CyberionForErekir" - ) - ) - val v5 = v4_1.inherit() - val v5_1 = v5.inherit() -} \ No newline at end of file diff --git a/main/src/net/liplum/welcome/Welcome.kt b/main/src/net/liplum/welcome/Welcome.kt index 8aa01a0e..68449566 100644 --- a/main/src/net/liplum/welcome/Welcome.kt +++ b/main/src/net/liplum/welcome/Welcome.kt @@ -28,7 +28,7 @@ import plumy.dsl.sprite @ClientOnly object Welcome { var bundle = ReferBundleWrapper.create() - private var version = Scenes.v5_1 + private var version = WelcomeScenePacks.v5_1 fun genEntity() = Entity(bundle, version) private var entity = genEntity() private var showWelcome = false @@ -49,7 +49,7 @@ object Welcome { @JvmStatic fun judgeWelcome() { - val allTips = version.scenes.map { Welcomes[it] }.distinct().toList() + val allTips = version.scenes.distinct().toList() val tipsCanShow = allTips.filter { it.condition.canShow(it) } val allCandidates = tipsCanShow.allMaxBy { it.condition.priority(it) } if (allCandidates.isEmpty()) { @@ -131,9 +131,9 @@ object Welcome { class Entity( val bundle: ReferBundleWrapper, - val info: WelcomeTipPack, + val info: WelcomeScenePack, ) { - var tip: WelcomeTip = WelcomeTip.Default + var tip: WelcomeScene = WelcomeScene.Default operator fun get(key: String) = bundle["$tip.$key"] diff --git a/main/src/net/liplum/welcome/WelcomeTip.kt b/main/src/net/liplum/welcome/WelcomeScene.kt similarity index 71% rename from main/src/net/liplum/welcome/WelcomeTip.kt rename to main/src/net/liplum/welcome/WelcomeScene.kt index 9ee06325..c246b3c3 100644 --- a/main/src/net/liplum/welcome/WelcomeTip.kt +++ b/main/src/net/liplum/welcome/WelcomeScene.kt @@ -1,6 +1,6 @@ package net.liplum.welcome -class WelcomeTip( +class WelcomeScene( @JvmField var id: String = DefaultID, @JvmField var conditionID: String = DefaultCondition, @JvmField var templateID: String = DefaultTemplateID, @@ -15,7 +15,7 @@ class WelcomeTip( get() = ConditionRegistry[conditionID] companion object { - val Default = WelcomeTip() + val Default = WelcomeScene() const val DefaultID = "Default" const val DefaultCondition = "ShowWelcome" const val DefaultTemplateID = "Story" @@ -24,27 +24,24 @@ class WelcomeTip( } } -class WelcomeTipPack( - var default: String = "Default", - var scenes: List = emptyList(), +class WelcomeScenePack( + var default: WelcomeScene, + var scenes: List = emptyList(), ) { - operator fun get(index: Int) = + operator fun get(index: Int): WelcomeScene = if (index !in scenes.indices) default else scenes[index] - fun indexOf(tipID: String): Int = + fun indexOf(tipID: WelcomeScene): Int = scenes.indexOf(tipID) - val defaultIndex: Int - get() = indexOf(default) - fun inherit( - default: String? = null, - scenes: List = emptyList(), - ): WelcomeTipPack { - return WelcomeTipPack( + default: WelcomeScene? = null, + scenes: List = emptyList(), + ): WelcomeScenePack { + return WelcomeScenePack( default = default ?: this.default, scenes = this.scenes + scenes, ) diff --git a/main/src/net/liplum/welcome/WelcomeScenePacks.kt b/main/src/net/liplum/welcome/WelcomeScenePacks.kt new file mode 100644 index 00000000..00758188 --- /dev/null +++ b/main/src/net/liplum/welcome/WelcomeScenePacks.kt @@ -0,0 +1,44 @@ +package net.liplum.welcome + +object WelcomeScenePacks { + val common = WelcomeScenePack( + default = Welcomes.default, + scenes = listOf( + Welcomes.updateECHO, + Welcomes.theShip, + Welcomes.echo, + Welcomes.newBrains, + Welcomes.discord, + Welcomes.adBlock, + Welcomes.`404NotFound`, + Welcomes.ohNo, + Welcomes.rateUs, + ) + ) + val v2 = WelcomeScenePack( + default = Welcomes.employmentVerification, + scenes = listOf( + Welcomes.employmentVerification, + ) + ) + val v3 = common.inherit( + default = Welcomes.researchProject, + scenes = listOf( + Welcomes.employmentVerification, + ) + ) + val v4 = common.inherit( + default = Welcomes.erekirDetected, + scenes = listOf( + Welcomes.erekirDetected, + Welcomes.setOutErekir, + ) + ) + val v4_1 = v4.inherit( + scenes = listOf( + Welcomes.cyberionForErekir, + ) + ) + val v5 = v4_1.inherit() + val v5_1 = v5.inherit() +} \ No newline at end of file diff --git a/main/src/net/liplum/welcome/Welcomes.kt b/main/src/net/liplum/welcome/Welcomes.kt index c13e0ec7..28f0f910 100644 --- a/main/src/net/liplum/welcome/Welcomes.kt +++ b/main/src/net/liplum/welcome/Welcomes.kt @@ -1,127 +1,141 @@ package net.liplum.welcome object Welcomes { - val tips = listOf( - WelcomeTip( - id = "Default", - templateID = "Story", - ), - WelcomeTip( - id = "EmploymentVerification", - templateID = "SpecialDishes", - ), - WelcomeTip( - id = "Discord", - templateID = "DoAction", - data = mapOf( - "YesAction" to "OpenLink", - "Link" to "@link", - ), - iconPath = "discord", - chance = 750, - ), - WelcomeTip( - id = "UpdateECHO", - templateID = "Update", - data = mapOf( - "ActionA" to "UpdateCyberIO", - "ActionC" to "@SkipThisUpdate", - ), - iconPath = "update-icon", - conditionID = "CheckUpdate", - ), - WelcomeTip( - id = "ResearchProject", - iconPath = "welcome-holo-project", - conditionID = "SpecialDishes", - ), - WelcomeTip( - id = "TheSHIP", - ), - WelcomeTip( - id = "ECHO", - ), - WelcomeTip( - id = "NewBrains", - iconPath = "heimdall", + val default = WelcomeScene( + id = "Default", + templateID = "Story", + ) + val employmentVerification = WelcomeScene( + id = "EmploymentVerification", + templateID = "SpecialDishes", + ) + val discord = WelcomeScene( + id = "Discord", + templateID = "DoAction", + data = mapOf( + "YesAction" to "OpenLink", + "Link" to "@link", ), - WelcomeTip( - id = "AdBlock", - templateID = "DoAction", - iconPath = "ad-block", - data = mapOf( - "NoAction" to "StopReceiveWelcome", - ), - chance = 300, + iconPath = "discord", + chance = 750, + ) + val updateECHO = WelcomeScene( + id = "UpdateECHO", + templateID = "Update", + data = mapOf( + "ActionA" to "UpdateCyberIO", + "ActionC" to "@SkipThisUpdate", ), - WelcomeTip( - id = "404NotFound", - templateID = "PlainText", - iconPath = "ad-block", - conditionID = "SettingsReq", - data = mapOf( - "FontSize" to 1.2, - "ShowPoliteWelcome" to false, - "CExpression" to "@ClickWelcomeTimes > 5 && @ShouldShowWelcome", - ), - chance = 200, + iconPath = "update-icon", + conditionID = "CheckUpdate", + ) + val researchProject = WelcomeScene( + id = "ResearchProject", + iconPath = "welcome-holo-project", + conditionID = "SpecialDishes", + ) + val theShip = WelcomeScene( + id = "TheSHIP", + ) + val echo = WelcomeScene( + id = "ECHO", + ) + val newBrains = WelcomeScene( + id = "NewBrains", + iconPath = "heimdall", + ) + val adBlock = WelcomeScene( + id = "AdBlock", + templateID = "DoAction", + iconPath = "ad-block", + data = mapOf( + "NoAction" to "StopReceiveWelcome", ), - WelcomeTip( - id = "OhNo", - iconPath = "@error", - data = mapOf( - "ShowPoliteWelcome" to false, - ), - chance = 200, + chance = 300, + ) + val `404NotFound` = WelcomeScene( + id = "404NotFound", + templateID = "PlainText", + iconPath = "ad-block", + conditionID = "SettingsReq", + data = mapOf( + "FontSize" to 1.2, + "ShowPoliteWelcome" to false, + "CExpression" to "@ClickWelcomeTimes > 5 && @ShouldShowWelcome", ), - WelcomeTip( - id = "RateUs", - templateID = "RateStar", - iconPath = "@error", - data = mapOf( - "StarNumber" to 5, - "InactiveStarIconPath" to "star-inactive", - "ActiveStarIconPath" to "star", - "StarSize" to 60.0, - ), - chance = 200, + chance = 200, + ) + val ohNo = WelcomeScene( + id = "OhNo", + iconPath = "@error", + data = mapOf( + "ShowPoliteWelcome" to false, ), - WelcomeTip( - id = "ErekirDetected", - iconPath = "spec-erekir", - conditionID = "SpecialDishes", + chance = 200, + ) + val rateUs = WelcomeScene( + id = "RateUs", + templateID = "RateStar", + iconPath = "@error", + data = mapOf( + "StarNumber" to 5, + "InactiveStarIconPath" to "star-inactive", + "ActiveStarIconPath" to "star", + "StarSize" to 60.0, ), - WelcomeTip( - id = "SetOutErekir", - templateID = "DoAction", - conditionID = "SettingsReq", - iconPath = "spec-erekir", - data = mapOf( - "ShowPoliteWelcome" to true, - "CExpression" to "@ContentSpecific == vanilla && @ShouldShowWelcome", - "YesAction" to "Navigation", - "Locator" to "/CyberIO/ContentSpecific", - ), + chance = 200, + ) + val erekirDetected = WelcomeScene( + id = "ErekirDetected", + iconPath = "spec-erekir", + conditionID = "SpecialDishes", + ) + val setOutErekir = WelcomeScene( + id = "SetOutErekir", + templateID = "DoAction", + conditionID = "SettingsReq", + iconPath = "spec-erekir", + data = mapOf( + "ShowPoliteWelcome" to true, + "CExpression" to "@ContentSpecific == vanilla && @ShouldShowWelcome", + "YesAction" to "Navigation", + "Locator" to "/CyberIO/ContentSpecific", ), - WelcomeTip( - id = "CyberionForErekir", - conditionID = "SettingsReq", - iconPath = "cyberion-for-erekir", - data = mapOf( - "ShowPoliteWelcome" to true, - "CExpression" to "@ContentSpecific == erekir && @ShouldShowWelcome", - ), + ) + val cyberionForErekir = WelcomeScene( + id = "CyberionForErekir", + conditionID = "SettingsReq", + iconPath = "cyberion-for-erekir", + data = mapOf( + "ShowPoliteWelcome" to true, + "CExpression" to "@ContentSpecific == erekir && @ShouldShowWelcome", ), ) + val tips = listOf( + default, + employmentVerification, + discord, + updateECHO, + researchProject, + theShip, + echo, + newBrains, + adBlock, + `404NotFound`, + ohNo, + rateUs, + erekirDetected, + setOutErekir, + cyberionForErekir, + ) val id2Tips = tips.associateBy { it.id } - } -operator fun Welcomes.get(id: String) = id2Tips[id] ?: WelcomeTip.Default -inline fun Welcomes.find(filter: (WelcomeTip) -> Boolean): WelcomeTip? { +operator fun Welcomes.get(id: String) = id2Tips[id] ?: WelcomeScene.Default +inline fun Welcomes.find(filter: (WelcomeScene) -> Boolean): WelcomeScene? { return id2Tips.values.find(filter) } -inline fun Welcomes.findAll(filter: (WelcomeTip) -> Boolean): List { +inline fun Welcomes.findAll(filter: (WelcomeScene) -> Boolean): List { return id2Tips.values.filter(filter) } \ No newline at end of file From f6d0594cb25b02e7d853683ec86ca94ae109e26e Mon Sep 17 00:00:00 2001 From: Liplum Date: Thu, 7 Dec 2023 03:09:30 +0800 Subject: [PATCH 4/6] bump gradle to v7.6.3 --- gradle/wrapper/gradle-wrapper.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index ae04661e..068cdb2d 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-7.5.1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.3-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists From 95c66855b0ff7ffc7cf525269eb7bfbcdb1e9dbf Mon Sep 17 00:00:00 2001 From: Liplum Date: Thu, 7 Dec 2023 15:06:32 +0800 Subject: [PATCH 5/6] using reference for WelcomeScene, WelcomeCondition, and WelcomeAction --- assets/welcomes/en.properties | 6 +- assets/welcomes/ja.properties | 6 +- assets/welcomes/ru.properties | 6 +- assets/welcomes/uk_UA.properties | 6 +- assets/welcomes/zh_CN.properties | 6 +- .../src/net/liplum/common/ui/RateStarPanel.kt | 11 +- main/src/net/liplum/ui/CioUI.kt | 17 +- main/src/net/liplum/welcome/ActionRegistry.kt | 41 ----- main/src/net/liplum/welcome/Actions.kt | 71 -------- main/src/net/liplum/welcome/Condition.kt | 42 ----- main/src/net/liplum/welcome/SharedUI.kt | 19 +-- .../net/liplum/welcome/TemplateRegistry.kt | 40 ----- main/src/net/liplum/welcome/Templates.kt | 158 ------------------ main/src/net/liplum/welcome/Welcome.kt | 68 ++++---- main/src/net/liplum/welcome/WelcomeActions.kt | 72 ++++++++ .../{Conditions.kt => WelcomeConditions.kt} | 33 ++-- main/src/net/liplum/welcome/WelcomeScene.kt | 75 +++++++-- .../net/liplum/welcome/WelcomeTemplates.kt | 155 +++++++++++++++++ main/src/net/liplum/welcome/Welcomes.kt | 82 ++++----- 19 files changed, 396 insertions(+), 518 deletions(-) delete mode 100644 main/src/net/liplum/welcome/ActionRegistry.kt delete mode 100644 main/src/net/liplum/welcome/Actions.kt delete mode 100644 main/src/net/liplum/welcome/Condition.kt delete mode 100644 main/src/net/liplum/welcome/TemplateRegistry.kt delete mode 100644 main/src/net/liplum/welcome/Templates.kt create mode 100644 main/src/net/liplum/welcome/WelcomeActions.kt rename main/src/net/liplum/welcome/{Conditions.kt => WelcomeConditions.kt} (52%) create mode 100644 main/src/net/liplum/welcome/WelcomeTemplates.kt diff --git a/assets/welcomes/en.properties b/assets/welcomes/en.properties index 6df7ef22..03080c88 100644 --- a/assets/welcomes/en.properties +++ b/assets/welcomes/en.properties @@ -17,9 +17,9 @@ Discord.no=Mark as Junk UpdateECHO.title=Update ECHO UpdateECHO=News: Recently, the ECHO has published a new version {0}.\n\ You can click the button below to update your ECHO terminal. -UpdateECHO.button-a=[accent]Update[] -UpdateECHO.button-b=Not Now -UpdateECHO.button-c=Skip This +UpdateECHO.update=[accent]Update[] +UpdateECHO.no=Not Now +UpdateECHO.skip-this=Skip This UpdateECHO.break-update-warning=Warning: The latest version is a break update, so it may make your saves corrupted. Be careful! #v2 EmploymentVerification.title=Employment Verification diff --git a/assets/welcomes/ja.properties b/assets/welcomes/ja.properties index b579b29d..670505bb 100644 --- a/assets/welcomes/ja.properties +++ b/assets/welcomes/ja.properties @@ -17,9 +17,9 @@ Discord.no=\u30B8\u30E3\u30F3\u30AF\u3068\u3057\u3066\u30DE\u30FC\u30AF UpdateECHO.title=\uFF25\uFF23\uFF28\uFF2F\u3092\u66F4\u65B0\u3059\u308B UpdateECHO=News: \u6700\u8FD1\u3001\uFF25\uFF23\uFF28\uFF2F\u306F\u65B0\u3057\u3044\u30D0\u30FC\u30B8\u30E7\u30F3\u3092\u516C\u958B\u3057\u307E\u3057\u305F {0}\u3002\n\ \u4E0B\u306E\u30DC\u30BF\u30F3\u3092\u30AF\u30EA\u30C3\u30AF\u3057\u3066\u3001\uFF25\uFF23\uFF28\uFF2F\u7AEF\u672B\u3092\u66F4\u65B0\u3067\u304D\u307E\u3059\u3002 -UpdateECHO.button-a=\u66F4\u65B0\u3059\u308B -UpdateECHO.button-b=\u4ECA\u306F\u3084\u3081\u308D -UpdateECHO.button-c=\u8868\u793A\u3057\u306A\u3044 +UpdateECHO.update=\u66F4\u65B0\u3059\u308B +UpdateECHO.no=\u4ECA\u306F\u3084\u3081\u308D +UpdateECHO.skip-this=\u8868\u793A\u3057\u306A\u3044 #v2 EmploymentVerification.title=\u96C7\u7528\u78BA\u8A8D EmploymentVerification=\u300APlum Star Inc.\u300B\u306B\u3088\u3046\u3053\u305D\u3002\u6B64\u306E\u65B0\u3057\u3044\u30D0\u30FC\u30B8\u30E7\u30F3\u306E\u5B8C\u5168\u306A\u30B5\u30A4\u30D0\u30CD\u30C6\u30A3\u30C3\u30AF\u30B9\u3092\u304A\u697D\u3057\u307F\u304F\u3060\u3055\u3044\uFF01\n\ diff --git a/assets/welcomes/ru.properties b/assets/welcomes/ru.properties index 5849a96f..cb6cf0fd 100644 --- a/assets/welcomes/ru.properties +++ b/assets/welcomes/ru.properties @@ -17,9 +17,9 @@ Discord.no=\u041E\u0442\u043C\u0435\u0442\u0438\u0442\u044C \u043A\u0430\u043A \ UpdateECHO.title=\u041E\u0431\u043D\u043E\u0432\u0438\u0442\u044C \u042D\u0425\u041E UpdateECHO=\u041D\u043E\u0432\u043E\u0441\u0442\u0438: \u041D\u0435\u0434\u0430\u0432\u043D\u043E ECHO \u043E\u043F\u0443\u0431\u043B\u0438\u043A\u043E\u0432\u0430\u043B\u043E \u043D\u043E\u0432\u0443\u044E \u0432\u0435\u0440\u0441\u0438\u044E {0}.\n\ \u0412\u044B \u043C\u043E\u0436\u0435\u0442\u0435 \u043D\u0430\u0436\u0430\u0442\u044C \u043A\u043D\u043E\u043F\u043A\u0443 \u043D\u0438\u0436\u0435, \u0447\u0442\u043E\u0431\u044B \u043E\u0431\u043D\u043E\u0432\u0438\u0442\u044C \u0441\u0432\u043E\u0439 \u0442\u0435\u0440\u043C\u0438\u043D\u0430\u043B ECHO. -UpdateECHO.button-a=\u041E\u0431\u043D\u043E\u0432\u043B\u044F\u0442\u044C -UpdateECHO.button-b=\u041D\u0435 \u0441\u0435\u0439\u0447\u0430\u0441 -UpdateECHO.button-c=\u0411\u043E\u043B\u044C\u0448\u0435 \u043D\u0435 \u043F\u043E\u043A\u0430\u0437\u044B\u0432\u0430\u0442\u044C +UpdateECHO.update=\u041E\u0431\u043D\u043E\u0432\u043B\u044F\u0442\u044C +UpdateECHO.no=\u041D\u0435 \u0441\u0435\u0439\u0447\u0430\u0441 +UpdateECHO.skip-this=\u0411\u043E\u043B\u044C\u0448\u0435 \u043D\u0435 \u043F\u043E\u043A\u0430\u0437\u044B\u0432\u0430\u0442\u044C #v2 EmploymentVerification.title=\u041F\u0440\u043E\u0432\u0435\u0440\u043A\u0430 \u0437\u0430\u043D\u044F\u0442\u043E\u0441\u0442\u0438 EmploymentVerification=\u041F\u0440\u0438\u0441\u043E\u0435\u0434\u0438\u043D\u044F\u0439\u0442\u0435\u0441\u044C \u043A \u043D\u0430\u043C, Plum Star Inc., \u043D\u0430\u0441\u043B\u0430\u0436\u0434\u0430\u0439\u0442\u0435\u0441\u044C \u044D\u0442\u043E\u0439 \u043D\u043E\u0432\u043E\u0439 \u0432\u0435\u0440\u0441\u0438\u0435\u0439 \u043F\u043E\u043B\u043D\u043E\u0439 \u043A\u0438\u0431\u0435\u0440\u043D\u0435\u0442\u0438\u043A\u0438!\n\ diff --git a/assets/welcomes/uk_UA.properties b/assets/welcomes/uk_UA.properties index c4f75dda..88dfecfa 100644 --- a/assets/welcomes/uk_UA.properties +++ b/assets/welcomes/uk_UA.properties @@ -17,9 +17,9 @@ Discord.no=\u0412\u0438\u0434\u0430\u043B\u0438\u0442\u0438 UpdateECHO.title=\u041E\u043D\u043E\u0432\u0438\u0442\u0438 ECHO UpdateECHO=\u041D\u043E\u0432\u0438\u043D\u0438: \u043D\u0435\u0449\u043E\u0434\u0430\u0432\u043D\u043E ECHO \u043E\u043F\u0443\u0431\u043B\u0456\u043A\u0443\u0432\u0430\u043B\u0438 \u043D\u043E\u0432\u0443 \u0432\u0435\u0440\u0441\u0456\u044E: {0}.\n\ \u0412\u0438 \u043C\u043E\u0436\u0435\u0442\u0435 \u043D\u0430\u0442\u0438\u0441\u043D\u0443\u0442\u0438 \u043A\u043D\u043E\u043F\u043A\u0443 \u043D\u0438\u0436\u0447\u0435, \u0449\u043E\u0431 \u043E\u043D\u043E\u0432\u0438\u0442\u0438 \u0442\u0435\u0440\u043C\u0456\u043D\u0430\u043B ECHO. -UpdateECHO.button-a=\u041E\u043D\u043E\u0432\u0438\u0442\u0438 -UpdateECHO.button-b=\u041D\u0435 \u0437\u0430\u0440\u0430\u0437 -UpdateECHO.button-c=\u041D\u0435 \u043F\u043E\u043A\u0430\u0437\u0443\u0432\u0430\u0442\u0438 +UpdateECHO.update=\u041E\u043D\u043E\u0432\u0438\u0442\u0438 +UpdateECHO.no=\u041D\u0435 \u0437\u0430\u0440\u0430\u0437 +UpdateECHO.skip-this=\u041D\u0435 \u043F\u043E\u043A\u0430\u0437\u0443\u0432\u0430\u0442\u0438 #v2 EmploymentVerification.title=\u041F\u0456\u0434\u0442\u0432\u0435\u0440\u0434\u0436\u0435\u043D\u043D\u044F \u043F\u0440\u0430\u0446\u0435\u0432\u043B\u0430\u0448\u0442\u0443\u0432\u0430\u043D\u043D\u044F EmploymentVerification=\u041B\u0430\u0441\u043A\u0430\u0432\u043E \u043F\u0440\u043E\u0441\u0438\u043C\u043E \u0434\u043E \u043D\u0430\u0441, \u00AB\u041F\u043B\u044E\u043C \u0421\u0442\u0430\u0440 \u0406\u043D\u043A\u043E\u0440\u043F\u043E\u0440\u0435\u0439\u0448\u043D\u00BB, \u043D\u0430\u0441\u043E\u043B\u043E\u0434\u0436\u0443\u0439\u0442\u0435\u0441\u044C \u0446\u0456\u0454\u044E \u043D\u043E\u0432\u043E\u044E \u0432\u0435\u0440\u0441\u0456\u0454\u044E, \u0449\u043E \u0441\u043F\u043E\u0432\u043D\u0435\u043D\u0430 \u043A\u0443\u043F\u043E\u044E \u043A\u0456\u0431\u0435\u0440\u043D\u0435\u0442\u0438\u0447\u043D\u0438\u0445 \u0440\u0435\u0447\u0435\u0439!\n\ diff --git a/assets/welcomes/zh_CN.properties b/assets/welcomes/zh_CN.properties index 3bcd9871..e35e50e2 100644 --- a/assets/welcomes/zh_CN.properties +++ b/assets/welcomes/zh_CN.properties @@ -17,9 +17,9 @@ Discord.no=\u6807\u8BB0\u4E3A\u5783\u573E\u5185\u5BB9 UpdateECHO.title=\u66F4\u65B0\u201C\u98DE\u58F0\u201D UpdateECHO=News: \u6700\u8FD1\uFF0C\u201C\u98DE\u58F0\u201D\u7EC8\u7AEF\u63A8\u51FA\u4E86\u65B0\u7248\u672C{0}\u3002\n\ \u4F60\u53EF\u4EE5\u70B9\u51FB\u4E0B\u9762\u7684\u6309\u94AE\u66F4\u65B0\u4F60\u7684\u7EC8\u7AEF -UpdateECHO.button-a=[accent]\u66F4\u65B0[] -UpdateECHO.button-b=\u4EE5\u540E\u63D0\u9192\u6211 -UpdateECHO.button-c=\u4E0D\u518D\u663E\u793A +UpdateECHO.update=[accent]\u66F4\u65B0[] +UpdateECHO.no=\u4EE5\u540E\u63D0\u9192\u6211 +UpdateECHO.skip-this=\u4E0D\u518D\u663E\u793A UpdateECHO.break-update-warning=\u8B66\u544A\uFF1A\u6700\u65B0\u7248\u672C\u7684\u66F4\u65B0\u5DF2\u635F\u574F\uFF0C\u53EF\u80FD\u4F1A\u5BFC\u81F4\u5B58\u6863\u9519\u8BEF\u3002\u8BF7\u52A1\u5FC5\u8C28\u614E\uFF01 #v2 EmploymentVerification.title=\u9A8C\u8BC1\u96C7\u4F63\u72B6\u6001 diff --git a/common/src/net/liplum/common/ui/RateStarPanel.kt b/common/src/net/liplum/common/ui/RateStarPanel.kt index e59710df..86b483b2 100644 --- a/common/src/net/liplum/common/ui/RateStarPanel.kt +++ b/common/src/net/liplum/common/ui/RateStarPanel.kt @@ -5,11 +5,12 @@ import arc.scene.ui.ImageButton import arc.scene.ui.layout.Table import plumy.core.assets.TR -class RateStarPanelBuilder { - var starNumber = 5 - var starSize = 50f - var inactiveStar: TR = TR() - var activeStar: TR = TR() +class RateStarPanelBuilder( + val starNumber: Int = 5, + val starSize: Float = 50f, + val activeStar: TR = TR(), + val inactiveStar: TR = TR(), +) { inline fun build( crossinline onRate: (Int) -> Unit = {}, ): Table = Table().apply { diff --git a/main/src/net/liplum/ui/CioUI.kt b/main/src/net/liplum/ui/CioUI.kt index 2e28781c..3e8201f4 100644 --- a/main/src/net/liplum/ui/CioUI.kt +++ b/main/src/net/liplum/ui/CioUI.kt @@ -31,8 +31,8 @@ import net.liplum.ui.settings.SliderSettingX.Companion.addSliderSettingX import net.liplum.update.Updater import net.liplum.utils.IsLocal import net.liplum.utils.safeCall -import net.liplum.welcome.Conditions import net.liplum.welcome.Welcome +import net.liplum.welcome.WelcomeConditions import net.liplum.welcome.Welcomes import net.liplum.welcome.findAll import plumy.core.ClientOnly @@ -167,19 +167,18 @@ object CioUI { Updater.accessJob?.join() if (!failed) { if (Updater.requireUpdate) { - val updateTips = Welcomes.findAll { tip -> - tip.condition == Conditions.CheckUpdate + val updateScenes = Welcomes.findAll { tip -> + tip.condition == WelcomeConditions.CheckUpdate } - if (updateTips.isEmpty()) { + if (updateScenes.isEmpty()) { ShowTextDialog(bundle("not-support")) } else { - val updateTip = updateTips.randomExcept(atLeastOne = true) { + val updateScene = updateScenes.randomExcept(atLeastOne = true) { id != Settings.LastWelcomeID } - if (updateTip != null) - Welcome.genEntity().apply { - tip = updateTip - }.showTip() + Welcomes.updateECHO + if (updateScene != null) + Welcome.createEntity(updateScene).showTip() else ShowTextDialog(bundle("not-support")) } diff --git a/main/src/net/liplum/welcome/ActionRegistry.kt b/main/src/net/liplum/welcome/ActionRegistry.kt deleted file mode 100644 index 5727dd08..00000000 --- a/main/src/net/liplum/welcome/ActionRegistry.kt +++ /dev/null @@ -1,41 +0,0 @@ -package net.liplum.welcome - -import net.liplum.welcome.ActionRegistry.register - -object ActionRegistry { - val actions: MutableMap = HashMap() - operator fun get(id: String) = - actions[id] ?: Action.Default - - operator fun get(id: Any?) = - (id as? String)?.let { actions[it] } ?: Action.Default - - operator fun set(id: String, action: Action) { - actions[id] = action - } - - fun T.register(): T { - this@ActionRegistry[id] = this - return this - } -} - -abstract class Action( - val id: String, -) { - init { - this.register() - } - - abstract fun doAction(entity: Welcome.Entity) - operator fun invoke(entity: Welcome.Entity) { - doAction(entity) - } - - companion object { - val Default = object : Action("Default") { - override fun doAction(entity: Welcome.Entity) { - } - } - } -} diff --git a/main/src/net/liplum/welcome/Actions.kt b/main/src/net/liplum/welcome/Actions.kt deleted file mode 100644 index 40a1dde8..00000000 --- a/main/src/net/liplum/welcome/Actions.kt +++ /dev/null @@ -1,71 +0,0 @@ -package net.liplum.welcome - -import arc.Core -import net.liplum.CLog -import net.liplum.Settings -import net.liplum.Var -import net.liplum.ui.Navigator -import net.liplum.update.Updater - -object Actions { - val OpenLink = object : Action("OpenLink") { - override fun doAction(entity: Welcome.Entity) { - val data = entity.tip.data - var link = data["Link"] as? String - if (link != null) { - link = if (link.startsWith('@')) - entity[link.substring(1)] - else - link - Core.app.openURI(link) - } - } - } - val CloseReceiveWelcome = object : Action("StopReceiveWelcome") { - override fun doAction(entity: Welcome.Entity) { - Settings.ShouldShowWelcome = false - } - } - val StopCheckUpdate = object : Action("StopCheckUpdate") { - override fun doAction(entity: Welcome.Entity) { - Settings.ShowUpdate = false - } - } - val SkipThisUpdate = object : Action("SkipThisUpdate") { - override fun doAction(entity: Welcome.Entity) { - val latest = Updater.latestVersion - Settings.LastSkippedUpdate = latest.toString() - } - } - val UpdateCyberIO = object : Action("UpdateCyberIO") { - override fun doAction(entity: Welcome.Entity) { - Updater.Release.update() - } - } - val CallStaticFunction = object : Action("CallStaticFunction") { - override fun doAction(entity: Welcome.Entity) { - val data = entity.tip.data - val clzName = data["ClassFullName"] as? String - val funcName = data["StaticFunctionName"] as? String - if (clzName != null && funcName != null) { - try { - val clz = Class.forName(clzName) - val method = clz.getMethod(funcName) - method.invoke(null) - } catch (e: Exception) { - CLog.err("In action [$id]", e) - } - } - } - } - val Navigation = object : Action("Navigation") { - override fun doAction(entity: Welcome.Entity) { - val data = entity.tip.data - val locatorText = data["Locator"] as? String - if (locatorText != null) { - val locator = Navigator.by(locatorText) - Var.Navigation.navigate(locator) - } - } - } -} \ No newline at end of file diff --git a/main/src/net/liplum/welcome/Condition.kt b/main/src/net/liplum/welcome/Condition.kt deleted file mode 100644 index c5651409..00000000 --- a/main/src/net/liplum/welcome/Condition.kt +++ /dev/null @@ -1,42 +0,0 @@ -package net.liplum.welcome - -import net.liplum.welcome.ConditionRegistry.register - -object ConditionRegistry { - val conditions: MutableMap = HashMap() - operator fun get(id: String) = - conditions[id] ?: Condition.Default - - operator fun get(id: Any?) = - (id as? String)?.let { conditions[it] } ?: Condition.Default - - operator fun set(id: String, condition: Condition) { - conditions[id] = condition - } - - fun T.register(): T { - this@ConditionRegistry[id] = this - return this - } -} - -abstract class Condition( - val id: String, -) { - init { - this.register() - } - - abstract fun canShow(tip: WelcomeScene): Boolean - abstract fun priority(tip: WelcomeScene): Int - - companion object { - val Default = object : Condition("Default") { - override fun canShow(tip: WelcomeScene): Boolean { - return false - } - - override fun priority(tip: WelcomeScene) = Int.MIN_VALUE - } - } -} \ No newline at end of file diff --git a/main/src/net/liplum/welcome/SharedUI.kt b/main/src/net/liplum/welcome/SharedUI.kt index ffa6fe8a..b1a11540 100644 --- a/main/src/net/liplum/welcome/SharedUI.kt +++ b/main/src/net/liplum/welcome/SharedUI.kt @@ -7,14 +7,13 @@ import arc.scene.ui.Label import arc.scene.ui.TextButton import arc.scene.ui.layout.Cell import arc.scene.ui.layout.Table -import arc.scene.utils.Elem import arc.util.Scaling import mindustry.gen.Tex import net.liplum.Meta import net.liplum.Var import net.liplum.i18nName -import plumy.core.assets.TR import plumy.core.DesktopOnly +import plumy.core.assets.TR internal fun Dialog.addPoster( icon: TR, @@ -35,7 +34,7 @@ internal fun Dialog.addPoster( return img } -internal fun Dialog.addPoliteWelcome(entity: Welcome.Entity) { +internal fun Dialog.addPoliteWelcome(entity: WelcomeEntity) { addCenterText( entity.bundle.format( "welcome", @@ -79,22 +78,12 @@ internal fun Dialog.addBoxedText( internal inline fun Dialog.addCloseButton( text: String, table: Table = this.cont, + width: Float = 200f, crossinline task: () -> Unit = {}, ): Cell { return table.button(text) { Welcome.recordClick() task() hide() - }.size(200f, 50f) -} - -internal inline fun Dialog.createCloseButton( - text: String, - crossinline task: () -> Unit = {}, -): TextButton { - return Elem.newButton(text) { - Welcome.recordClick() - task() - hide() - } + }.size(width, 50f) } diff --git a/main/src/net/liplum/welcome/TemplateRegistry.kt b/main/src/net/liplum/welcome/TemplateRegistry.kt deleted file mode 100644 index 0afe878a..00000000 --- a/main/src/net/liplum/welcome/TemplateRegistry.kt +++ /dev/null @@ -1,40 +0,0 @@ -package net.liplum.welcome - -import arc.scene.ui.Dialog -import mindustry.ui.dialogs.BaseDialog -import net.liplum.welcome.TemplateRegistry.register - -object TemplateRegistry { - val templates: MutableMap = HashMap() - operator fun get(id: String) = - templates[id] ?: WelcomeTemplate.Default - - operator fun set(id: String, template: WelcomeTemplate) { - templates[id] = template - } - - fun T.register(): T { - this@TemplateRegistry[id] = this - return this - } -} - -abstract class WelcomeTemplate( - val id: String, -) { - init { - this.register() - } - - abstract fun gen(entity: Welcome.Entity): Dialog - - companion object { - val Default = object : WelcomeTemplate("Default") { - override fun gen(entity: Welcome.Entity) = - BaseDialog(entity.bundle["Default.title"]).apply { - cont.add(entity.bundle["Default"]) - addCloseButton() - } - } - } -} diff --git a/main/src/net/liplum/welcome/Templates.kt b/main/src/net/liplum/welcome/Templates.kt deleted file mode 100644 index c81f1ef7..00000000 --- a/main/src/net/liplum/welcome/Templates.kt +++ /dev/null @@ -1,158 +0,0 @@ -package net.liplum.welcome - -import arc.scene.ui.Button -import mindustry.ui.dialogs.BaseDialog -import net.liplum.R -import net.liplum.Var -import plumy.core.arc.tinted -import net.liplum.common.ui.RateStarPanelBuilder -import net.liplum.update.Updater -import net.liplum.welcome.Welcome.Entity -import net.liplum.welcome.Welcome.handleTrRefer - -object Templates { - val Story = object : WelcomeTemplate("Story") { - override fun gen(entity: Entity) = - BaseDialog(entity["title"]).apply { - addCloseListener() - val data = entity.tip.data - addPoster(entity.icon) - val showPoliteWelcome = data["ShowPoliteWelcome"] as? Boolean ?: true - if (showPoliteWelcome) addPoliteWelcome(entity) - addCenterText(entity.content) - addCloseButton(entity["read"]) - } - } - val ButtonABC = object : WelcomeTemplate("ButtonABC") { - override fun gen(entity: Entity) = - BaseDialog(entity["title"]).apply { - addCloseListener() - val data = entity.tip.data - val yesAction = ActionRegistry[data["ActionA"]] - val noAction = ActionRegistry[data["ActionB"]] - val dontShowAction = ActionRegistry[data["ActionC"]] - val showPoliteWelcome = data["ShowPoliteWelcome"] as? Boolean ?: true - addPoster(entity.icon) - if (showPoliteWelcome) addPoliteWelcome(entity) - cont.table { - addCloseButton(entity["button-a"], it) { - yesAction(entity) - }.size(150f, 50f) - addCloseButton(entity["button-b"], it) { - noAction(entity) - }.size(150f, 50f) - addCloseButton(entity["button-c"], it) { - dontShowAction(entity) - }.size(150f, 50f) - }.growX() - .row() - } - } - val DoAction = object : WelcomeTemplate("DoAction") { - override fun gen(entity: Entity) = - BaseDialog(entity["title"]).apply { - addCloseListener() - val data = entity.tip.data - addPoster(entity.icon) - val showPoliteWelcome = data["ShowPoliteWelcome"] as? Boolean ?: false - if (showPoliteWelcome) addPoliteWelcome(entity) - val yesAction = ActionRegistry[data["YesAction"]] - val noAction = ActionRegistry[data["NoAction"]] - addCenterText(entity.content) - cont.table { - fun addButton(vararg buttons: Button) { - for (b in buttons) - it.add(b).size(200f, 50f) - } - - val yes = createCloseButton(entity["yes"]) { - yesAction(entity) - } - val no = createCloseButton(entity["no"]) { - noAction(entity) - } - addButton(yes, no) - }.growX() - .row() - } - } - val TextIcon = object : WelcomeTemplate("TextIcon") { - override fun gen(entity: Entity) = - BaseDialog(entity["title"]).apply { - addCloseListener() - val data = entity.tip.data - val text = data["Text"] as? String ?: "" - val fontSize = data["FontSize"] as? Float ?: 1f - val resText = entity.bundle.handleRefer(text) - addCenterText(resText).get().apply { - this.setFontScale(fontSize) - } - val showPoliteWelcome = data["ShowPoliteWelcome"] as? Boolean ?: true - if (showPoliteWelcome) addPoliteWelcome(entity) - addCenterText(entity.content) - addCloseButton(entity["read"]) - } - } - val PlainText = object : WelcomeTemplate("PlainText") { - override fun gen(entity: Entity) = - BaseDialog(entity["title"]).apply { - addCloseListener() - val data = entity.tip.data - val showPoliteWelcome = data["ShowPoliteWelcome"] as? Boolean ?: true - if (showPoliteWelcome) addPoliteWelcome(entity) - val fontSize = data["FontSize"] as? Float ?: 1f - addCenterText(entity.content).pad(40f).get().apply { - this.setFontScale(fontSize) - } - addCloseButton(entity["read"]) - } - } - val rateStar = object : WelcomeTemplate("RateStar") { - override fun gen(entity: Entity) = - BaseDialog(entity["title"]).apply { - addCloseListener() - val data = entity.tip.data - addPoster(entity.icon) - val showPoliteWelcome = data["ShowPoliteWelcome"] as? Boolean ?: true - if (showPoliteWelcome) addPoliteWelcome(entity) - addCenterText(entity.content) - val starSize = data["StarSize"] as? Float ?: 50f - val ratePanel = RateStarPanelBuilder().apply { - starNumber = 5 - this.starSize = starSize - (data["InactiveStarIconPath"] as? String)?.let { inactiveStar = it.handleTrRefer() } - (data["ActiveStarIconPath"] as? String)?.let { activeStar = it.handleTrRefer() } - }.build() - cont.add(ratePanel).row() - addCloseButton(entity["submit"]) - } - } - val Update = object : WelcomeTemplate("Update") { - override fun gen(entity: Entity) = - BaseDialog(entity["title"]).apply { - addCloseListener() - val data = entity.tip.data - val yesAction = ActionRegistry[data["ActionA"]] - val noAction = ActionRegistry[data["ActionB"]] - val dontShowAction = ActionRegistry[data["ActionC"]] - addPoster(entity.icon) - addCenterText(entity.content(Updater.latestVersion.toString().tinted(Var.Hologram))) - if (Updater.isCurrentBreakUpdate) - addCenterText(entity["break-update-warning"]).color(R.C.RedAlert) - if (Updater.hasUpdateDescription) - addBoxedText(Updater.UpdateDescription) - cont.table { - addCloseButton(entity["button-a"], it) { - yesAction(entity) - }.size(150f, 50f) - addCloseButton(entity["button-b"], it) { - noAction(entity) - }.size(150f, 50f) - addCloseButton(entity["button-c"], it) { - dontShowAction(entity) - }.size(150f, 50f) - }.growX() - .row() - } - } -} \ No newline at end of file diff --git a/main/src/net/liplum/welcome/Welcome.kt b/main/src/net/liplum/welcome/Welcome.kt index 68449566..641a97dc 100644 --- a/main/src/net/liplum/welcome/Welcome.kt +++ b/main/src/net/liplum/welcome/Welcome.kt @@ -21,6 +21,7 @@ import net.liplum.common.util.allMaxBy import net.liplum.common.util.randomExcept import net.liplum.event.CioInitEvent import net.liplum.math.randomByWeights +import net.liplum.welcome.Welcome.handleTrRefer import plumy.core.ClientOnly import plumy.core.assets.TR import plumy.dsl.sprite @@ -29,18 +30,12 @@ import plumy.dsl.sprite object Welcome { var bundle = ReferBundleWrapper.create() private var version = WelcomeScenePacks.v5_1 - fun genEntity() = Entity(bundle, version) - private var entity = genEntity() - private var showWelcome = false @JvmStatic @ClientOnly fun showWelcomeDialog() { checkLastVersion() - judgeWelcome() - if (showWelcome) { - entity.showTip() - } + judgeWelcome()?.showTip() //For debug /*val tip = WelcomeList.find { it.id == "SetOutErekir" } tip?.condition?.canShow(tip)*/ @@ -48,13 +43,12 @@ object Welcome { } @JvmStatic - fun judgeWelcome() { + fun judgeWelcome(): WelcomeEntity? { val allTips = version.scenes.distinct().toList() val tipsCanShow = allTips.filter { it.condition.canShow(it) } val allCandidates = tipsCanShow.allMaxBy { it.condition.priority(it) } if (allCandidates.isEmpty()) { - showWelcome = false - return + return null } var sumChance = 0 val weights = IntArray(allCandidates.size) { @@ -72,9 +66,13 @@ object Welcome { } if (res != null) { LastWelcomeID = res.id - entity.tip = res - showWelcome = true + return createEntity(res) } + return null + } + + fun createEntity(scene: WelcomeScene): WelcomeEntity { + return WelcomeEntity(bundle, version, scene) } @JvmStatic @@ -111,9 +109,9 @@ object Welcome { fun load() { loadBundle() //To load all templates and actions - Templates - Actions - Conditions + WelcomeTemplates + WelcomeActions + WelcomeConditions } @JvmStatic @@ -128,34 +126,26 @@ object Welcome { if (startsWith('@')) removePrefix("@").sprite else cio.sprite +} - class Entity( - val bundle: ReferBundleWrapper, - val info: WelcomeScenePack, - ) { - var tip: WelcomeScene = WelcomeScene.Default - operator fun get(key: String) = - bundle["$tip.$key"] - - val content: String - get() = bundle["$tip"] +class WelcomeEntity( + val bundle: ReferBundleWrapper, + val info: WelcomeScenePack, + val scene: WelcomeScene, +) { + operator fun get(key: String) = + bundle["$scene.$key"] - fun content(vararg args: Any): String = - bundle.format("$tip", *args) + val content: String + get() = bundle["$scene"] - val icon: TR - get() = tip.iconPath.handleTrRefer() + fun content(vararg args: Any): String = + bundle.format("$scene", *args) - fun showTip() { - tip.template.gen(this).show() - } + val icon: TR + get() = scene.iconPath.handleTrRefer() - companion object { - fun Entity.showTipByID(id: String): Entity { - tip = Welcomes[id] - showTip() - return this - } - } + fun showTip() { + scene.template.gen(this).show() } } diff --git a/main/src/net/liplum/welcome/WelcomeActions.kt b/main/src/net/liplum/welcome/WelcomeActions.kt new file mode 100644 index 00000000..b3e00c7c --- /dev/null +++ b/main/src/net/liplum/welcome/WelcomeActions.kt @@ -0,0 +1,72 @@ +package net.liplum.welcome + +import arc.Core +import net.liplum.CLog +import net.liplum.Settings +import net.liplum.Var +import net.liplum.ui.Navigator +import net.liplum.update.Updater + +object WelcomeActions { + class OpenLink( + val link: String, + ) : WelcomeAction() { + override fun doAction(entity: WelcomeEntity) { + var link = this.link + link = if (link.startsWith('@')) + entity[link.substring(1)] + else + link + Core.app.openURI(link) + } + } + + object StopReceiveWelcome : WelcomeAction() { + override fun doAction(entity: WelcomeEntity) { + Settings.ShouldShowWelcome = false + } + } + + object StopCheckUpdate : WelcomeAction() { + override fun doAction(entity: WelcomeEntity) { + Settings.ShowUpdate = false + } + } + + object SkipThisUpdate : WelcomeAction() { + override fun doAction(entity: WelcomeEntity) { + val latest = Updater.latestVersion + Settings.LastSkippedUpdate = latest.toString() + } + } + + object UpdateCyberIO : WelcomeAction() { + override fun doAction(entity: WelcomeEntity) { + Updater.Release.update() + } + } + + class CallStaticFunction( + val classFullName: String, + val funcName: String, + ) : WelcomeAction() { + override fun doAction(entity: WelcomeEntity) { + try { + val clz = Class.forName(classFullName) + val method = clz.getMethod(funcName) + method.invoke(null) + } catch (e: Exception) { + CLog.err("Failed to call ${classFullName}.${funcName}", e) + } + } + } + + class Navigation( + val destination: String, + ) : WelcomeAction() { + override fun doAction(entity: WelcomeEntity) { + val locator = Navigator.by(destination) + Var.Navigation.navigate(locator) + } + } +} \ No newline at end of file diff --git a/main/src/net/liplum/welcome/Conditions.kt b/main/src/net/liplum/welcome/WelcomeConditions.kt similarity index 52% rename from main/src/net/liplum/welcome/Conditions.kt rename to main/src/net/liplum/welcome/WelcomeConditions.kt index 29588721..4f5c7bae 100644 --- a/main/src/net/liplum/welcome/Conditions.kt +++ b/main/src/net/liplum/welcome/WelcomeConditions.kt @@ -3,18 +3,17 @@ package net.liplum.welcome import mindustry.Vars import net.liplum.Settings import net.liplum.update.Updater -import opengal.core.IExpressionReceiver -import opengal.experssion.ExpressionParser -object Conditions { - val ShowWelcome = object : Condition("ShowWelcome") { +object WelcomeConditions { + object ShowWelcome : WelcomeCondition() { override fun canShow(tip: WelcomeScene): Boolean { return Settings.ShouldShowWelcome } override fun priority(tip: WelcomeScene) = 0 } - val CheckUpdate = object : Condition("CheckUpdate") { + + object CheckUpdate : WelcomeCondition() { override fun canShow(tip: WelcomeScene): Boolean { return !Vars.steam && Settings.ShowUpdate && Updater.requireUpdate && @@ -24,7 +23,8 @@ object Conditions { override fun priority(tip: WelcomeScene) = 10 } - val SpecialDishes = object : Condition("SpecialDishes") { + + object SpecialDishes : WelcomeCondition() { override fun canShow(tip: WelcomeScene): Boolean { return Settings.ShouldShowWelcome } @@ -32,22 +32,15 @@ object Conditions { override fun priority(tip: WelcomeScene) = if (Settings.ClickWelcomeTimes == 0) 5 else 0 } - val SettingsReq = object : Condition("SettingsReq") { + + class Expr( + val priority: Int = 0, + val expr: () -> Boolean, + ) : WelcomeCondition() { override fun canShow(tip: WelcomeScene): Boolean { - val data = tip.data - val exprRaw = data["CExpression"] as? String ?: "" - val expr = ExpressionParser.by(exprRaw).parse() - return expr.calculate(ExprSettingsWrapper) + return expr() } - override fun priority(tip: WelcomeScene) = 0 - } - - object ExprSettingsWrapper : IExpressionReceiver { - override fun set(name: String, value: Any) = - throw NotImplementedError("Can't set $name as $value") - - override fun get(name: String): T = - Settings[name] + override fun priority(tip: WelcomeScene) = priority } } \ No newline at end of file diff --git a/main/src/net/liplum/welcome/WelcomeScene.kt b/main/src/net/liplum/welcome/WelcomeScene.kt index c246b3c3..105e1be9 100644 --- a/main/src/net/liplum/welcome/WelcomeScene.kt +++ b/main/src/net/liplum/welcome/WelcomeScene.kt @@ -1,26 +1,24 @@ package net.liplum.welcome +import arc.scene.ui.Dialog +import mindustry.ui.dialogs.BaseDialog + class WelcomeScene( - @JvmField var id: String = DefaultID, - @JvmField var conditionID: String = DefaultCondition, - @JvmField var templateID: String = DefaultTemplateID, - @JvmField var iconPath: String = DefaultIconPath, - @JvmField var chance: Int = DefaultChance, - @JvmField var data: Map = emptyMap(), + @JvmField val id: String, + @JvmField val condition: WelcomeCondition = WelcomeCondition.Default, + @JvmField val template: WelcomeTemplate = WelcomeTemplate.Default, + @JvmField var iconPath: String = "icon", + @JvmField var chance: Int = 100, ) { override fun toString() = id - val template: WelcomeTemplate - get() = TemplateRegistry[templateID] - val condition: Condition - get() = ConditionRegistry[conditionID] companion object { - val Default = WelcomeScene() - const val DefaultID = "Default" - const val DefaultCondition = "ShowWelcome" - const val DefaultTemplateID = "Story" - const val DefaultChance = 1000 - const val DefaultIconPath = "icon" + val Default = WelcomeScene( + id = "Default", + condition = WelcomeConditions.ShowWelcome, + template = WelcomeTemplates.Story(), + chance = 0, + ) } } @@ -46,4 +44,47 @@ class WelcomeScenePack( scenes = this.scenes + scenes, ) } -} \ No newline at end of file +} + +abstract class WelcomeTemplate { + abstract fun gen(entity: WelcomeEntity): Dialog + + companion object { + val Default = object : WelcomeTemplate() { + override fun gen(entity: WelcomeEntity) = + BaseDialog(entity.bundle["Default.title"]).apply { + cont.add(entity.bundle["Default"]) + addCloseButton() + } + } + } +} + +abstract class WelcomeCondition { + abstract fun canShow(tip: WelcomeScene): Boolean + abstract fun priority(tip: WelcomeScene): Int + + companion object { + val Default = object : WelcomeCondition() { + override fun canShow(tip: WelcomeScene): Boolean { + return false + } + + override fun priority(tip: WelcomeScene) = Int.MIN_VALUE + } + } +} + +abstract class WelcomeAction { + abstract fun doAction(entity: WelcomeEntity) + operator fun invoke(entity: WelcomeEntity) { + doAction(entity) + } + + companion object { + val Default = object : WelcomeAction() { + override fun doAction(entity: WelcomeEntity) { + } + } + } +} diff --git a/main/src/net/liplum/welcome/WelcomeTemplates.kt b/main/src/net/liplum/welcome/WelcomeTemplates.kt new file mode 100644 index 00000000..617374d8 --- /dev/null +++ b/main/src/net/liplum/welcome/WelcomeTemplates.kt @@ -0,0 +1,155 @@ +package net.liplum.welcome + +import mindustry.ui.dialogs.BaseDialog +import net.liplum.R +import net.liplum.Var +import net.liplum.common.ui.RateStarPanelBuilder +import net.liplum.update.Updater +import net.liplum.welcome.Welcome.handleTrRefer +import plumy.core.arc.tinted + + +object WelcomeTemplates { + class Story( + val showPoliteWelcome: Boolean = true, + ) : WelcomeTemplate() { + override fun gen(entity: WelcomeEntity) = + BaseDialog(entity["title"]).apply { + addCloseListener() + addPoster(entity.icon) + if (showPoliteWelcome) addPoliteWelcome(entity) + addCenterText(entity.content) + addCloseButton(entity["read"]) + } + } + + class ButtonABC( + val actionA: WelcomeAction = WelcomeAction.Default, + val actionB: WelcomeAction = WelcomeAction.Default, + val actionC: WelcomeAction = WelcomeAction.Default, + val showPoliteWelcome: Boolean = true, + ) : WelcomeTemplate() { + override fun gen(entity: WelcomeEntity) = + BaseDialog(entity["title"]).apply { + addCloseListener() + addPoster(entity.icon) + if (showPoliteWelcome) addPoliteWelcome(entity) + cont.table { + addCloseButton(entity["button-a"], it, 200f) { + actionA(entity) + } + addCloseButton(entity["button-b"], it, 200f) { + actionB(entity) + } + addCloseButton(entity["button-c"], it, 200f) { + actionC(entity) + } + }.growX() + .row() + } + } + + class DoAction( + val yesAction: WelcomeAction = WelcomeAction.Default, + val noAction: WelcomeAction = WelcomeAction.Default, + val showPoliteWelcome: Boolean = true, + ) : WelcomeTemplate() { + override fun gen(entity: WelcomeEntity) = + BaseDialog(entity["title"]).apply { + addCloseListener() + addPoster(entity.icon) + if (showPoliteWelcome) addPoliteWelcome(entity) + addCenterText(entity.content) + cont.table { + addCloseButton(entity["yes"]) { + yesAction(entity) + } + addCloseButton(entity["no"]) { + noAction(entity) + } + }.growX() + .row() + } + } + + class TextIcon( + val text: String = "", + val fontSize: Float = 1f, + val showPoliteWelcome: Boolean = true, + ) : WelcomeTemplate() { + override fun gen(entity: WelcomeEntity) = + BaseDialog(entity["title"]).apply { + addCloseListener() + val resText = entity.bundle.handleRefer(text) + addCenterText(resText).get().apply { + this.setFontScale(fontSize) + } + if (showPoliteWelcome) addPoliteWelcome(entity) + addCenterText(entity.content) + addCloseButton(entity["read"]) + } + } + + class PlainText( + val fontSize: Float = 1f, + val showPoliteWelcome: Boolean = true, + ) : WelcomeTemplate() { + override fun gen(entity: WelcomeEntity) = + BaseDialog(entity["title"]).apply { + addCloseListener() + if (showPoliteWelcome) addPoliteWelcome(entity) + addCenterText(entity.content).pad(40f).get().apply { + this.setFontScale(fontSize) + } + addCloseButton(entity["read"]) + } + } + + class RateStar( + val starSize: Float = 50f, + val starNumber: Int = 5, + val activeStarIconPath: String, + val inactiveStarIconPath: String, + val showPoliteWelcome: Boolean = true, + ) : WelcomeTemplate() { + override fun gen(entity: WelcomeEntity) = + BaseDialog(entity["title"]).apply { + addCloseListener() + addPoster(entity.icon) + if (showPoliteWelcome) addPoliteWelcome(entity) + addCenterText(entity.content) + val ratePanel = RateStarPanelBuilder( + starNumber = starNumber, + starSize = starSize, + activeStar = activeStarIconPath.handleTrRefer(), + inactiveStar = inactiveStarIconPath.handleTrRefer(), + ).build() + cont.add(ratePanel).row() + addCloseButton(entity["submit"]) + } + } + + object UpdateCyberIO : WelcomeTemplate() { + override fun gen(entity: WelcomeEntity) = + BaseDialog(entity["title"]).apply { + addCloseListener() + addPoster(entity.icon) + addCenterText(entity.content(Updater.latestVersion.toString().tinted(Var.Hologram))) + if (Updater.isCurrentBreakUpdate) + addCenterText(entity["break-update-warning"]).color(R.C.RedAlert) + if (Updater.hasUpdateDescription) + addBoxedText(Updater.UpdateDescription) + cont.table { + addCloseButton(entity["update"], it) { + WelcomeActions.UpdateCyberIO(entity) + }.size(150f, 50f) + addCloseButton(entity["no"], it) { + }.size(150f, 50f) + addCloseButton(entity["skip-this"], it) { + WelcomeActions.SkipThisUpdate(entity) + }.size(150f, 50f) + }.growX() + .row() + } + } +} \ No newline at end of file diff --git a/main/src/net/liplum/welcome/Welcomes.kt b/main/src/net/liplum/welcome/Welcomes.kt index 28f0f910..336cd8a6 100644 --- a/main/src/net/liplum/welcome/Welcomes.kt +++ b/main/src/net/liplum/welcome/Welcomes.kt @@ -1,38 +1,34 @@ package net.liplum.welcome +import net.liplum.Settings + object Welcomes { val default = WelcomeScene( id = "Default", - templateID = "Story", + template = WelcomeTemplates.Story(), ) val employmentVerification = WelcomeScene( id = "EmploymentVerification", - templateID = "SpecialDishes", + condition = WelcomeConditions.SpecialDishes, ) val discord = WelcomeScene( id = "Discord", - templateID = "DoAction", - data = mapOf( - "YesAction" to "OpenLink", - "Link" to "@link", + template = WelcomeTemplates.DoAction( + yesAction = WelcomeActions.OpenLink("@link"), ), iconPath = "discord", chance = 750, ) val updateECHO = WelcomeScene( id = "UpdateECHO", - templateID = "Update", - data = mapOf( - "ActionA" to "UpdateCyberIO", - "ActionC" to "@SkipThisUpdate", - ), + template = WelcomeTemplates.UpdateCyberIO, iconPath = "update-icon", - conditionID = "CheckUpdate", + condition = WelcomeConditions.CheckUpdate, ) val researchProject = WelcomeScene( id = "ResearchProject", iconPath = "welcome-holo-project", - conditionID = "SpecialDishes", + condition = WelcomeConditions.SpecialDishes, ) val theShip = WelcomeScene( id = "TheSHIP", @@ -46,70 +42,64 @@ object Welcomes { ) val adBlock = WelcomeScene( id = "AdBlock", - templateID = "DoAction", - iconPath = "ad-block", - data = mapOf( - "NoAction" to "StopReceiveWelcome", + template = WelcomeTemplates.DoAction( + noAction = WelcomeActions.StopReceiveWelcome, ), + iconPath = "ad-block", chance = 300, ) val `404NotFound` = WelcomeScene( id = "404NotFound", - templateID = "PlainText", - iconPath = "ad-block", - conditionID = "SettingsReq", - data = mapOf( - "FontSize" to 1.2, - "ShowPoliteWelcome" to false, - "CExpression" to "@ClickWelcomeTimes > 5 && @ShouldShowWelcome", + template = WelcomeTemplates.PlainText( + fontSize = 1.2f, + showPoliteWelcome = false, ), + condition = WelcomeConditions.Expr { + Settings.ClickWelcomeTimes > 5 && Settings.ShouldShowWelcome + }, chance = 200, ) val ohNo = WelcomeScene( id = "OhNo", iconPath = "@error", - data = mapOf( - "ShowPoliteWelcome" to false, + template = WelcomeTemplates.Story( + showPoliteWelcome = false, ), chance = 200, ) val rateUs = WelcomeScene( id = "RateUs", - templateID = "RateStar", - iconPath = "@error", - data = mapOf( - "StarNumber" to 5, - "InactiveStarIconPath" to "star-inactive", - "ActiveStarIconPath" to "star", - "StarSize" to 60.0, + template = WelcomeTemplates.RateStar( + starSize = 60f, + starNumber = 5, + activeStarIconPath = "star", + inactiveStarIconPath = "star-inactive", ), + iconPath = "@error", chance = 200, ) val erekirDetected = WelcomeScene( id = "ErekirDetected", iconPath = "spec-erekir", - conditionID = "SpecialDishes", + condition = WelcomeConditions.SpecialDishes, ) val setOutErekir = WelcomeScene( id = "SetOutErekir", - templateID = "DoAction", - conditionID = "SettingsReq", + condition = WelcomeConditions.Expr { + Settings.ContentSpecific == "vanilla" && Settings.ShouldShowWelcome + }, iconPath = "spec-erekir", - data = mapOf( - "ShowPoliteWelcome" to true, - "CExpression" to "@ContentSpecific == vanilla && @ShouldShowWelcome", - "YesAction" to "Navigation", - "Locator" to "/CyberIO/ContentSpecific", + template = WelcomeTemplates.DoAction( + yesAction = WelcomeActions.Navigation("/CyberIO/ContentSpecific"), ), ) val cyberionForErekir = WelcomeScene( id = "CyberionForErekir", - conditionID = "SettingsReq", iconPath = "cyberion-for-erekir", - data = mapOf( - "ShowPoliteWelcome" to true, - "CExpression" to "@ContentSpecific == erekir && @ShouldShowWelcome", - ), + template = WelcomeTemplates.Story(), + condition = WelcomeConditions.Expr { + Settings.ContentSpecific == "erekir" && Settings.ShouldShowWelcome + }, ) val tips = listOf( default, From ecf0a2c6c7c1a12a3c23605d8e9eaeebb19536f3 Mon Sep 17 00:00:00 2001 From: Liplum Date: Thu, 7 Dec 2023 16:20:37 +0800 Subject: [PATCH 6/6] fixed welcome layout issues --- assets/welcomes/en.properties | 2 +- assets/welcomes/ja.properties | 76 +++++------ assets/welcomes/ru.properties | 96 ++++++------- assets/welcomes/uk_UA.properties | 96 ++++++------- assets/welcomes/zh_CN.properties | 126 +++++++++--------- main/src/net/liplum/ui/CioUI.kt | 6 +- main/src/net/liplum/welcome/WelcomeScene.kt | 8 +- .../net/liplum/welcome/WelcomeScenePacks.kt | 36 ++--- .../welcome/{Welcomes.kt => WelcomeScenes.kt} | 29 ++-- .../net/liplum/welcome/WelcomeTemplates.kt | 22 +-- 10 files changed, 252 insertions(+), 245 deletions(-) rename main/src/net/liplum/welcome/{Welcomes.kt => WelcomeScenes.kt} (79%) diff --git a/assets/welcomes/en.properties b/assets/welcomes/en.properties index 03080c88..984c29cf 100644 --- a/assets/welcomes/en.properties +++ b/assets/welcomes/en.properties @@ -8,7 +8,7 @@ Default.read=I see welcome=Welcome to play Cyber IO {0}. Discord.title=Discord Discord=Sometimes, roaming in the space alone, you may want to seek a community \n\ - to share your work or just have a problem (of course, NO BUG).\n\ + to share your work or just have a problem.\n\ Alright, despite bad ECHO signal, our company is waiting for you, Plum Star on Discord.\n\ Now, join us to secure reputation or report anything you want. Discord.link=https://discord.gg/PDwyxM3waw diff --git a/assets/welcomes/ja.properties b/assets/welcomes/ja.properties index 670505bb..20eb5e29 100644 --- a/assets/welcomes/ja.properties +++ b/assets/welcomes/ja.properties @@ -7,51 +7,51 @@ Default.read=I see # Standard welcome=Welcome to play Cyber IO {0}. Discord.title=Discord -Discord=\u6642\u3005\u3001\u4E00\u4EBA\u3067\u30B9\u30DA\u30FC\u30B9\u3092\u6B69\u304D\u56DE\u3063\u3066\u3001\u8CB4\u65B9\u306F\u30B3\u30DF\u30E5\u30CB\u30C6\u30A3\u3092\u63A2\u3057\u305F\u3044\u304B\u3082\u3057\u308C\u307E\u305B\u3093\u3002\n\ - \u8CB4\u65B9\u306E\u4ED5\u4E8B\u3092\u5171\u6709\u3057\u305F\u308A\u3001\u554F\u984C\u3092\u62B1\u3048\u305F\u308A\u3059\u308B\u70BA\u306B\uFF08\u3082\u3061\u308D\u3093\u3001\u30D0\u30B0\u306F\u6709\u308A\u307E\u305B\u3093\uFF09\u3002\n\ - \u3055\u3066\u3001\u60AA\u3044\uFF25\uFF23\uFF28\uFF2F\u4FE1\u53F7\u306B\u3082\u304B\u304B\u308F\u3089\u305A\u3001\u8CB4\u65B9\u3092\u5F85\u3063\u3066\u3044\u308B\u60D1\u661F\u300ADiscord\u300B\u306E\u300APlumStar\u300B\u304C\u6709\u308A\u307E\u3059\u3002\n\ - \u4ECA\u3001\u79C1\u305F\u3061\u306B\u53C2\u52A0\u3057\u3066\u8A55\u5224\u3092\u78BA\u4FDD\u3057\u305F\u308A\u3001\u8CB4\u65B9\u304C\u671B\u3080\u3082\u306E\u3092\u5831\u544A\u3057\u3066\u304F\u3060\u3055\u3044\u3002 +Discord=時々、一人でスペースを歩き回って、貴方はコミュニティを探したいかもしれません。\n\ + 貴方の仕事を共有したり、問題を抱えたりする為に。\n\ + さて、悪いECHO信号にもかかわらず、貴方を待っている惑星《Discord》の《PlumStar》が有ります。\n\ + 今、私たちに参加して評判を確保したり、貴方が望むものを報告してください。 Discord.link=https://discord.gg/PDwyxM3waw -Discord.yes=[accent]\u30EA\u30F3\u30AF\u3092\u958B\u304F[] -Discord.no=\u30B8\u30E3\u30F3\u30AF\u3068\u3057\u3066\u30DE\u30FC\u30AF -UpdateECHO.title=\uFF25\uFF23\uFF28\uFF2F\u3092\u66F4\u65B0\u3059\u308B -UpdateECHO=News: \u6700\u8FD1\u3001\uFF25\uFF23\uFF28\uFF2F\u306F\u65B0\u3057\u3044\u30D0\u30FC\u30B8\u30E7\u30F3\u3092\u516C\u958B\u3057\u307E\u3057\u305F {0}\u3002\n\ - \u4E0B\u306E\u30DC\u30BF\u30F3\u3092\u30AF\u30EA\u30C3\u30AF\u3057\u3066\u3001\uFF25\uFF23\uFF28\uFF2F\u7AEF\u672B\u3092\u66F4\u65B0\u3067\u304D\u307E\u3059\u3002 -UpdateECHO.update=\u66F4\u65B0\u3059\u308B -UpdateECHO.no=\u4ECA\u306F\u3084\u3081\u308D -UpdateECHO.skip-this=\u8868\u793A\u3057\u306A\u3044 +Discord.yes=[accent]リンクを開く[] +Discord.no=ジャンクとしてマーク +UpdateECHO.title=ECHOを更新する +UpdateECHO=News: 最近、ECHOは新しいバージョンを公開しました {0}。\n\ + 下のボタンをクリックして、ECHO端末を更新できます。 +UpdateECHO.update=更新する +UpdateECHO.no=今はやめろ +UpdateECHO.skip-this=表示しない #v2 -EmploymentVerification.title=\u96C7\u7528\u78BA\u8A8D -EmploymentVerification=\u300APlum Star Inc.\u300B\u306B\u3088\u3046\u3053\u305D\u3002\u6B64\u306E\u65B0\u3057\u3044\u30D0\u30FC\u30B8\u30E7\u30F3\u306E\u5B8C\u5168\u306A\u30B5\u30A4\u30D0\u30CD\u30C6\u30A3\u30C3\u30AF\u30B9\u3092\u304A\u697D\u3057\u307F\u304F\u3060\u3055\u3044\uFF01\n\ - \u7136\u3057\u3001\u662F\u7B49\u306E\u30C7\u30D0\u30A4\u30B9\u3092\u63A5\u7D9A\u3059\u308B\u9762\u5012\u306A\u4F5C\u696D\u306B\u3064\u3044\u3066\u5FC3\u914D\u3059\u308B\u5FC5\u8981\u304C\u6709\u308B\u304B\u3082\u3057\u308C\u307E\u305B\u3093\u3002\n\ - \u3068\u306B\u304B\u304F\u3001\u9811\u5F35\u3063\u3066\u304F\u3060\u3055\u3044\uFF01 -EmploymentVerification.read=\u52A0\u5165 +EmploymentVerification.title=雇用確認 +EmploymentVerification=《Plum Star Inc.》にようこそ。此の新しいバージョンの完全なサイバネティックスをお楽しみください!\n\ + 然し、是等のデバイスを接続する面倒な作業について心配する必要が有るかもしれません。\n\ + とにかく、頑張ってください! +EmploymentVerification.read=加入 #v3 -ResearchProject.title=\u7814\u7A76\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8 -ResearchProject=\u304A\u65E9\u3046\u3054\u3056\u3044\u307E\u3059\u3001\u65B0\u53C2\u8005\uFF01 \u8CB4\u65B9\u306E\u7ACB\u5834\u306E\u5143\u5F93\u696D\u54E1\u304C\u8F9E\u3081\u305F\u306E\u3067\uFF08\u3046\u30FC\u3093...\u7269\u7406\u7684\u306B\uFF09\u3001\n\ - \u30DB\u30ED\u30B0\u30E9\u30E0\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\uFF08Holo-proj\uFF09\u306F\u9577\u3044\u9593\u4E2D\u65AD\u3055\u308C\u3066\u3044\u307E\u3059\u3002\n\ - \u7136\u3057\u5E78\u3044\u306A\u3053\u3068\u306B\u3001\u6B64\u306E\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u306F\u4ECA\u3001\u79C1\u305F\u3061\u306E\u6551\u3044\u4E3B\u3067\u6709\u308B\u8CB4\u65B9\u306B\u5F15\u304D\u6E21\u3055\u308C\u3066\u3044\u307E\u3059\u3002 \u3055\u3042\u3001\u4ED5\u4E8B\u306B\u623B\u308A\u307E\u3057\u3087\u3046\uFF01 -ResearchProject.read=\u4ED5\u4E8B\u306B\u884C\u304F -TheSHIP.title=\u8239 -TheSHIP=\u8CB4\u65B9\u304C\u4E00\u4EBA\u3067\u7A7A\u9593\u306B\u6D6E\u304B\u3093\u3067\u3044\u305F\u3068\u3044\u3046\u30A4\u30E1\u30FC\u30B8\u3001\u6700\u3082\u91CD\u8981\u306A\u4E8B\u306F\u4F55\u3067\u3059\u304B\uFF1F\u306F\u3044\u3001\u3082\u3061\u308D\u3093\u3001\u5B87\u5B99\u8239\u3002\n\ - \u6700\u826F\u304B\u3064\u8CE2\u660E\u306A\u9078\u629E\u306F\u3001\u5236\u5FA1\u3055\u308C\u305F\u6838\u878D\u5408\u3092\u52D5\u529B\u6E90\u3068\u3057\u3001\u6700\u65B0\u306E\u30A6\u30ED\u30DC\u30ED\u30B9\uFF2F\uFF33\uFF08\u5B89\u5B9A\u6027\u304C\u4FDD\u8A3C\u3055\u308C\u3066\u3044\u308B\uFF09\u3092\u4F7F\u7528\u3059\u308BPlumStarInc.\u306B\u3088\u3063\u3066\u88FD\u9020\u3055\u308C\u305F\uFF33\uFF28\uFF29\uFF2F\uFF30\u3067\u3059\u3002\n\\uFFE3\uFFFD\uFFFD\u3059\u3002\n\ +ResearchProject.title=研究プロジェクト +ResearchProject=お早うございます、新参者! 貴方の立場の元従業員が辞めたので(うーん...物理的に)、\n\ + ホログラムプロジェクト(Holo-proj)は長い間中断されています。\n\ + 然し幸いなことに、此のプロジェクトは今、私たちの救い主で有る貴方に引き渡されています。 さあ、仕事に戻りましょう! +ResearchProject.read=仕事に行く +TheSHIP.title=船 +TheSHIP=貴方が一人で空間に浮かんでいたというイメージ、最も重要な事は何ですか?はい、もちろん、宇宙船。\n\ + 最良かつ賢明な選択は、制御された核融合を動力源とし、最新のウロボロスOS(安定性が保証されている)を使用するPlumStarInc.によって製造されたSHIOPです。\n\ ̄��す。\n\ Commodity code: 111_1111_11_1001\n\ - PS: \uFF25\uFF23\uFF28\uFF2F\u306E\u76F8\u8AC7\u3092\u53D7\u3051\u4ED8\u3051\u307E\u3057\u305F\u3002 -TheSHIP.read=\u30B8\u30E3\u30F3\u30AF\u3068\u3057\u3066\u30DE\u30FC\u30AF -ECHO.title=\uFF25\uFF23\uFF28\uFF2F -ECHO=\u60D1\u661F\u4E0A\u306E\u69D8\u3005\u306A\u751F\u304D\u7269\u3084\u8A00\u8A9E\u9593\u306E\u30B3\u30DF\u30E5\u30CB\u30B1\u30FC\u30B7\u30E7\u30F3\u306E\u969C\u58C1\u306B\u5BFE\u51E6\u3059\u308B\u70BA\u306B\u3001ECHO\u304C\u958B\u767A\u3055\u308C\u307E\u3057\u305F\u3002\n\ - \u5176\u308C\u306F\u3001\u30EF\u30F3\u30AF\u30EA\u30C3\u30AF\u3067\u8A71\u3057\u3001\u304A\u4E92\u3044\u306B\u5BFE\u8A71\u3059\u308B\u70BA\u306E\u7C21\u5358\u306A\u65B9\u6CD5\u3092\u63D0\u4F9B\u3057\u307E\u3057\u305F\u3002\n\ - \u3055\u3089\u306B\u3001\uFF25\uFF23\uFF28\uFF2F\u306F\uFF25\uFF23\uFF28\uFF2F\u7AEF\u672B\u306B Cookie \u3092\u4FDD\u5B58\u3057\u3066\u3001\u30B3\u30DF\u30E5\u30CB\u30B1\u30FC\u30B7\u30E7\u30F3\u306E\u30A8\u30AF\u30B9\u30DA\u30EA\u30A8\u30F3\u30B9\u3092\u5411\u4E0A\u3055\u305B\u307E\u3059\u3002\n\ - \uFF25\uFF23\uFF28\uFF2F\u7AEF\u672B\u3067\u306E Cookie \u306E\u4F7F\u7528\u306B\u95A2\u3059\u308B\u8A73\u7D30\u60C5\u5831\u306F\u3001[#e53935]*404 Not Found*[] \u3067\u5165\u624B\u51FA\u6765\u307E\u3059\u3002 -ECHO.read=\u627F\u8A8D -NewBrains.title=\u65B0\u3057\u3044\u982D\u8133 -NewBrains=\u30D0\u30A4\u30AA\u30C6\u30AF\u30CE\u30ED\u30B8\u30FC\u3001\u533B\u5B66\u3001\u795E\u7D4C\u5B66\u306A\u3069\u3092\u30EA\u30FC\u30C9\u3059\u308B New Brains Corp. \u306F\u3001\u4E16\u754C\u6700\u5927\u306E\u4F01\u696D\u306E\uFF11\u3064\u3067\u3059\u3002\n\ - \u5E38\u306B\u3001\u5176\u4E4B\u540D\u306E\u3068\u304A\u308A\u3001\u5F7C\u3089\u306F\u8133\u79D1\u5B66\u306E\u6700\u524D\u7DDA\u306B\u3044\u307E\u3059\u3002\n\u307B\u3068\u3093\u3069\u306E\u4EBA\u306F\u307E\u3060\u6C17\u3065\u3044\u3066\u3044\u307E\u305B\u3093\u304C\u3001\u5176\u308C\u306F\u5F7C\u3089\u306E\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u306E\u4E00\u90E8\u3067\u3082\u6709\u308A\u307E\u3059\u3002 -NewBrains.read=\u65E2\u8AAD\u306B\u3059\u308B + PS: ECHOの相談を受け付けました。 +TheSHIP.read=ジャンクとしてマーク +ECHO.title=ECHO +ECHO=惑星上の様々な生き物や言語間のコミュニケーションの障壁に対処する為に、ECHOが開発されました。\n\ + 其れは、ワンクリックで話し、お互いに対話する為の簡単な方法を提供しました。\n\ + さらに、ECHOはECHO端末に Cookie を保存して、コミュニケーションのエクスペリエンスを向上させます。\n\ + ECHO端末での Cookie の使用に関する詳細情報は、[#e53935]*404 Not Found*[] で入手出来ます。 +ECHO.read=承認 +NewBrains.title=新しい頭脳 +NewBrains=バイオテクノロジー、医学、神経学などをリードする New Brains Corp. は、世界最大の企業の1つです。\n\ + 常に、其之名のとおり、彼らは脳科学の最前線にいます。\nほとんどの人はまだ気づいていませんが、其れは彼らのプロジェクトの一部でも有ります。 +NewBrains.read=既読にする AdBlock.title=Block Ad AdBlock=Do you feel the popup advertisement is annoying?\n\ Let's install the AdBlock, which can provide a completely clear environment for you!\n\ P.S.: If you want to bring ad back, please check the game settings at:\n\ - Settings >> Cyber IO >> \u300APlum Star Inc.\u300B\u304B\u3089\u306E\u30E1\u30C3\u30BB\u30FC\u30B8\u3092\u53D7\u4FE1\u3057\u307E\u3059\u3002 + Settings >> Cyber IO >> 《Plum Star Inc.》からのメッセージを受信します。 AdBlock.yes=Not Now AdBlock.no=Install \ No newline at end of file diff --git a/assets/welcomes/ru.properties b/assets/welcomes/ru.properties index cb6cf0fd..3898d1d5 100644 --- a/assets/welcomes/ru.properties +++ b/assets/welcomes/ru.properties @@ -5,56 +5,56 @@ Default=If you saw this page, it might mean you are using the CyberIO for test o Default.read=I see #---Do not translate--- # Standard -welcome=\u0414\u043E\u0431\u0440\u043E \u043F\u043E\u0436\u0430\u043B\u043E\u0432\u0430\u0442\u044C \u0432 \u0438\u0433\u0440\u0443 Cyber IO {0}. +welcome=Добро пожаловать в игру Cyber IO {0}. Discord.title=Discord -Discord=\u0418\u043D\u043E\u0433\u0434\u0430, \u0431\u043B\u0443\u0436\u0434\u0430\u044F \u043F\u043E \u043A\u043E\u0441\u043C\u043E\u0441\u0443 \u0432 \u043E\u0434\u0438\u043D\u043E\u0447\u0435\u0441\u0442\u0432\u0435, \u0432\u044B \u043C\u043E\u0436\u0435\u0442\u0435 \u0437\u0430\u0445\u043E\u0442\u0435\u0442\u044C \u043D\u0430\u0439\u0442\u0438 \u0441\u043E\u043E\u0431\u0449\u0435\u0441\u0442\u0432\u043E \n\ - \u0447\u0442\u043E\u0431\u044B \u043F\u043E\u0434\u0435\u043B\u0438\u0442\u044C\u0441\u044F \u0441\u0432\u043E\u0435\u0439 \u0440\u0430\u0431\u043E\u0442\u043E\u0439 \u0438\u043B\u0438 \u043F\u0440\u043E\u0441\u0442\u043E \u0438\u043C\u0435\u0442\u044C \u043F\u0440\u043E\u0431\u043B\u0435\u043C\u0443 (\u043A\u043E\u043D\u0435\u0447\u043D\u043E, \u0411\u0415\u0417 \u041E\u0428\u0418\u0411\u041A\u0418).\n\ - \u0425\u043E\u0440\u043E\u0448\u043E, \u043D\u0435\u0441\u043C\u043E\u0442\u0440\u044F \u043D\u0430 \u043F\u043B\u043E\u0445\u043E\u0439 \u0441\u0438\u0433\u043D\u0430\u043B ECHO, \u043D\u0430\u0448\u0430 \u043A\u043E\u043C\u043F\u0430\u043D\u0438\u044F \u0436\u0434\u0435\u0442 \u0442\u0435\u0431\u044F, Plum Star \u0432 Discord.\n\ - \u0422\u0435\u043F\u0435\u0440\u044C \u043F\u0440\u0438\u0441\u043E\u0435\u0434\u0438\u043D\u044F\u0439\u0442\u0435\u0441\u044C \u043A \u043D\u0430\u043C, \u0447\u0442\u043E\u0431\u044B \u0437\u0430\u0449\u0438\u0442\u0438\u0442\u044C \u0440\u0435\u043F\u0443\u0442\u0430\u0446\u0438\u044E \u0438\u043B\u0438 \u0441\u043E\u043E\u0431\u0449\u0438\u0442\u044C \u043E \u0447\u0435\u043C \u0443\u0433\u043E\u0434\u043D\u043E. +Discord=Иногда, блуждая по космосу в одиночестве, вы можете захотеть найти сообщество \n\ + чтобы поделиться своей работой или просто иметь проблему.\n\ + Хорошо, несмотря на плохой сигнал ECHO, наша компания ждет тебя, Plum Star в Discord.\n\ + Теперь присоединяйтесь к нам, чтобы защитить репутацию или сообщить о чем угодно. Discord.link=https://discord.gg/PDwyxM3waw -Discord.yes=[accent]\u041E\u0442\u043A\u0440\u044B\u0442\u044C \u0441\u0441\u044B\u043B\u043A\u0443[] -Discord.no=\u041E\u0442\u043C\u0435\u0442\u0438\u0442\u044C \u043A\u0430\u043A \u043D\u0435\u0436\u0435\u043B\u0430\u0442\u0435\u043B\u044C\u043D\u043E\u0435 -UpdateECHO.title=\u041E\u0431\u043D\u043E\u0432\u0438\u0442\u044C \u042D\u0425\u041E -UpdateECHO=\u041D\u043E\u0432\u043E\u0441\u0442\u0438: \u041D\u0435\u0434\u0430\u0432\u043D\u043E ECHO \u043E\u043F\u0443\u0431\u043B\u0438\u043A\u043E\u0432\u0430\u043B\u043E \u043D\u043E\u0432\u0443\u044E \u0432\u0435\u0440\u0441\u0438\u044E {0}.\n\ - \u0412\u044B \u043C\u043E\u0436\u0435\u0442\u0435 \u043D\u0430\u0436\u0430\u0442\u044C \u043A\u043D\u043E\u043F\u043A\u0443 \u043D\u0438\u0436\u0435, \u0447\u0442\u043E\u0431\u044B \u043E\u0431\u043D\u043E\u0432\u0438\u0442\u044C \u0441\u0432\u043E\u0439 \u0442\u0435\u0440\u043C\u0438\u043D\u0430\u043B ECHO. -UpdateECHO.update=\u041E\u0431\u043D\u043E\u0432\u043B\u044F\u0442\u044C -UpdateECHO.no=\u041D\u0435 \u0441\u0435\u0439\u0447\u0430\u0441 -UpdateECHO.skip-this=\u0411\u043E\u043B\u044C\u0448\u0435 \u043D\u0435 \u043F\u043E\u043A\u0430\u0437\u044B\u0432\u0430\u0442\u044C +Discord.yes=[accent]Открыть ссылку[] +Discord.no=Отметить как нежелательное +UpdateECHO.title=Обновить ЭХО +UpdateECHO=Новости: Недавно ECHO опубликовало новую версию {0}.\n\ + Вы можете нажать кнопку ниже, чтобы обновить свой терминал ECHO. +UpdateECHO.update=Обновлять +UpdateECHO.no=Не сейчас +UpdateECHO.skip-this=Больше не показывать #v2 -EmploymentVerification.title=\u041F\u0440\u043E\u0432\u0435\u0440\u043A\u0430 \u0437\u0430\u043D\u044F\u0442\u043E\u0441\u0442\u0438 -EmploymentVerification=\u041F\u0440\u0438\u0441\u043E\u0435\u0434\u0438\u043D\u044F\u0439\u0442\u0435\u0441\u044C \u043A \u043D\u0430\u043C, Plum Star Inc., \u043D\u0430\u0441\u043B\u0430\u0436\u0434\u0430\u0439\u0442\u0435\u0441\u044C \u044D\u0442\u043E\u0439 \u043D\u043E\u0432\u043E\u0439 \u0432\u0435\u0440\u0441\u0438\u0435\u0439 \u043F\u043E\u043B\u043D\u043E\u0439 \u043A\u0438\u0431\u0435\u0440\u043D\u0435\u0442\u0438\u043A\u0438!\n\ - \u041D\u043E \u0432\u0430\u043C, \u0432\u043E\u0437\u043C\u043E\u0436\u043D\u043E, \u043F\u0440\u0438\u0434\u0435\u0442\u0441\u044F \u0431\u0435\u0441\u043F\u043E\u043A\u043E\u0438\u0442\u044C\u0441\u044F \u043E\u0431 \u0443\u0442\u043E\u043C\u0438\u0442\u0435\u043B\u044C\u043D\u043E\u0439 \u0440\u0430\u0431\u043E\u0442\u0435 \u043F\u043E \u043F\u043E\u0434\u043A\u043B\u044E\u0447\u0435\u043D\u0438\u044E \u044D\u0442\u0438\u0445 \u0443\u0441\u0442\u0440\u043E\u0439\u0441\u0442\u0432.\n\ - \u0412 \u043B\u044E\u0431\u043E\u043C \u0441\u043B\u0443\u0447\u0430\u0435, \u0443\u0434\u0430\u0447\u0438! -EmploymentVerification.read=\u041F\u0440\u0438\u0441\u043E\u0435\u0434\u0438\u043D\u0438\u0442\u044C\u0441\u044F +EmploymentVerification.title=Проверка занятости +EmploymentVerification=Присоединяйтесь к нам, Plum Star Inc., наслаждайтесь этой новой версией полной кибернетики!\n\ + Но вам, возможно, придется беспокоиться об утомительной работе по подключению этих устройств.\n\ + В любом случае, удачи! +EmploymentVerification.read=Присоединиться #v3 -ResearchProject.title=\u0418\u0441\u0441\u043B\u0435\u0434\u043E\u0432\u0430\u0442\u0435\u043B\u044C\u0441\u043A\u0438\u0439 \u043F\u0440\u043E\u0435\u043A\u0442 -ResearchProject=\u0414\u043E\u0431\u0440\u043E\u0435 \u0443\u0442\u0440\u043E, \u043D\u043E\u0432\u0438\u0447\u043E\u043A! \u041F\u043E\u0441\u043A\u043E\u043B\u044C\u043A\u0443 \u0431\u044B\u0432\u0448\u0438\u0439 \u0441\u043E\u0442\u0440\u0443\u0434\u043D\u0438\u043A \u043D\u0430 \u0432\u0430\u0448\u0435\u0439 \u0434\u043E\u043B\u0436\u043D\u043E\u0441\u0442\u0438 \u0431\u044B\u043B \u0443\u0432\u043E\u043B\u0435\u043D (\u043C\u043C\u043C... \u0444\u0438\u0437\u0438\u0447\u0435\u0441\u043A\u0438),\n\ - \u041F\u0440\u043E\u0435\u043A\u0442 \u0413\u043E\u043B\u043E\u0433\u0440\u0430\u043C\u043C\u0430 (\u0425\u043E\u043B\u043E-\u041F\u0440\u043E\u0434\u0436) \u0434\u0430\u0432\u043D\u043E \u043F\u0440\u0438\u043E\u0441\u0442\u0430\u043D\u043E\u0432\u043B\u0435\u043D.\n\ - \u041D\u043E, \u043A \u0441\u0447\u0430\u0441\u0442\u044C\u044E, \u044D\u0442\u043E\u0442 \u043F\u0440\u043E\u0435\u043A\u0442 \u0442\u0435\u043F\u0435\u0440\u044C \u043F\u0435\u0440\u0435\u0434\u0430\u043D \u0432\u0430\u043C, \u043D\u0430\u0448\u0435\u043C\u0443 \u0441\u043F\u0430\u0441\u0438\u0442\u0435\u043B\u044E. \u0410 \u0442\u0435\u043F\u0435\u0440\u044C \u0432\u043E\u0437\u0432\u0440\u0430\u0449\u0430\u0439\u0441\u044F \u043A \u0440\u0430\u0431\u043E\u0442\u0435! -ResearchProject.read=\u0418\u0434\u0442\u0438 \u0440\u0430\u0431\u043E\u0442\u0430\u0442\u044C -TheSHIP.title=\u041A\u043E\u0440\u0430\u0431\u043B\u044C -TheSHIP=\u041F\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u044C\u0442\u0435, \u0447\u0442\u043E \u0432\u044B \u043F\u0430\u0440\u0438\u0442\u0435 \u0432 \u043A\u043E\u0441\u043C\u043E\u0441\u0435 \u0432 \u043E\u0434\u0438\u043D\u043E\u0447\u0435\u0441\u0442\u0432\u0435, \u0447\u0442\u043E \u0441\u0430\u043C\u043E\u0435 \u0433\u043B\u0430\u0432\u043D\u043E\u0435? \u0414\u0430, \u043A\u043E\u043D\u0435\u0447\u043D\u043E, \u043A\u043E\u0441\u043C\u0438\u0447\u0435\u0441\u043A\u0438\u0439 \u043A\u043E\u0440\u0430\u0431\u043B\u044C.\n\ - \u041B\u0443\u0447\u0448\u0438\u043C \u0438 \u043C\u0443\u0434\u0440\u044B\u043C \u0432\u044B\u0431\u043E\u0440\u043E\u043C \u044F\u0432\u043B\u044F\u0435\u0442\u0441\u044F \u041A\u041E\u0420\u0410\u0411\u041B\u042C \u043F\u0440\u043E\u0438\u0437\u0432\u043E\u0434\u0441\u0442\u0432\u0430 Plum Star Inc.,\n \u0440\u0430\u0431\u043E\u0442\u0430\u044E\u0449\u0438\u0439 \u043D\u0430 \u0443\u043F\u0440\u0430\u0432\u043B\u044F\u0435\u043C\u043E\u043C \u044F\u0434\u0435\u0440\u043D\u043E\u043C \u0441\u0438\u043D\u0442\u0435\u0437\u0435 \u0438 \u0438\u0441\u043F\u043E\u043B\u044C\u0437\u0443\u044E\u0449\u0438\u0439 \u043D\u043E\u0432\u0435\u0439\u0448\u0443\u044E \u041E\u0421 Ouroboros (\u0441\u0442\u0430\u0431\u0438\u043B\u044C\u043D\u043E\u0441\u0442\u044C \u0433\u0430\u0440\u0430\u043D\u0442\u0438\u0440\u043E\u0432\u0430\u043D\u0430).\n\ - \u041A\u043E\u0434 \u0442\u043E\u0432\u0430\u0440\u0430: 111_1111_11_1001\n\ - PS: \u041A\u043E\u043D\u0441\u0443\u043B\u044C\u0442\u0430\u0446\u0438\u044F \u042D\u0425\u041E \u043F\u0440\u0438\u043D\u044F\u0442\u0430. -TheSHIP.read=\u041E\u0442\u043C\u0435\u0442\u0438\u0442\u044C \u043A\u0430\u043A \u043D\u0435\u0436\u0435\u043B\u0430\u0442\u0435\u043B\u044C\u043D\u043E\u0435 -ECHO.title=\u042D\u0425\u041E -ECHO=\u0414\u043B\u044F \u043F\u0440\u0435\u043E\u0434\u043E\u043B\u0435\u043D\u0438\u044F \u043A\u043E\u043C\u043C\u0443\u043D\u0438\u043A\u0430\u0442\u0438\u0432\u043D\u044B\u0445 \u0431\u0430\u0440\u044C\u0435\u0440\u043E\u0432 \u043C\u0435\u0436\u0434\u0443 \u0440\u0430\u0437\u043B\u0438\u0447\u043D\u044B\u043C\u0438 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0430\u043C\u0438 \u0438 \u044F\u0437\u044B\u043A\u0430\u043C\u0438 \u043D\u0430 \u043F\u043B\u0430\u043D\u0435\u0442\u0430\u0445 \u0431\u044B\u043B\u043E \u0440\u0430\u0437\u0440\u0430\u0431\u043E\u0442\u0430\u043D\u043E ECHO.\n\ - \u042D\u0442\u043E \u043E\u0431\u0435\u0441\u043F\u0435\u0447\u0438\u043B\u043E \u043F\u0440\u043E\u0441\u0442\u043E\u0439 \u0441\u043F\u043E\u0441\u043E\u0431, \u043E\u0434\u0438\u043D \u0449\u0435\u043B\u0447\u043E\u043A, \u0447\u0442\u043E\u0431\u044B \u0433\u043E\u0432\u043E\u0440\u0438\u0442\u044C, \u0432\u0437\u0430\u0438\u043C\u043E\u0434\u0435\u0439\u0441\u0442\u0432\u043E\u0432\u0430\u0442\u044C \u0434\u0440\u0443\u0433 \u0441 \u0434\u0440\u0443\u0433\u043E\u043C.\n\ - \u041A\u0440\u043E\u043C\u0435 \u0442\u043E\u0433\u043E, ECHO \u0441\u043E\u0445\u0440\u0430\u043D\u044F\u0435\u0442 \u0444\u0430\u0439\u043B\u044B cookie \u043D\u0430 \u0442\u0435\u0440\u043C\u0438\u043D\u0430\u043B\u0430\u0445 ECHO, \u0447\u0442\u043E\u0431\u044B \u0441\u0434\u0435\u043B\u0430\u0442\u044C \u0432\u0430\u0448\u0435 \u043E\u0431\u0449\u0435\u043D\u0438\u0435 \u0431\u043E\u043B\u0435\u0435 \u0443\u0434\u043E\u0431\u043D\u044B\u043C.\n\ - \u041F\u043E\u0434\u0440\u043E\u0431\u043D\u0430\u044F \u0438\u043D\u0444\u043E\u0440\u043C\u0430\u0446\u0438\u044F \u043E\u0431 \u0438\u0441\u043F\u043E\u043B\u044C\u0437\u043E\u0432\u0430\u043D\u0438\u0438 \u0444\u0430\u0439\u043B\u043E\u0432 cookie \u043D\u0430 \u0432\u0430\u0448\u0435\u043C \u0442\u0435\u0440\u043C\u0438\u043D\u0430\u043B\u0435 ECHO \u0434\u043E\u0441\u0442\u0443\u043F\u043D\u0430 \u043F\u043E \u0441\u0441\u044B\u043B\u043A\u0435 [#e53935]*404 \u041D\u0435 \u041D\u0430\u0439\u0434\u0435\u043D\u043E*[]. -ECHO.read=\u041F\u0440\u0438\u043D\u0438\u043C\u0430\u0442\u044C +ResearchProject.title=Исследовательский проект +ResearchProject=Доброе утро, новичок! Поскольку бывший сотрудник на вашей должности был уволен (ммм... физически),\n\ + Проект Голограмма (Холо-Продж) давно приостановлен.\n\ + Но, к счастью, этот проект теперь передан вам, нашему спасителю. А теперь возвращайся к работе! +ResearchProject.read=Идти работать +TheSHIP.title=Корабль +TheSHIP=Представьте, что вы парите в космосе в одиночестве, что самое главное? Да, конечно, космический корабль.\n\ + Лучшим и мудрым выбором является КОРАБЛЬ производства Plum Star Inc.,\n работающий на управляемом ядерном синтезе и использующий новейшую ОС Ouroboros (стабильность гарантирована).\n\ + Код товара: 111_1111_11_1001\n\ + PS: Консультация ЭХО принята. +TheSHIP.read=Отметить как нежелательное +ECHO.title=ЭХО +ECHO=Для преодоления коммуникативных барьеров между различными существами и языками на планетах было разработано ECHO.\n\ + Это обеспечило простой способ, один щелчок, чтобы говорить, взаимодействовать друг с другом.\n\ + Кроме того, ECHO сохраняет файлы cookie на терминалах ECHO, чтобы сделать ваше общение более удобным.\n\ + Подробная информация об использовании файлов cookie на вашем терминале ECHO доступна по ссылке [#e53935]*404 Не Найдено*[]. +ECHO.read=Принимать NewBrains.title=New Brains -NewBrains=New Brains Corp., \u043A\u043E\u0442\u043E\u0440\u0430\u044F \u0432\u043E\u0437\u0433\u043B\u0430\u0432\u043B\u044F\u0435\u0442 \u0431\u0438\u043E\u0442\u0435\u0445\u043D\u043E\u043B\u043E\u0433\u0438\u0438, \u043C\u0435\u0434\u0438\u0446\u0438\u043D\u0443, \u043D\u0435\u0432\u0440\u043E\u043B\u043E\u0433\u0438\u044E \u0438 \u0442. \u0434., \u0432\u0445\u043E\u0434\u0438\u0442 \u0432 \u0447\u0438\u0441\u043B\u043E \u043A\u0440\u0443\u043F\u043D\u0435\u0439\u0448\u0438\u0445 \u043A\u043E\u043C\u043F\u0430\u043D\u0438\u0439 \u0432\u043E \u0432\u0441\u0435\u043C \u043C\u0438\u0440\u0435.\n\ - \u0412\u0441\u0435\u0433\u0434\u0430, \u043A\u0430\u043A \u044D\u0442\u043E \u043D\u0430\u0437\u044B\u0432\u0430\u0435\u0442\u0441\u044F, \u043E\u043D\u0438 \u043D\u0430\u0445\u043E\u0434\u044F\u0442\u0441\u044F \u0432 \u0430\u0432\u0430\u043D\u0433\u0430\u0440\u0434\u0435 \u043D\u0430\u0443\u043A\u0438 \u043E \u043C\u043E\u0437\u0433\u0435.\n\u0411\u043E\u043B\u044C\u0448\u0438\u043D\u0441\u0442\u0432\u043E \u0438\u0437 \u0432\u0430\u0441 \u0435\u0449\u0435 \u043D\u0435 \u0437\u0430\u043C\u0435\u0442\u0438\u043B\u0438 \u044D\u0442\u043E\u0433\u043E, \u043D\u043E \u044D\u0442\u043E \u0442\u0430\u043A\u0436\u0435 \u0447\u0430\u0441\u0442\u044C \u0438\u0445 \u043F\u0440\u043E\u0435\u043A\u0442\u043E\u0432. -NewBrains.read=\u041F\u043E\u043C\u0435\u0442\u0438\u0442\u044C, \u043A\u0430\u043A \u043F\u0440\u043E\u0447\u0438\u0442\u0430\u043D\u043D\u043E\u0435 -AdBlock.title=\u0411\u043B\u043E\u043A\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0440\u0435\u043A\u043B\u0430\u043C\u0443 -AdBlock=\u0412\u0430\u0441 \u0440\u0430\u0437\u0434\u0440\u0430\u0436\u0430\u0435\u0442 \u0432\u0441\u043F\u043B\u044B\u0432\u0430\u044E\u0449\u0430\u044F \u0440\u0435\u043A\u043B\u0430\u043C\u0430?\n\ - \u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u0443\u0441\u0442\u0430\u043D\u043E\u0432\u0438\u043C AdBlock, \u043A\u043E\u0442\u043E\u0440\u044B\u0439 \u043C\u043E\u0436\u0435\u0442 \u043F\u0440\u0435\u0434\u043E\u0441\u0442\u0430\u0432\u0438\u0442\u044C \u0432\u0430\u043C \u043F\u043E\u043B\u043D\u043E\u0441\u0442\u044C\u044E \u043F\u0440\u043E\u0437\u0440\u0430\u0447\u043D\u0443\u044E \u0441\u0440\u0435\u0434\u0443!\n\ - P.S.: \u0415\u0441\u043B\u0438 \u0432\u044B \u0445\u043E\u0442\u0438\u0442\u0435 \u0432\u0435\u0440\u043D\u0443\u0442\u044C \u0440\u0435\u043A\u043B\u0430\u043C\u0443, \u043F\u0440\u043E\u0432\u0435\u0440\u044C\u0442\u0435 \u043D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438 \u0438\u0433\u0440\u044B \u043F\u043E \u0430\u0434\u0440\u0435\u0441\u0443:\n\ - \u041D\u0430\u0441\u0442\u0440\u043E\u0439\u043A\u0438 >> Cyber IO >> \u041F\u043E\u043B\u0443\u0447\u0438\u0442\u044C \u0441\u043E\u043E\u0431\u0449\u0435\u043D\u0438\u0435 \u043E\u0442 Plum Star Inc. -AdBlock.yes=[accent]\u041D\u0435 \u0441\u0435\u0439\u0447\u0430\u0441[] -AdBlock.no=\u0423\u0441\u0442\u0430\u043D\u043E\u0432\u0438\u0442\u044C -404NotFound.title=[#e53935]404 \u041D\u0435 \u041D\u0430\u0439\u0434\u0435\u043D\u043E[] -404NotFound=[#e53935]404 \u041D\u0435 \u041D\u0430\u0439\u0434\u0435\u043D\u043E[] -404NotFound.read=Q\u041F\u043E\u043A\u0438\u0434\u0430\u0442\u044C +NewBrains=New Brains Corp., которая возглавляет биотехнологии, медицину, неврологию и т. д., входит в число крупнейших компаний во всем мире.\n\ + Всегда, как это называется, они находятся в авангарде науки о мозге.\nБольшинство из вас еще не заметили этого, но это также часть их проектов. +NewBrains.read=Пометить, как прочитанное +AdBlock.title=Блокировать рекламу +AdBlock=Вас раздражает всплывающая реклама?\n\ + Давайте установим AdBlock, который может предоставить вам полностью прозрачную среду!\n\ + P.S.: Если вы хотите вернуть рекламу, проверьте настройки игры по адресу:\n\ + Настройки >> Cyber IO >> Получить сообщение от Plum Star Inc. +AdBlock.yes=[accent]Не сейчас[] +AdBlock.no=Установить +404NotFound.title=[#e53935]404 Не Найдено[] +404NotFound=[#e53935]404 Не Найдено[] +404NotFound.read=QПокидать diff --git a/assets/welcomes/uk_UA.properties b/assets/welcomes/uk_UA.properties index 88dfecfa..8c7699fe 100644 --- a/assets/welcomes/uk_UA.properties +++ b/assets/welcomes/uk_UA.properties @@ -5,56 +5,56 @@ Default=If you saw this page, it might mean you are using the CyberIO for test o Default.read=I see #---Do not translate--- # Standard -welcome=\u041B\u0430\u0441\u043A\u0430\u0432\u043E \u043F\u0440\u043E\u0441\u0438\u043C\u043E \u0434\u043E Cyber IO {0}. +welcome=Ласкаво просимо до Cyber IO {0}. Discord.title=Discord -Discord=\u0406\u043D\u043E\u0434\u0456, \u0431\u043B\u0443\u043A\u0430\u044E\u0447\u0438 \u0432 \u043A\u043E\u0441\u043C\u043E\u0441\u0456 \u043D\u0430\u043E\u043E\u0434\u0438\u043D\u0446\u0456, \u0432\u0438 \u043C\u043E\u0436\u0435\u0442\u0435 \u0437\u0430\u0445\u043E\u0442\u0456\u0442\u0438 \u0437\u043D\u0430\u0439\u0442\u0438 \u044F\u043A\u0443\u0441\u044C \u0441\u043F\u0456\u043B\u044C\u043D\u043E\u0442\u0443, \n\ - \u043F\u043E\u0434\u0456\u043B\u0438\u0442\u0438\u0441\u044F \u0441\u0432\u043E\u0454\u044E \u0440\u043E\u0431\u043E\u0442\u043E\u044E \u0430\u0431\u043E \u043F\u0440\u043E\u0441\u0442\u043E \u0437\u0456\u0448\u0442\u043E\u0432\u0445\u043D\u0443\u0442\u0438\u0441\u044F \u0456\u0437 \u043F\u0440\u043E\u0431\u043B\u0435\u043C\u043E\u044E (\u0437\u0432\u0438\u0447\u0430\u0439\u043D\u043E, \u0449\u043E \u0425\u0418\u0411 \u041D\u0415 \u0406\u0421\u041D\u0423\u0404). \n\ - \u0413\u0430\u0440\u0430\u0437\u0434, \u043D\u0435\u0437\u0432\u0430\u0436\u0430\u044E\u0447\u0438 \u043D\u0430 \u043F\u043E\u0433\u0430\u043D\u0438\u0439 \u0441\u0438\u0433\u043D\u0430\u043B ECHO, \u043D\u0430\u0448\u0430 \u043A\u043E\u043C\u043F\u0430\u043D\u0456\u044F \u00AB\u041F\u043B\u044E\u043C \u0421\u0442\u0430\u0440 \u0406\u043D\u043A\u043E\u0440\u043F\u043E\u0440\u0435\u0439\u0448\u043D\u00BB \u0447\u0435\u043A\u0430\u0454 \u043D\u0430 \u0432\u0430\u0441 \u0443 Discord.\n\ - \u041F\u0440\u0438\u0454\u0434\u043D\u0443\u0439\u0442\u0435\u0441\u044C \u0434\u043E \u043D\u0430\u0441, \u0449\u043E\u0431 \u0443\u0431\u0435\u0437\u043F\u0435\u0447\u0438\u0442\u0438 \u0441\u0432\u043E\u044E \u0440\u0435\u043F\u0443\u0442\u0430\u0446\u0456\u044E \u0430\u0431\u043E \u043F\u043E\u0432\u0456\u0434\u043E\u043C\u0438\u0442\u0438 \u043F\u0440\u043E \u0432\u0441\u0435, \u0449\u043E \u0437\u0430\u0432\u0433\u043E\u0434\u043D\u043E. +Discord=Іноді, блукаючи в космосі наоодинці, ви можете захотіти знайти якусь спільноту, \n\ + поділитися своєю роботою або просто зіштовхнутися із проблемою. \n\ + Гаразд, незважаючи на поганий сигнал ECHO, наша компанія «Плюм Стар Інкорпорейшн» чекає на вас у Discord.\n\ + Приєднуйтесь до нас, щоб убезпечити свою репутацію або повідомити про все, що завгодно. Discord.link=https://discord.gg/PDwyxM3waw -Discord.yes=[accent]\u041F\u0435\u0440\u0435\u0439\u0442\u0438 \u0437\u0430 \u043F\u043E\u0441\u0438\u043B\u0430\u043D\u043D\u044F\u043C[] -Discord.no=\u0412\u0438\u0434\u0430\u043B\u0438\u0442\u0438 -UpdateECHO.title=\u041E\u043D\u043E\u0432\u0438\u0442\u0438 ECHO -UpdateECHO=\u041D\u043E\u0432\u0438\u043D\u0438: \u043D\u0435\u0449\u043E\u0434\u0430\u0432\u043D\u043E ECHO \u043E\u043F\u0443\u0431\u043B\u0456\u043A\u0443\u0432\u0430\u043B\u0438 \u043D\u043E\u0432\u0443 \u0432\u0435\u0440\u0441\u0456\u044E: {0}.\n\ - \u0412\u0438 \u043C\u043E\u0436\u0435\u0442\u0435 \u043D\u0430\u0442\u0438\u0441\u043D\u0443\u0442\u0438 \u043A\u043D\u043E\u043F\u043A\u0443 \u043D\u0438\u0436\u0447\u0435, \u0449\u043E\u0431 \u043E\u043D\u043E\u0432\u0438\u0442\u0438 \u0442\u0435\u0440\u043C\u0456\u043D\u0430\u043B ECHO. -UpdateECHO.update=\u041E\u043D\u043E\u0432\u0438\u0442\u0438 -UpdateECHO.no=\u041D\u0435 \u0437\u0430\u0440\u0430\u0437 -UpdateECHO.skip-this=\u041D\u0435 \u043F\u043E\u043A\u0430\u0437\u0443\u0432\u0430\u0442\u0438 +Discord.yes=[accent]Перейти за посиланням[] +Discord.no=Видалити +UpdateECHO.title=Оновити ECHO +UpdateECHO=Новини: нещодавно ECHO опублікували нову версію: {0}.\n\ + Ви можете натиснути кнопку нижче, щоб оновити термінал ECHO. +UpdateECHO.update=Оновити +UpdateECHO.no=Не зараз +UpdateECHO.skip-this=Не показувати #v2 -EmploymentVerification.title=\u041F\u0456\u0434\u0442\u0432\u0435\u0440\u0434\u0436\u0435\u043D\u043D\u044F \u043F\u0440\u0430\u0446\u0435\u0432\u043B\u0430\u0448\u0442\u0443\u0432\u0430\u043D\u043D\u044F -EmploymentVerification=\u041B\u0430\u0441\u043A\u0430\u0432\u043E \u043F\u0440\u043E\u0441\u0438\u043C\u043E \u0434\u043E \u043D\u0430\u0441, \u00AB\u041F\u043B\u044E\u043C \u0421\u0442\u0430\u0440 \u0406\u043D\u043A\u043E\u0440\u043F\u043E\u0440\u0435\u0439\u0448\u043D\u00BB, \u043D\u0430\u0441\u043E\u043B\u043E\u0434\u0436\u0443\u0439\u0442\u0435\u0441\u044C \u0446\u0456\u0454\u044E \u043D\u043E\u0432\u043E\u044E \u0432\u0435\u0440\u0441\u0456\u0454\u044E, \u0449\u043E \u0441\u043F\u043E\u0432\u043D\u0435\u043D\u0430 \u043A\u0443\u043F\u043E\u044E \u043A\u0456\u0431\u0435\u0440\u043D\u0435\u0442\u0438\u0447\u043D\u0438\u0445 \u0440\u0435\u0447\u0435\u0439!\n\ - \u041F\u0440\u043E\u0442\u0435, \u043C\u043E\u0436\u043B\u0438\u0432\u043E, \u0432\u0430\u043C \u0434\u043E\u0432\u0435\u0434\u0435\u0442\u044C\u0441\u044F \u0442\u0443\u0440\u0431\u0443\u0432\u0430\u0442\u0438\u0441\u044F \u043F\u0440\u043E \u0432\u0442\u043E\u043C\u043B\u0438\u0432\u0443 \u0440\u043E\u0431\u043E\u0442\u0443 \u0437 \u043F\u0456\u0434\u043A\u043B\u044E\u0447\u0435\u043D\u043D\u044F\u043C \u0446\u0438\u0445 \u043F\u0440\u0438\u0441\u0442\u0440\u043E\u0457\u0432.\n\ - \u0423\u0441\u0435 \u043E\u0434\u043D\u043E, \u0449\u0430\u0441\u0442\u0438! -EmploymentVerification.read=\u0414\u043E\u043B\u0443\u0447\u0438\u0442\u0438\u0441\u044F +EmploymentVerification.title=Підтвердження працевлаштування +EmploymentVerification=Ласкаво просимо до нас, «Плюм Стар Інкорпорейшн», насолоджуйтесь цією новою версією, що сповнена купою кібернетичних речей!\n\ + Проте, можливо, вам доведеться турбуватися про втомливу роботу з підключенням цих пристроїв.\n\ + Усе одно, щасти! +EmploymentVerification.read=Долучитися #v3 -ResearchProject.title=\u0414\u043E\u0441\u043B\u0456\u0434\u043D\u0438\u0446\u044C\u043A\u0438\u0439 \u043F\u0440\u043E\u0454\u043A\u0442 -ResearchProject=\u0414\u043E\u0431\u0440\u043E\u0433\u043E \u0440\u0430\u043D\u043A\u0443, \u043D\u043E\u0432\u0430\u0447\u043A\u0443! \u041E\u0441\u043A\u0456\u043B\u044C\u043A\u0438 \u043A\u043E\u043B\u0438\u0448\u043D\u044C\u043E\u0433\u043E \u0441\u043F\u0456\u0432\u0440\u043E\u0431\u0456\u0442\u043D\u0438\u043A\u0430 \u043D\u0430 \u0432\u0430\u0448\u0456\u0439 \u043F\u043E\u0441\u0430\u0434\u0456 \u0431\u0443\u043B\u043E \u0437\u0432\u0456\u043B\u044C\u043D\u0435\u043D\u043E (\u043D\u0443\u0443\u0443\u0443... \u0444\u0456\u0437\u0438\u0447\u043D\u043E),\n\ - \u043F\u0440\u043E\u0454\u043A\u0442 \u00AB\u0413\u043E\u043B\u043E\u0433\u0440\u0430\u043C\u0430\u00BB (Holo-proj) \u043D\u0430 \u0442\u0440\u0438\u0432\u0430\u043B\u0438\u0439 \u0447\u0430\u0441 \u043F\u0440\u0438\u0437\u0443\u043F\u0438\u043D\u0435\u043D\u043E.\n\ - \u0410\u043B\u0435, \u043D\u0430 \u0449\u0430\u0441\u0442\u044F, \u0446\u0435\u0439 \u043F\u0440\u043E\u0454\u043A\u0442 \u0442\u0435\u043F\u0435\u0440 \u043F\u0435\u0440\u0435\u0434\u0430\u043D\u0438\u0439 \u0432\u0430\u043C, \u043D\u0430\u0448 \u0440\u044F\u0442\u0456\u0432\u043D\u0438\u043A. \u041C\u0435\u0440\u0449\u0456\u0439 \u0434\u043E \u0440\u043E\u0431\u043E\u0442\u0438! -ResearchProject.read=\u0419\u0442\u0438 \u043F\u0440\u0430\u0446\u044E\u0432\u0430\u0442\u0438 -TheSHIP.title=\u041A\u043E\u0440\u0430\u0431\u0435\u043B\u044C -TheSHIP=\u0429\u043E \u0454 \u043D\u0430\u0439\u0433\u043E\u043B\u043E\u0432\u043D\u0456\u0448\u0438\u043C, \u043A\u043E\u043B\u0438 \u0432\u0438 \u043B\u0456\u0442\u0430\u0454\u0442\u0435 \u0432 \u043A\u043E\u0441\u043C\u043E\u0441\u0456 \u043D\u0430\u043E\u0434\u0438\u043D\u0446\u0456? \u0422\u0430\u043A, \u0437\u0432\u0438\u0447\u0430\u0439\u043D\u043E, \u0446\u0435 \u043A\u043E\u0441\u043C\u0456\u0447\u043D\u0438\u0439 \u043A\u043E\u0440\u0430\u0431\u0435\u043B\u044C.\n\ - \u041D\u0430\u0439\u043A\u0440\u0430\u0449\u0438\u043C \u0456 \u043D\u0430\u0439\u0440\u043E\u0437\u0441\u0443\u0434\u043B\u0438\u0432\u0456\u0448\u0438\u043C \u0432\u0438\u0431\u043E\u0440\u043E\u043C \u0454 \u043A\u043E\u0440\u0430\u0431\u0435\u043B\u044C, \u0432\u0438\u0440\u043E\u0431\u043B\u0435\u043D\u0438\u0439 \u00AB\u041F\u043B\u044E\u043C \u0421\u0442\u0430\u0440 \u0406\u043D\u043A\u00BB,\n \u043D\u0430 \u043E\u0441\u043D\u043E\u0432\u0456 \u043A\u0435\u0440\u043E\u0432\u0430\u043D\u043E\u0433\u043E \u044F\u0434\u0435\u0440\u043D\u043E\u0433\u043E \u0441\u0438\u043D\u0442\u0435\u0437\u0443, \u0442\u0430 \u044F\u043A\u0438\u0439 \u0432\u0438\u043A\u043E\u0440\u0438\u0441\u0442\u043E\u0432\u0443\u0454 \u043D\u0430\u0439\u043D\u043E\u0432\u0456\u0448\u0443 \u041E\u0421 Ouroboros (\u0441\u0442\u0430\u0431\u0456\u043B\u044C\u043D\u0456\u0441\u0442\u044C \u0433\u0430\u0440\u0430\u043D\u0442\u043E\u0432\u0430\u043D\u043E).\n\ - \u041A\u043E\u0434 \u0442\u043E\u0432\u0430\u0440\u0443: 111_1111_11_1001\n\ - PS: \u041A\u043E\u043D\u0441\u0443\u043B\u044C\u0442\u0430\u0446\u0456\u044E ECHO \u043F\u0440\u0438\u0439\u043D\u044F\u0442\u043E. -TheSHIP.read=\u0412\u0438\u0434\u0430\u043B\u0438\u0442\u0438 +ResearchProject.title=Дослідницький проєкт +ResearchProject=Доброго ранку, новачку! Оскільки колишнього співробітника на вашій посаді було звільнено (нуууу... фізично),\n\ + проєкт «Голограма» (Holo-proj) на тривалий час призупинено.\n\ + Але, на щастя, цей проєкт тепер переданий вам, наш рятівник. Мерщій до роботи! +ResearchProject.read=Йти працювати +TheSHIP.title=Корабель +TheSHIP=Що є найголовнішим, коли ви літаєте в космосі наодинці? Так, звичайно, це космічний корабель.\n\ + Найкращим і найрозсудливішим вибором є корабель, вироблений «Плюм Стар Інк»,\n на основі керованого ядерного синтезу, та який використовує найновішу ОС Ouroboros (стабільність гарантовано).\n\ + Код товару: 111_1111_11_1001\n\ + PS: Консультацію ECHO прийнято. +TheSHIP.read=Видалити ECHO.title=ECHO -ECHO=\u0429\u043E\u0431 \u043F\u043E\u0434\u043E\u043B\u0430\u0442\u0438 \u0431\u0430\u0440\u2019\u0454\u0440\u0438 \u0441\u043F\u0456\u043B\u043A\u0443\u0432\u0430\u043D\u043D\u044F \u043C\u0456\u0436 \u0440\u0456\u0437\u043D\u0438\u043C\u0438 \u0456\u0441\u0442\u043E\u0442\u0430\u043C\u0438 \u0442\u0430 \u043C\u043E\u0432\u0430\u043C\u0438 \u043D\u0430 \u043F\u043B\u0430\u043D\u0435\u0442\u0430\u0445, \u0431\u0443\u043B\u043E \u0440\u043E\u0437\u0440\u043E\u0431\u043B\u0435\u043D\u043E ECHO.\n\ - \u0426\u0435 \u0437\u0430\u0431\u0435\u0437\u043F\u0435\u0447\u0438\u043B\u043E \u043F\u0440\u043E\u0441\u0442\u0438\u0439 \u0441\u043F\u043E\u0441\u0456\u0431 \u0440\u043E\u0437\u043C\u043E\u0432\u043B\u044F\u0442\u0438, \u0432\u0437\u0430\u0454\u043C\u043E\u0434\u0456\u044F\u0442\u0438 \u043E\u0434\u0438\u043D \u0437 \u043E\u0434\u043D\u0438\u043C \u043E\u0434\u043D\u0438\u043C \u043A\u043B\u0430\u0446\u0430\u043D\u043D\u044F\u043C \u043C\u0438\u0448\u0456.\n\ - \u041A\u0440\u0456\u043C \u0442\u043E\u0433\u043E, ECHO \u0437\u0431\u0435\u0440\u0456\u0433\u0430\u0454 \u0444\u0430\u0439\u043B\u0438 cookie \u043D\u0430 \u0442\u0435\u0440\u043C\u0456\u043D\u0430\u043B\u0430\u0445 ECHO, \u0449\u043E\u0431 \u043F\u043E\u043A\u0440\u0430\u0449\u0438\u0442\u0438 \u0432\u0430\u0448 \u0434\u043E\u0441\u0432\u0456\u0434 \u0441\u043F\u0456\u043B\u043A\u0443\u0432\u0430\u043D\u043D\u044F.\n\ - \u0414\u0435\u0442\u0430\u043B\u044C\u043D\u0430 \u0456\u043D\u0444\u043E\u0440\u043C\u0430\u0446\u0456\u044F \u043F\u0440\u043E \u0432\u0438\u043A\u043E\u0440\u0438\u0441\u0442\u0430\u043D\u043D\u044F \u0444\u0430\u0439\u043B\u0456\u0432 cookie \u043D\u0430 \u0432\u0430\u0448\u043E\u043C\u0443 \u0442\u0435\u0440\u043C\u0456\u043D\u0430\u043B\u0456 ECHO \u0434\u043E\u0441\u0442\u0443\u043F\u043D\u0430 \u043D\u0430 [#e53935]*404 \u041D\u0435 \u0437\u043D\u0430\u0439\u0434\u0435\u043D\u043E*[]. -ECHO.read=\u041F\u0440\u0438\u0439\u043D\u044F\u0442\u0438 -NewBrains.title=\u041D\u043E\u0432\u0456 \u043C\u0456\u0437\u043A\u0438 -NewBrains=\u00AB\u041D\u044C\u044E \u0411\u0440\u0435\u0439\u043D\u0437 \u041A\u043E\u0440\u043F\u043E\u0440\u0435\u0439\u0448\u043D\u00BB, \u044F\u043A\u0430 \u043B\u0456\u0434\u0438\u0440\u0443\u0454 \u0432 \u0433\u0430\u043B\u0443\u0437\u0456 \u0431\u0456\u043E\u0442\u0435\u0445\u043D\u043E\u043B\u043E\u0433\u0456\u0439, \u043C\u0435\u0434\u0438\u0446\u0438\u043D\u0438, \u043D\u0435\u0432\u0440\u043E\u043B\u043E\u0433\u0456\u0457 \u0442\u043E\u0449\u043E, \u0454 \u043E\u0434\u043D\u0456\u0454\u044E \u0437 \u043D\u0430\u0439\u0431\u0456\u043B\u044C\u0448\u0438\u0445 \u043A\u043E\u043C\u043F\u0430\u043D\u0456\u0439 \u0443 \u0432\u0441\u044C\u043E\u043C\u0443 \u0441\u0432\u0456\u0442\u0456.\n\ - \u0417\u0433\u0456\u0434\u043D\u043E \u0437 \u043D\u0430\u0437\u0432\u043E\u044E, \u0432\u043E\u043D\u0438 \u0437\u0430\u0432\u0436\u0434\u0438 \u043F\u0435\u0440\u0448\u0456 \u0432 \u043D\u0430\u0443\u043A\u0430\u0445 \u043F\u0440\u043E \u043C\u043E\u0437\u043E\u043A.\n\u0411\u0456\u043B\u044C\u0448\u0456\u0441\u0442\u044C \u0456\u0437 \u0432\u0430\u0441 \u0446\u044C\u043E\u0433\u043E \u0449\u0435 \u043D\u0435 \u043F\u043E\u043C\u0456\u0442\u0438\u043B\u0438, \u0430\u043B\u0435 \u0446\u0435 \u0442\u0430\u043A\u043E\u0436 \u0454 \u0447\u0430\u0441\u0442\u0438\u043D\u043E\u044E \u0457\u0445\u043D\u0456\u0445 \u043F\u0440\u043E\u0435\u043A\u0442\u0456\u0432. -NewBrains.read=\u041F\u043E\u0437\u043D\u0430\u0447\u0438\u0442\u0438 \u043F\u0440\u043E\u0447\u0438\u0442\u0430\u043D\u0438\u043C -AdBlock.title=\u0417\u0430\u0431\u043B\u043E\u043A\u0443\u0432\u0430\u0442\u0438 \u0440\u0435\u043A\u043B\u0430\u043C\u0443 -AdBlock=\u0412\u0456\u0434\u0447\u0443\u0432\u0430\u0454\u0442\u0435, \u0449\u043E \u0441\u043F\u043B\u0438\u0432\u0430\u044E\u0447\u0430 \u0440\u0435\u043A\u043B\u0430\u043C\u0430 \u0432\u0430\u0441 \u0434\u0440\u0430\u0442\u0443\u0454??\n\ - \u0423\u0441\u0442\u0430\u043D\u043E\u0432\u0456\u0442\u044C AdBlock, \u044F\u043A\u0438\u0439 \u043C\u043E\u0436\u0435 \u0437\u0430\u0431\u0435\u0437\u043F\u0435\u0447\u0438\u0442\u0438 \u0432\u0430\u043C \u0430\u0431\u0441\u043E\u043B\u044E\u0442\u043D\u043E \u0447\u0438\u0441\u0442\u0435 \u0441\u0435\u0440\u0435\u0434\u043E\u0432\u0438\u0449\u0435!\n\ - P.S.: \u042F\u043A\u0449\u043E \u0432\u0438 \u0445\u043E\u0447\u0435\u0442\u0435 \u043F\u043E\u0432\u0435\u0440\u043D\u0443\u0442\u0438 \u0440\u0435\u043A\u043B\u0430\u043C\u0443, \u043F\u0435\u0440\u0435\u0432\u0456\u0440\u0442\u0435 \u043D\u0430\u043B\u0430\u0448\u0442\u0443\u0432\u0430\u043D\u043D\u044F \u0433\u0440\u0438:\n\ - \u041D\u0430\u043B\u0430\u0448\u0442\u0443\u0432\u0430\u043D\u043D\u044F >> Cyber IO >> \u041E\u0442\u0440\u0438\u043C\u0443\u0432\u0430\u0442\u0438 \u043F\u043E\u0432\u0456\u0434\u043E\u043C\u043B\u0435\u043D\u043D\u044F \u0432\u0456\u0434 \u00AB\u041F\u043B\u044E\u043C \u0421\u0442\u0430\u0440 \u0406\u043D\u043A\u043E\u0440\u043F\u043E\u0440\u0435\u0439\u0448\u043D\u00BB -AdBlock.yes=[accent]\u041D\u0435 \u0437\u0430\u0440\u0430\u0437[] -AdBlock.no=\u0423\u0441\u0442\u0430\u043D\u043E\u0432\u0438\u0442\u0438 -404NotFound.title=[#e53935]\u041F\u043E\u043C\u0438\u043B\u043A\u0430 404[] -404NotFound=[#e53935]\u041D\u0435 \u0437\u043D\u0430\u0439\u0434\u0435\u043D\u043E.[] -404NotFound.read=\u0412\u0438\u0439\u0442\u0438 +ECHO=Щоб подолати бар’єри спілкування між різними істотами та мовами на планетах, було розроблено ECHO.\n\ + Це забезпечило простий спосіб розмовляти, взаємодіяти один з одним одним клацанням миші.\n\ + Крім того, ECHO зберігає файли cookie на терміналах ECHO, щоб покращити ваш досвід спілкування.\n\ + Детальна інформація про використання файлів cookie на вашому терміналі ECHO доступна на [#e53935]*404 Не знайдено*[]. +ECHO.read=Прийняти +NewBrains.title=Нові мізки +NewBrains=«Нью Брейнз Корпорейшн», яка лідирує в галузі біотехнологій, медицини, неврології тощо, є однією з найбільших компаній у всьому світі.\n\ + Згідно з назвою, вони завжди перші в науках про мозок.\nБільшість із вас цього ще не помітили, але це також є частиною їхніх проектів. +NewBrains.read=Позначити прочитаним +AdBlock.title=Заблокувати рекламу +AdBlock=Відчуваєте, що спливаюча реклама вас дратує??\n\ + Установіть AdBlock, який може забезпечити вам абсолютно чисте середовище!\n\ + P.S.: Якщо ви хочете повернути рекламу, перевірте налаштування гри:\n\ + Налаштування >> Cyber IO >> Отримувати повідомлення від «Плюм Стар Інкорпорейшн» +AdBlock.yes=[accent]Не зараз[] +AdBlock.no=Установити +404NotFound.title=[#e53935]Помилка 404[] +404NotFound=[#e53935]Не знайдено.[] +404NotFound.read=Вийти diff --git a/assets/welcomes/zh_CN.properties b/assets/welcomes/zh_CN.properties index e35e50e2..d80d3c24 100644 --- a/assets/welcomes/zh_CN.properties +++ b/assets/welcomes/zh_CN.properties @@ -5,75 +5,75 @@ Default=If you saw this page, it might mean you are using the CyberIO for test o Default.read=I see #---Do not translate--- #Standard -welcome=\u6B22\u8FCE\u6E38\u73A9 Cyber IO {0}. +welcome=欢迎游玩 Cyber IO {0}. Discord.title=Discord -Discord=\u6709\u65F6\uFF0C\u5F53\u4F60\u72EC\u81EA\u6F2B\u6B65\u592A\u7A7A\uFF0C\u53EF\u80FD\u4F1A\u60F3\u5BFB\u627E\u4E00\u4E2A\u793E\u533A\u56E2\u961F\n\ -\u4F60\u53EF\u4EE5\u5206\u4EAB\u4F60\u7684\u7ECF\u9A8C\u6216\u8005\u95EE\u4E9B\u95EE\u9898\uFF08\u5F53\u7136\u4F60\u7528\u4E0D\u7740\u95EEbug\uFF09\u3002\n\ -\u5C3D\u7BA1\u201C\u98DE\u58F0\u201D\u4FE1\u53F7\u4E0D\u597D\uFF0C\u4E16\u754C\u4E0A\u4ECD\u7136\u6709\u4EBA\u5728\u60E6\u8BB0\u7740\u4F60\u2014\u2014Plum Star\u7684Discord\u3002\n\ -\u52A0\u5165\u6211\u4EEC\uFF0C\u5206\u4EAB\u4F60\u7684\u9645\u9047\uFF0C\u5766\u9732\u4F60\u7684\u7591\u95EE\u5427\uFF01 +Discord=有时,当你独自漫步太空,可能会想寻找一个社区团队\n\ +你可以分享你的经验或者问些问题。\n\ +尽管“飞声”信号不好,世界上仍然有人在惦记着你——Plum Star的Discord。\n\ +加入我们,分享你的际遇,坦露你的疑问吧! Discord.link=https://discord.gg/PDwyxM3waw -Discord.yes=[accent]\u6253\u5F00\u94FE\u63A5[] -Discord.no=\u6807\u8BB0\u4E3A\u5783\u573E\u5185\u5BB9 -UpdateECHO.title=\u66F4\u65B0\u201C\u98DE\u58F0\u201D -UpdateECHO=News: \u6700\u8FD1\uFF0C\u201C\u98DE\u58F0\u201D\u7EC8\u7AEF\u63A8\u51FA\u4E86\u65B0\u7248\u672C{0}\u3002\n\ - \u4F60\u53EF\u4EE5\u70B9\u51FB\u4E0B\u9762\u7684\u6309\u94AE\u66F4\u65B0\u4F60\u7684\u7EC8\u7AEF -UpdateECHO.update=[accent]\u66F4\u65B0[] -UpdateECHO.no=\u4EE5\u540E\u63D0\u9192\u6211 -UpdateECHO.skip-this=\u4E0D\u518D\u663E\u793A -UpdateECHO.break-update-warning=\u8B66\u544A\uFF1A\u6700\u65B0\u7248\u672C\u7684\u66F4\u65B0\u5DF2\u635F\u574F\uFF0C\u53EF\u80FD\u4F1A\u5BFC\u81F4\u5B58\u6863\u9519\u8BEF\u3002\u8BF7\u52A1\u5FC5\u8C28\u614E\uFF01 +Discord.yes=[accent]打开链接[] +Discord.no=标记为垃圾内容 +UpdateECHO.title=更新“飞声” +UpdateECHO=News: 最近,“飞声”终端推出了新版本{0}。\n\ + 你可以点击下面的按钮更新你的终端 +UpdateECHO.update=[accent]更新[] +UpdateECHO.no=以后提醒我 +UpdateECHO.skip-this=不再显示 +UpdateECHO.break-update-warning=警告:最新版本的更新已损坏,可能会导致存档错误。请务必谨慎! #v2 -EmploymentVerification.title=\u9A8C\u8BC1\u96C7\u4F63\u72B6\u6001 -EmploymentVerification=\u6B22\u8FCE\u5C31\u804C\u4E8EPlum Star\u516C\u53F8\uFF0C\u795D\u4F60\u4EAB\u53D7\u4E8E\u5D2D\u65B0\u7684\u5168\u90E8\u8D5B\u535A\u5B66\u79D1\u6280\uFF01\n\ -\u4F46\u4F60\u53EF\u80FD\u4F1A\u5F88\u70E6\u607C\uFF0C\u56E0\u4E3A\u4F60\u9700\u8981\u5E72\u8FDE\u63A5\u8BBE\u5907\u8FD9\u79CD\u4EE4\u4EBA\u538C\u5026\u7684\u5DE5\u4F5C\u3002\n\ -\u65E0\u8BBA\u5982\u4F55\uFF0C\u795D\u4F60\u597D\u8FD0\uFF01 -EmploymentVerification.read=\u52A0\u5165\uFF01 +EmploymentVerification.title=验证雇佣状态 +EmploymentVerification=欢迎就职于Plum Star公司,祝你享受于崭新的全部赛博学科技!\n\ +但你可能会很烦恼,因为你需要干连接设备这种令人厌倦的工作。\n\ +无论如何,祝你好运! +EmploymentVerification.read=加入! #v3 -ResearchProject.title=\u7814\u7A76\u8BA1\u5212 -ResearchProject=\u65E9\u4E0A\u597D\uFF0C\u65B0\u6765\u7684\uFF01\u81EA\u4ECE\u4E4B\u524D\u5750\u4F60\u4F4D\u5B50\u7684\u5458\u5DE5\u6309\u4E0B\u6682\u505C\u952E\u540E\uFF08\u55EF\u2026\u2026\u7269\u7406\u5C42\u9762\u4E0A\u7684\uFF09\uFF0C\n\ -\u5168\u606F\u9879\u76EE\uFF08holo-proj\uFF09\u505C\u4E86\u597D\u957F\u4E00\u6BB5\u65F6\u95F4\u3002\n\ -\u4F46\u597D\u6D88\u606F\u662F\u662F\uFF0C\u73B0\u5728\u8FD9\u4E2A\u9879\u76EE\u5DF2\u7ECF\u79FB\u4EA4\u5230\u4E86\u4F60\u7684\u624B\u4E0A\uFF0C\u5927\u5584\u4EBA\uFF0C\u73B0\u5728\u8D76\u7D27\u56DE\u53BB\u5DE5\u4F5C\u5427\uFF01 -ResearchProject.read=\u505A\u5DE5 -TheSHIP.title=\u201C\u68F1\u8239\u201D -TheSHIP=\u60F3\u8C61\u4F60\u6B63\u8EAB\u5904\u4E00\u671B\u65E0\u9645\u7684\u592A\u7A7A\uFF0C\u4EC0\u4E48\u4E1C\u897F\u5BF9\u4F60\u800C\u8A00\u662F\u6700\u91CD\u8981\u7684\uFF1F\u6BEB\u65E0\u7591\u95EE\uFF0C\u662F\u592A\u7A7A\u98DE\u8239\n\ -\u6700\u597D\u6700\u660E\u667A\u7684\u9009\u62E9\u6B63\u662F\u201C\u68F1\u8239\u201D\uFF0C\u7531Plum Star\u516C\u53F8\u51FA\u54C1\uFF0C\n \u57FA\u4E8E\u6838\u805A\u53D8\u80FD\u6E90\u63A7\u5236\u548C\u6700\u65B0\u7684\u5965\u7F57\u535A\u7F57\u65AF\u64CD\u4F5C\u7CFB\u7EDF\uFF08\u8D28\u91CF\u4FDD\u969C\uFF09\u3002\n\ -\u5546\u54C1\u7F16\u53F7\uFF1A111_1111_11_1001\n\ -\u6CE8\uFF1A\u201C\u98DE\u58F0\u201D\u5DF2\u7ECF\u901A\u8FC7 -TheSHIP.read=\u6807\u8BB0\u4E3A\u5783\u573E\u5185\u5BB9 -ECHO.title=\u201C\u98DE\u58F0\u201D -ECHO=\u4E3A\u4E86\u5904\u7406\u5728\u884C\u661F\u4E0A\u6570\u79CD\u7269\u79CD\u4E0E\u5DE5\u5177\u4E4B\u95F4\u4EA4\u6D41\u7684\u969C\u788D\uFF0C\u201C\u98DE\u58F0\u201D\u88AB\u53D1\u660E\u4E86\u51FA\u6765\u3002\n\ -\u5B83\u63D0\u4F9B\u4E86\u4E00\u79CD\u7B80\u5355\u7684\u65B9\u6CD5\u6765\u4E0E\u5F7C\u6B64\u4EA4\u4E92\uFF0C\u53EA\u9700\u8981\u8F7B\u8F7B\u4E00\u70B9\u3002\n\ -\u53E6\u5916\uFF0C\u201C\u98DE\u58F0\u201D\u5728\u7EC8\u7AEF\u5B58\u50A8\u4E86 cookie \u4EE5\u4F7F\u60A8\u7684\u4F53\u9A8C\u66F4\u52A0\u8212\u9002\u3002\n\ -\u5173\u4E8E\u201C\u98DE\u58F0\u201D\u5728\u7EC8\u7AEF\u4F7F\u7528 cookie \u7684\u66F4\u591A\u4FE1\u606F\uFF0C\u8BF7\u53C2\u89C1\u4E8E[#e53935]*404 Not Found*[]\u3002 -ECHO.read=\u901A\u8FC7 +ResearchProject.title=研究计划 +ResearchProject=早上好,新来的!自从之前坐你位子的员工按下暂停键后(嗯……物理层面上的),\n\ +全息项目(holo-proj)停了好长一段时间。\n\ +但好消息是是,现在这个项目已经移交到了你的手上,大善人,现在赶紧回去工作吧! +ResearchProject.read=做工 +TheSHIP.title=“棱船” +TheSHIP=想象你正身处一望无际的太空,什么东西对你而言是最重要的?毫无疑问,是太空飞船\n\ +最好最明智的选择正是“棱船”,由Plum Star公司出品,\n 基于核聚变能源控制和最新的奥罗博罗斯操作系统(质量保障)。\n\ +商品编号:111_1111_11_1001\n\ +注:“飞声”已经通过 +TheSHIP.read=标记为垃圾内容 +ECHO.title=“飞声” +ECHO=为了处理在行星上数种物种与工具之间交流的障碍,“飞声”被发明了出来。\n\ +它提供了一种简单的方法来与彼此交互,只需要轻轻一点。\n\ +另外,“飞声”在终端存储了 cookie 以使您的体验更加舒适。\n\ +关于“飞声”在终端使用 cookie 的更多信息,请参见于[#e53935]*404 Not Found*[]。 +ECHO.read=通过 NewBrains.title=New Brains -NewBrains=New Brains\u516C\u53F8\u5F15\u9886\u751F\u7269\u5B66\u3001\u836F\u5B66\u548C\u795E\u7ECF\u5B66\u884C\u4E1A\u9876\u6D41\uFF0C\u662F\u5B87\u5B99\u4E2D\u6700\u5927\u7684\u516C\u53F8\u4E4B\u4E00\u3002\n\ -\u6B63\u5982\u5176\u540D\uFF0C\u4ED6\u4EEC\u7AD9\u5728\u4E86\u8111\u79D1\u5B66\u7684\u524D\u6CBF\u4F4D\u7F6E\u4E0A\u3002\n\u4F60\u4EEC\u5927\u591A\u6570\u53EF\u80FD\u8FD8\u6CA1\u6709\u6CE8\u610F\u5230\uFF0C\u8FD9\u4E5F\u662F\u4ED6\u4EEC\u9879\u76EE\u4E2D\u7684\u4E00\u90E8\u5206\u3002 -NewBrains.read=\u6807\u8BB0\u4E3A\u5DF2\u8BFB -AdBlock.title=\u5C4F\u853D\u5E7F\u544A -AdBlock=\u4F60\u89C9\u5F97\u5F39\u7A97\u5F88\u70E6\u4EBA\u5417\uFF1F\n\ - \u90A3\u5C31\u6765\u8BD5\u8BD5 AdBlock \u5427\uFF0C\u8FD8\u4F60\u4E00\u4E2A\u5E72\u51C0\u6E05\u723D\u7684\u6D4F\u89C8\u73AF\u5883\uFF01\n\ - \u6CE8\uFF1A\u5982\u679C\u4F60\u60F3\u6062\u590D\u67D0\u4E9B\u5E7F\u544A\uFF0C\u8BF7\u5728\u6B64\u5904\u8BBE\u7F6E\uFF1A\n\ - \u8BBE\u7F6E >> Cyber IO >> \u4ECEPlum Star\u516C\u53F8\u83B7\u5F97\u6570\u636E -AdBlock.yes=[accent]\u7A0D\u540E\u63D0\u9192\u6211[] -AdBlock.no=\u5B89\u88C5 -404NotFound.title=[#e53935]404 \u9875\u9762\u672A\u627E\u5230] -404NotFound=[#e53935]404 \u9875\u9762\u672A\u627E\u5230[] -404NotFound.read=\u9000\u51FA +NewBrains=New Brains公司引领生物学、药学和神经学行业顶流,是宇宙中最大的公司之一。\n\ +正如其名,他们站在了脑科学的前沿位置上。\n你们大多数可能还没有注意到,这也是他们项目中的一部分。 +NewBrains.read=标记为已读 +AdBlock.title=屏蔽广告 +AdBlock=你觉得弹窗很烦人吗?\n\ + 那就来试试 AdBlock 吧,还你一个干净清爽的浏览环境!\n\ + 注:如果你想恢复某些广告,请在此处设置:\n\ + 设置 >> Cyber IO >> 从Plum Star公司获得数据 +AdBlock.yes=[accent]稍后提醒我[] +AdBlock.no=安装 +404NotFound.title=[#e53935]404 页面未找到] +404NotFound=[#e53935]404 页面未找到[] +404NotFound.read=退出 OhNo.title=Oh No! OhNo=Oh No! OhNo.read=Oh No -RateUs.title=\u7ED9 Cyber IO \u8BC4\u5206 -RateUs=\u6253\u6270\u4E00\u4E0B\uFF0C\u60A8\u73A9Cyber IO\u5F00\u5FC3\u5417\uFF1F\n\ - \u8BF7\u60A8\u7559\u4E0B\u8BC4\u4F30\u4EE5\u52A9\u4E8E\u6211\u4EEC\u6539\u8FDBCyber IO\u3002 -RateUs.submit=\u63D0\u4EA4 -ErekirDetected.title=\u68C0\u6D4B\u5230\u65B0\u884C\u661F -ErekirDetected=\u6700\u8FD1\u96F7\u8FBE\u4E0A\u663E\u793A\u51FA\u4E86\u4E00\u9897\u65B0\u884C\u661F\uFF0CPlum Star\u516C\u53F8\u51B3\u5B9A\u547D\u540D\u5B83\u4E3A\u201C\u57C3\u91CC\u514B\u5C14\u201D\n\ - \u4F60\u7684\u804C\u4F4D\u5DF2\u7ECF\u6539\u53D8\uFF0C\u76EE\u524D\u662F\u63A2\u7D22\u65B0\u884C\u661F\u7684\u5148\u950B\u961F\u3002\n\ - \u6211\u4EEC\u4F1A\u5B9A\u671F\u7ED9\u60A8\u51C6\u5907\u7269\u8D44\u98DE\u8239\uFF0C\u53EA\u9700\u8981\u60A8\u5207\u6362\u63A7\u5236\u53F0\u7684\u822A\u7EBF\u5373\u53EF\u3002\n\ - Main Menu >> Cyber IO >> \u7279\u6B8A\u5185\u5BB9 >> \u57C3\u91CC\u514B\u5C14 +RateUs.title=给 Cyber IO 评分 +RateUs=打扰一下,您玩Cyber IO开心吗?\n\ + 请您留下评估以助于我们改进Cyber IO。 +RateUs.submit=提交 +ErekirDetected.title=检测到新行星 +ErekirDetected=最近雷达上显示出了一颗新行星,Plum Star公司决定命名它为“埃里克尔”\n\ + 你的职位已经改变,目前是探索新行星的先锋队。\n\ + 我们会定期给您准备物资飞船,只需要您切换控制台的航线即可。\n\ + Main Menu >> Cyber IO >> 特殊内容 >> 埃里克尔 ErekirDetected.read=OK -SetOutErekir.title=\u5411\u57C3\u91CC\u514B\u5C14\u7684\u822A\u7EBF -SetOutErekir=\u4E0D\u80FD\u518D\u7B49\u4E86\uFF0C\u73B0\u5728\u4E0D\u53BB\uFF0C\u6211\u4EEC\u7684\u7ADE\u4E89\u5BF9\u624B\u5C31\u4F1A\u5148\u6211\u4EEC\u4E00\u6B65\uFF01\n\ - \u98DE\u8239\u51C6\u5907\u597D\u4E86\uFF0C\u8D70\uFF01 -SetOutErekir.yes=[accent]\u542F\u7A0B[] -SetOutErekir.no=\u7EE7\u7EED\u7B49\u5019 \ No newline at end of file +SetOutErekir.title=向埃里克尔的航线 +SetOutErekir=不能再等了,现在不去,我们的竞争对手就会先我们一步!\n\ + 飞船准备好了,走! +SetOutErekir.yes=[accent]启程[] +SetOutErekir.no=继续等候 \ No newline at end of file diff --git a/main/src/net/liplum/ui/CioUI.kt b/main/src/net/liplum/ui/CioUI.kt index 3e8201f4..e7f99196 100644 --- a/main/src/net/liplum/ui/CioUI.kt +++ b/main/src/net/liplum/ui/CioUI.kt @@ -33,7 +33,7 @@ import net.liplum.utils.IsLocal import net.liplum.utils.safeCall import net.liplum.welcome.Welcome import net.liplum.welcome.WelcomeConditions -import net.liplum.welcome.Welcomes +import net.liplum.welcome.WelcomeScenes import net.liplum.welcome.findAll import plumy.core.ClientOnly import plumy.core.NonSteamOnly @@ -167,7 +167,7 @@ object CioUI { Updater.accessJob?.join() if (!failed) { if (Updater.requireUpdate) { - val updateScenes = Welcomes.findAll { tip -> + val updateScenes = WelcomeScenes.findAll { tip -> tip.condition == WelcomeConditions.CheckUpdate } if (updateScenes.isEmpty()) { @@ -176,7 +176,7 @@ object CioUI { val updateScene = updateScenes.randomExcept(atLeastOne = true) { id != Settings.LastWelcomeID } - Welcomes.updateECHO + WelcomeScenes.updateECHO if (updateScene != null) Welcome.createEntity(updateScene).showTip() else diff --git a/main/src/net/liplum/welcome/WelcomeScene.kt b/main/src/net/liplum/welcome/WelcomeScene.kt index 105e1be9..883c627c 100644 --- a/main/src/net/liplum/welcome/WelcomeScene.kt +++ b/main/src/net/liplum/welcome/WelcomeScene.kt @@ -5,18 +5,18 @@ import mindustry.ui.dialogs.BaseDialog class WelcomeScene( @JvmField val id: String, - @JvmField val condition: WelcomeCondition = WelcomeCondition.Default, - @JvmField val template: WelcomeTemplate = WelcomeTemplate.Default, @JvmField var iconPath: String = "icon", @JvmField var chance: Int = 100, + @JvmField val condition: WelcomeCondition, + @JvmField val template: WelcomeTemplate, ) { override fun toString() = id companion object { val Default = WelcomeScene( id = "Default", - condition = WelcomeConditions.ShowWelcome, - template = WelcomeTemplates.Story(), + condition = WelcomeCondition.Default, + template = WelcomeTemplate.Default, chance = 0, ) } diff --git a/main/src/net/liplum/welcome/WelcomeScenePacks.kt b/main/src/net/liplum/welcome/WelcomeScenePacks.kt index 00758188..fde88eca 100644 --- a/main/src/net/liplum/welcome/WelcomeScenePacks.kt +++ b/main/src/net/liplum/welcome/WelcomeScenePacks.kt @@ -2,41 +2,41 @@ package net.liplum.welcome object WelcomeScenePacks { val common = WelcomeScenePack( - default = Welcomes.default, + default = WelcomeScene.Default, scenes = listOf( - Welcomes.updateECHO, - Welcomes.theShip, - Welcomes.echo, - Welcomes.newBrains, - Welcomes.discord, - Welcomes.adBlock, - Welcomes.`404NotFound`, - Welcomes.ohNo, - Welcomes.rateUs, + WelcomeScenes.updateECHO, + WelcomeScenes.theShip, + WelcomeScenes.echo, + WelcomeScenes.newBrains, + WelcomeScenes.discord, + WelcomeScenes.adBlock, + WelcomeScenes.`404NotFound`, + WelcomeScenes.ohNo, + WelcomeScenes.rateUs, ) ) val v2 = WelcomeScenePack( - default = Welcomes.employmentVerification, + default = WelcomeScenes.employmentVerification, scenes = listOf( - Welcomes.employmentVerification, + WelcomeScenes.employmentVerification, ) ) val v3 = common.inherit( - default = Welcomes.researchProject, + default = WelcomeScenes.researchProject, scenes = listOf( - Welcomes.employmentVerification, + WelcomeScenes.employmentVerification, ) ) val v4 = common.inherit( - default = Welcomes.erekirDetected, + default = WelcomeScenes.erekirDetected, scenes = listOf( - Welcomes.erekirDetected, - Welcomes.setOutErekir, + WelcomeScenes.erekirDetected, + WelcomeScenes.setOutErekir, ) ) val v4_1 = v4.inherit( scenes = listOf( - Welcomes.cyberionForErekir, + WelcomeScenes.cyberionForErekir, ) ) val v5 = v4_1.inherit() diff --git a/main/src/net/liplum/welcome/Welcomes.kt b/main/src/net/liplum/welcome/WelcomeScenes.kt similarity index 79% rename from main/src/net/liplum/welcome/Welcomes.kt rename to main/src/net/liplum/welcome/WelcomeScenes.kt index 336cd8a6..6c221994 100644 --- a/main/src/net/liplum/welcome/Welcomes.kt +++ b/main/src/net/liplum/welcome/WelcomeScenes.kt @@ -2,17 +2,15 @@ package net.liplum.welcome import net.liplum.Settings -object Welcomes { - val default = WelcomeScene( - id = "Default", - template = WelcomeTemplates.Story(), - ) +object WelcomeScenes { val employmentVerification = WelcomeScene( id = "EmploymentVerification", condition = WelcomeConditions.SpecialDishes, + template = WelcomeTemplates.Story(), ) val discord = WelcomeScene( id = "Discord", + condition = WelcomeConditions.ShowWelcome, template = WelcomeTemplates.DoAction( yesAction = WelcomeActions.OpenLink("@link"), ), @@ -28,24 +26,32 @@ object Welcomes { val researchProject = WelcomeScene( id = "ResearchProject", iconPath = "welcome-holo-project", + template = WelcomeTemplates.Story(), condition = WelcomeConditions.SpecialDishes, ) val theShip = WelcomeScene( id = "TheSHIP", + template = WelcomeTemplates.Story(), + condition = WelcomeConditions.ShowWelcome, ) val echo = WelcomeScene( id = "ECHO", + template = WelcomeTemplates.Story(), + condition = WelcomeConditions.ShowWelcome, ) val newBrains = WelcomeScene( id = "NewBrains", iconPath = "heimdall", + template = WelcomeTemplates.Story(), + condition = WelcomeConditions.ShowWelcome, ) val adBlock = WelcomeScene( id = "AdBlock", + iconPath = "ad-block", template = WelcomeTemplates.DoAction( noAction = WelcomeActions.StopReceiveWelcome, ), - iconPath = "ad-block", + condition = WelcomeConditions.ShowWelcome, chance = 300, ) val `404NotFound` = WelcomeScene( @@ -65,6 +71,7 @@ object Welcomes { template = WelcomeTemplates.Story( showPoliteWelcome = false, ), + condition = WelcomeConditions.ShowWelcome, chance = 200, ) val rateUs = WelcomeScene( @@ -75,12 +82,13 @@ object Welcomes { activeStarIconPath = "star", inactiveStarIconPath = "star-inactive", ), - iconPath = "@error", + condition = WelcomeConditions.ShowWelcome, chance = 200, ) val erekirDetected = WelcomeScene( id = "ErekirDetected", iconPath = "spec-erekir", + template = WelcomeTemplates.Story(), condition = WelcomeConditions.SpecialDishes, ) val setOutErekir = WelcomeScene( @@ -102,7 +110,6 @@ object Welcomes { }, ) val tips = listOf( - default, employmentVerification, discord, updateECHO, @@ -121,11 +128,11 @@ object Welcomes { val id2Tips = tips.associateBy { it.id } } -operator fun Welcomes.get(id: String) = id2Tips[id] ?: WelcomeScene.Default -inline fun Welcomes.find(filter: (WelcomeScene) -> Boolean): WelcomeScene? { +operator fun WelcomeScenes.get(id: String) = id2Tips[id] ?: WelcomeScene.Default +inline fun WelcomeScenes.find(filter: (WelcomeScene) -> Boolean): WelcomeScene? { return id2Tips.values.find(filter) } -inline fun Welcomes.findAll(filter: (WelcomeScene) -> Boolean): List { +inline fun WelcomeScenes.findAll(filter: (WelcomeScene) -> Boolean): List { return id2Tips.values.filter(filter) } \ No newline at end of file diff --git a/main/src/net/liplum/welcome/WelcomeTemplates.kt b/main/src/net/liplum/welcome/WelcomeTemplates.kt index 617374d8..7bdc98a9 100644 --- a/main/src/net/liplum/welcome/WelcomeTemplates.kt +++ b/main/src/net/liplum/welcome/WelcomeTemplates.kt @@ -35,13 +35,13 @@ object WelcomeTemplates { addPoster(entity.icon) if (showPoliteWelcome) addPoliteWelcome(entity) cont.table { - addCloseButton(entity["button-a"], it, 200f) { + addCloseButton(entity["button-a"], table = it, width = 150f) { actionA(entity) } - addCloseButton(entity["button-b"], it, 200f) { + addCloseButton(entity["button-b"], table = it, width = 150f) { actionB(entity) } - addCloseButton(entity["button-c"], it, 200f) { + addCloseButton(entity["button-c"], table = it, width = 150f) { actionC(entity) } }.growX() @@ -61,10 +61,10 @@ object WelcomeTemplates { if (showPoliteWelcome) addPoliteWelcome(entity) addCenterText(entity.content) cont.table { - addCloseButton(entity["yes"]) { + addCloseButton(entity["yes"], table = it) { yesAction(entity) } - addCloseButton(entity["no"]) { + addCloseButton(entity["no"], table = it) { noAction(entity) } }.growX() @@ -140,14 +140,14 @@ object WelcomeTemplates { if (Updater.hasUpdateDescription) addBoxedText(Updater.UpdateDescription) cont.table { - addCloseButton(entity["update"], it) { + addCloseButton(entity["update"], it, width = 150f) { WelcomeActions.UpdateCyberIO(entity) - }.size(150f, 50f) - addCloseButton(entity["no"], it) { - }.size(150f, 50f) - addCloseButton(entity["skip-this"], it) { + } + addCloseButton(entity["no"], it, width = 150f) { + } + addCloseButton(entity["skip-this"], it, width = 150f) { WelcomeActions.SkipThisUpdate(entity) - }.size(150f, 50f) + } }.growX() .row() }