mirror of
https://github.com/curioustorvald/Terrarum.git
synced 2026-03-14 23:56:07 +09:00
some locale changes; remoCon changes on load menu
This commit is contained in:
@@ -24,7 +24,7 @@ class FixtureTypewriter : FixtureBase {
|
||||
// constructor used when the game loads from the savefile
|
||||
constructor() : super(
|
||||
BlockBox(BlockBox.NO_COLLISION, 1, 1),
|
||||
nameFun = { Lang["GAME_ITEM_TYPEWRITER"] }
|
||||
nameFun = { Lang["ITEM_TYPEWRITER"] }
|
||||
) {
|
||||
|
||||
density = 2000.0
|
||||
|
||||
@@ -14,7 +14,7 @@ class FixtureWallCalendar : FixtureBase {
|
||||
|
||||
constructor() : super(
|
||||
BlockBox(BlockBox.NO_COLLISION, 1, 1),
|
||||
nameFun = { Lang["GAME_ITEM_CALENDAR"] }
|
||||
nameFun = { Lang["ITEM_CALENDAR"] }
|
||||
) {
|
||||
val itemImage = FixtureItemBase.getItemImageFromSingleImage("basegame", "sprites/fixtures/calendar.tga")
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@ import net.torvald.terrarum.modulebasegame.gameactors.FixtureTikiTorch
|
||||
class ItemTypewriter(originalID: ItemID) : FixtureItemBase(originalID, "net.torvald.terrarum.modulebasegame.gameactors.FixtureTypewriter") {
|
||||
|
||||
override var dynamicID: ItemID = originalID
|
||||
override val originalName = "GAME_ITEM_TYPEWRITER"
|
||||
override val originalName = "ITEM_TYPEWRITER"
|
||||
override var baseMass = FixtureTikiTorch.MASS
|
||||
override var stackable = true
|
||||
override var inventoryCategory = Category.MISC
|
||||
|
||||
@@ -10,7 +10,7 @@ import net.torvald.terrarum.gameitems.ItemID
|
||||
class ItemWallCalendar(originalID: ItemID) : FixtureItemBase(originalID, "net.torvald.terrarum.modulebasegame.gameactors.FixtureWallCalendar") {
|
||||
|
||||
override var dynamicID: ItemID = originalID
|
||||
override val originalName = "GAME_ITEM_CALENDAR"
|
||||
override val originalName = "ITEM_CALENDAR"
|
||||
override var baseMass = 1.0
|
||||
override var stackable = true
|
||||
override var inventoryCategory = Category.MISC
|
||||
|
||||
@@ -235,7 +235,7 @@ class UILoadList(val full: UILoadSavegame) : UICanvas() {
|
||||
if (showSpinner) {
|
||||
val spin = spinner.get(spinnerFrame % 8, spinnerFrame / 8)
|
||||
val offX = UIRemoCon.menubarOffX - UIRemoCon.UIRemoConElement.paddingLeft + 72 + 1
|
||||
val offY = UIRemoCon.menubarOffY - UIRemoCon.UIRemoConElement.lineHeight * 3 + 16
|
||||
val offY = UIRemoCon.menubarOffY - UIRemoCon.UIRemoConElement.lineHeight * 4 + 16
|
||||
batch.draw(spin, offX.toFloat(), offY.toFloat())
|
||||
}
|
||||
}
|
||||
|
||||
@@ -90,8 +90,17 @@ class UILoadSavegame(val remoCon: UIRemoCon) : Advanceable() {
|
||||
listOf(NullUI/*, transitionalAutosave*/)
|
||||
)
|
||||
|
||||
internal fun queueUpManageScr() { transitionPanel.setCentreUIto(0) }
|
||||
internal fun queueUpNewCharScr() { transitionPanel.setCentreUIto(1) }
|
||||
private val nodesForListing = Yaml(UITitleRemoConYaml.injectedMenuSingleCharSel).parse()
|
||||
private val nodesForManage = Yaml(UITitleRemoConYaml.injectedMenuSingleSaveManage).parse()
|
||||
|
||||
internal fun queueUpManageScr() {
|
||||
transitionPanel.setCentreUIto(0)
|
||||
remoCon.setNewRemoConContents(nodesForManage)
|
||||
}
|
||||
internal fun queueUpNewCharScr() {
|
||||
transitionPanel.setCentreUIto(1)
|
||||
remoCon.setNewRemoConContents(nodesForListing)
|
||||
}
|
||||
|
||||
// internal fun bringAutosaveSelectorUp() { transitionPanel.setRightUIto(1) }
|
||||
// internal fun takeAutosaveSelectorDown() { transitionPanel.setRightUIto(0) }
|
||||
@@ -102,6 +111,10 @@ class UILoadSavegame(val remoCon: UIRemoCon) : Advanceable() {
|
||||
|
||||
internal fun changePanelTo(index: Int) {
|
||||
transitionPanel.requestTransition(index)
|
||||
if (index == 1)
|
||||
remoCon.setNewRemoConContents(nodesForManage)
|
||||
else
|
||||
remoCon.setNewRemoConContents(nodesForListing)
|
||||
}
|
||||
|
||||
override fun advanceMode(button: UIItem) {
|
||||
@@ -118,6 +131,9 @@ class UILoadSavegame(val remoCon: UIRemoCon) : Advanceable() {
|
||||
// takeAutosaveSelectorDown()
|
||||
transitionPanel.show()
|
||||
|
||||
nodesForListing.parent = remoCon.treeRoot
|
||||
nodesForManage.parent = remoCon.treeRoot
|
||||
|
||||
}
|
||||
|
||||
override fun hide() {
|
||||
|
||||
@@ -41,6 +41,7 @@ object UITitleRemoConYaml {
|
||||
|
||||
// todo add MENU_IO_IMPORT
|
||||
val injectedMenuSingleCharSel = """
|
||||
- MENU_IO_IMPORT
|
||||
- CONTEXT_CHARACTER_NEW : net.torvald.terrarum.modulebasegame.ui.UINewCharacter
|
||||
- MENU_LABEL_RETURN
|
||||
"""
|
||||
@@ -48,6 +49,12 @@ object UITitleRemoConYaml {
|
||||
val injectedMenuSingleWorldSel = """
|
||||
- CONTEXT_WORLD_NEW : net.torvald.terrarum.modulebasegame.ui.UINewWorld
|
||||
- MENU_LABEL_RETURN
|
||||
"""
|
||||
|
||||
val injectedMenuSingleSaveManage = """
|
||||
- MENU_MODULES
|
||||
- MENU_LABEL_PREV_SAVES
|
||||
- MENU_LABEL_RETURN
|
||||
"""
|
||||
|
||||
operator fun invoke(hasSave: Boolean) =
|
||||
|
||||
Reference in New Issue
Block a user