From ac439d47a1381436c3917668c7ae660c6a1c034e Mon Sep 17 00:00:00 2001 From: Trilleo Date: Sat, 19 Sep 2026 20:42:39 +0800 Subject: [PATCH 1/6] Internal: Reformat documentation --- CHANGELOG.md | 14 +++++++------- CLAUDE.md | 18 +++++++++--------- README.md | 26 +++++++++++++------------- docs/DEVELOPER_GUIDE.md | 10 +++++----- docs/UTILITY_GUIDE.md | 36 ++++++++++++++++++------------------ 5 files changed, 52 insertions(+), 52 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 80c8b86..50d8541 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -20,8 +20,8 @@ #### Bank Menu + The Deposit, Withdraw, and Bank History buttons now have a blank row above and below them instead of being wedged - between the bank icon and the bottom row, so the bank details, the actions, and the navigation read as three - separate blocks. The menu is one row taller for it, and the amount menu is laid out the same way. + between the bank icon and the bottom row, so the bank details, the actions, and the navigation read as three separate + blocks. The menu is one row taller for it, and the amount menu is laid out the same way. #### Admin Menus @@ -31,9 +31,9 @@ #### Misc -+ New `bank-amounts` setting in `config.yml` lists the preset amounts the deposit and withdraw menus offer. Amounts - that are zero or negative are dropped, duplicates removed, and the rest sorted; up to nine fit in the menu row. An - empty list leaves players with only Everything and Custom Amount. ++ New `bank-amounts` setting in `config.yml` lists the preset amounts the deposit and withdraw menus offer. Amounts that + are zero or negative are dropped, duplicates removed, and the rest sorted; up to nine fit in the menu row. An empty + list leaves players with only Everything and Custom Amount. ## Version 1.0.1 @@ -84,8 +84,8 @@ #### Misc + Added a `Prices` utility that works out what a menu action costs — claims, outposts, spawn travel, plot types, town - merges — from Towny's config and the town or nation involved, and `Menu.costLine` / `Menu.priceLine` to turn an - amount into lore. + merges — from Towny's config and the town or nation involved, and `Menu.costLine` / `Menu.priceLine` to turn an amount + into lore. + `Pickers.option` takes a `lines` lambda for per-option lore. + Added `LoreBlocks`, which lays an icon's lore out in blocks: a blank line under the display name, single separators between blocks, a divider rule sized to the longest line above the actions, and no separator left dangling at either diff --git a/CLAUDE.md b/CLAUDE.md index c71f4db..298d0ed 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -57,8 +57,8 @@ Before finishing any task that changes the plugin, do all of the following: The local test server lives in `run/` (gitignored). `copyPlugin` deletes every `TownyMenu-*.jar` and `towny-*.jar` already in `run/plugins/` before copying, so a version bump never leaves two copies for Bukkit to load. It puts the -matching Towny jar there too, but the -Paper 26.2 jar (`run/paper-*.jar`) must be downloaded by hand from https://papermc.io/downloads/paper, and `eula.txt` +matching Towny jar there too, but the Paper 26.2 jar (`run/paper-*.jar`) must be downloaded by hand +from https://papermc.io/downloads/paper, and `eula.txt` accepted, before `startServer` works. The server console reads commands from the terminal running Gradle. ## Repository Layout @@ -119,14 +119,14 @@ Extend `Menu` (or `PagedMenu` for lists) and implement `build()`, which runs on - **Keep `PagedMenu` entries lazy** — pass the icon as a lambda to `MenuEntry` so off-page icons are never built. - **Show what a button costs** — a button that spends money takes its amount from `Prices` and turns it into lore with `costLine(...)` / `priceLine(...)`, so the figure is this server's and not a guess. -- **Lay every icon's lore out in the same blocks** — a tooltip reads name → description → data → actions, and a new - icon follows that order or it looks out of place beside the others. With an `Icons` builder the description is the +- **Lay every icon's lore out in the same blocks** — a tooltip reads name → description → data → actions, and a new icon + follows that order or it looks out of place beside the others. With an `Icons` builder the description is the `description` argument, the data and cost lines are the `extra` varargs, and everything about clicking is - `actions = listOf(...)`; with `itemStack { }` directly, use `loreWrapped(...)`, `loreBreak()` between data blocks, - and `loreActions(...)` to close. Never hand-roll the spacing: no `""` lore line to separate blocks, no divider drawn - by hand, no blank line under the name — `LoreBlocks` adds all three, collapses repeats, and trims a block that turns - out empty. The mistake to watch for is a click hint left among the data lines; it belongs in `actions`, which is what - puts it below the divider. See [The shape of an icon](docs/DEVELOPER_GUIDE.md#the-shape-of-an-icon). + `actions = listOf(...)`; with `itemStack { }` directly, use `loreWrapped(...)`, `loreBreak()` between data blocks, and + `loreActions(...)` to close. Never hand-roll the spacing: no `""` lore line to separate blocks, no divider drawn by + hand, no blank line under the name — `LoreBlocks` adds all three, collapses repeats, and trims a block that turns out + empty. The mistake to watch for is a click hint left among the data lines; it belongs in `actions`, which is what puts + it below the divider. See [The shape of an icon](docs/DEVELOPER_GUIDE.md#the-shape-of-an-icon). ## Translations diff --git a/README.md b/README.md index d95a546..22e97fe 100644 --- a/README.md +++ b/README.md @@ -37,8 +37,8 @@ - **Status pages** — Click your town or nation to see its level, what the next level needs, its limits, the daily upkeep, and warnings for debt, ruins, conquest, and overclaiming. - **Leaderboards and prices** — Rank towns, nations, and players by residents, land, and money, and see every price on - the server with a countdown to the next Towny day. Buttons that spend money show their own price too, so you know - what a claim, a teleport, or a plot costs before you click it. + the server with a countdown to the next Towny day. Buttons that spend money show their own price too, so you know what + a claim, a teleport, or a plot costs before you click it. - **Directories** — Browse and rank every town and nation by residents, claims, bank balance, distance, and more; visit, join, donate, buy a town that is for sale, or propose alliances. - **Invites** — Accept or decline town invites, nation invites for your town, and alliance requests in one place, or @@ -72,9 +72,9 @@ TownyMenu is an addon: Towny must be installed on the server, or TownyMenu will The compiled JAR is placed in `build/libs/`. Run `./gradlew copyPlugin` to copy it, along with the matching Towny jar, into `run/plugins/` for the local test server — any older copy of either is deleted first — or `./gradlew startServer` -to copy them and start the server. Before the -first start, download a Paper 26.2 jar from [papermc.io](https://papermc.io/downloads/paper) into `run/`, then accept -the EULA in `run/eula.txt` after the first launch. +to copy them and start the server. Before the first start, download a Paper 26.2 jar +from [papermc.io](https://papermc.io/downloads/paper) into `run/`, then accept the EULA in `run/eula.txt` after the +first launch. Prebuilt jars are attached to every [GitHub release](https://github.com/TriBinary/TownyMenu/releases); see the [change log](CHANGELOG.md) for what changed in each one. @@ -94,14 +94,14 @@ All commands are sub-commands of `/townymenu` (alias `/tm`). ## Configuration -| Key | Default | Description | -|:---------------------------|:--------|:----------------------------------------------------------------------------| -| `message-prefix` | — | MiniMessage prefix shown before plugin messages | -| `language` | `auto` | `auto` follows each player's client language; `en_US` or `zh_CN` forces one | -| `sneak-swap-hand-shortcut` | `true` | Open the main menu by pressing swap-hand (F) while sneaking | -| `tutorial-join-hint` | `true` | Suggest the tutorial to players without a town when they join | -| `live-menu-refresh` | `true` | Update open menus when Towny changes what they show | -| `towny-alerts` | `true` | Announce invites, bankruptcy, and ruin in chat, linked to the right menu | +| Key | Default | Description | +|:---------------------------|:-----------------------|:----------------------------------------------------------------------------------------------| +| `message-prefix` | — | MiniMessage prefix shown before plugin messages | +| `language` | `auto` | `auto` follows each player's client language; `en_US` or `zh_CN` forces one | +| `sneak-swap-hand-shortcut` | `true` | Open the main menu by pressing swap-hand (F) while sneaking | +| `tutorial-join-hint` | `true` | Suggest the tutorial to players without a town when they join | +| `live-menu-refresh` | `true` | Update open menus when Towny changes what they show | +| `towny-alerts` | `true` | Announce invites, bankruptcy, and ruin in chat, linked to the right menu | | `bank-amounts` | `10, 100, 1000, 10000` | Preset amounts the deposit and withdraw menus offer, alongside Everything and a custom amount | ## Translations diff --git a/docs/DEVELOPER_GUIDE.md b/docs/DEVELOPER_GUIDE.md index ac37c3b..ffe7249 100644 --- a/docs/DEVELOPER_GUIDE.md +++ b/docs/DEVELOPER_GUIDE.md @@ -284,8 +284,8 @@ permissions, bank, ranks, pickers) in `guis/common`, and feature menus in `guis/ - **Say what a button costs.** A button that spends money shows its price in its lore: take the amount from [`Prices`](UTILITY_GUIDE.md#prices) and turn it into a line with `costLine` / `priceLine`, so the figure is the server's own and not a guess. -- **Lay every icon's lore out in the same blocks.** A tooltip reads name — description — data — actions. Everything - an icon says about clicking goes in the `actions` argument of an `Icons` builder (or `loreActions` in the `itemStack` +- **Lay every icon's lore out in the same blocks.** A tooltip reads name — description — data — actions. Everything an + icon says about clicking goes in the `actions` argument of an `Icons` builder (or `loreActions` in the `itemStack` DSL), never among its data lines. Never hand-roll the spacing between blocks. See [Icons](#icons). - **Keep an empty row above the bottom row.** The back button, tutorial button, and page controls sit in the bottom row; leave the row above it empty so they stand apart from the menu's content. Only grids that need every row, such as the @@ -364,7 +364,7 @@ override fun entries(): List = | `BankMenu` | Deposit, withdraw, and bank history for a town or nation. | | `BankAmountMenu` | Picks how much to deposit or withdraw: the `bank-amounts` presets, everything, or a typed figure. Amounts Towny would refuse say why instead of offering a click. | | `RankMenu` | Grants or revokes town or nation ranks, checking the per-rank permission node. | -| `Pickers` | Selection menus for online residents, towns, nations, and fixed options. `option` takes a `lines` lambda for per-option lore, such as what picking that option costs. | +| `Pickers` | Selection menus for online residents, towns, nations, and fixed options. `option` takes a `lines` lambda for per-option lore, such as what picking that option costs. | ### Tutorial (`guis/tutorial`) @@ -485,8 +485,8 @@ Two rules keep new icons in line with the rest: block that turns out to be empty — so a conditional block never leaves a hole behind. A `""` is still fine *inside* the data lines to split one long list into two groups. -When you build an icon with `itemStack { }` directly — a sort button, a config entry — reach for the same blocks -through `loreWrapped(...)`, `loreBreak()`, and `loreActions(...)`. +When you build an icon with `itemStack { }` directly — a sort button, a config entry — reach for the same blocks through +`loreWrapped(...)`, `loreBreak()`, and `loreActions(...)`. ### Example: A New Menu diff --git a/docs/UTILITY_GUIDE.md b/docs/UTILITY_GUIDE.md index 8d32b0e..d7397ce 100644 --- a/docs/UTILITY_GUIDE.md +++ b/docs/UTILITY_GUIDE.md @@ -141,24 +141,24 @@ prompt(tr("bank.deposit-title"), tr("common.amount")) { amount -> ## Prices -`Prices` answers "what will this button cost?" so an icon can say so before the player clicks. Every amount is read -from Towny's config and from the town or nation involved — never a fixed default — so it matches what the command -would actually take, and everything returns `0` without an economy. - -| Method | Description | -|:--------------------------------------|:--------------------------------------------------------------------------------------| -| `claim(Town, count)` | What claiming `count` chunks costs the town, at its current rising claim price | -| `outpost()` | What claiming an outpost costs | -| `unclaimRefund()` | What a town gets back per unclaimed chunk; negative when unclaiming costs instead | -| `plotType(String, count)` | What setting `count` plots to a plot type costs (`reset` prices the default type) | -| `merge(remaining, succumbing)` | What merging the second town into the first costs, before any debt it takes on | -| `townSpawn(Player, Town, outpost)` | What travelling to a town's spawn or outpost costs this player | -| `nationSpawn(Player, Nation)` | What travelling to a nation's spawn costs this player | -| `residentSpawn(Player)` | What `/resident spawn` costs — Towny prices it as a trip home | - -Spawn travel is not a single config value: Towny prices it by the traveller's relationship to the destination (own -town, nation member, ally, outsider) and caps it at the server's price for that relationship, so a visitor and a -resident see different numbers. `Prices` mirrors that, including the free-spawn admin permissions. +`Prices` answers "what will this button cost?" so an icon can say so before the player clicks. Every amount is read from +Towny's config and from the town or nation involved — never a fixed default — so it matches what the command would +actually take, and everything returns `0` without an economy. + +| Method | Description | +|:-----------------------------------|:----------------------------------------------------------------------------------| +| `claim(Town, count)` | What claiming `count` chunks costs the town, at its current rising claim price | +| `outpost()` | What claiming an outpost costs | +| `unclaimRefund()` | What a town gets back per unclaimed chunk; negative when unclaiming costs instead | +| `plotType(String, count)` | What setting `count` plots to a plot type costs (`reset` prices the default type) | +| `merge(remaining, succumbing)` | What merging the second town into the first costs, before any debt it takes on | +| `townSpawn(Player, Town, outpost)` | What travelling to a town's spawn or outpost costs this player | +| `nationSpawn(Player, Nation)` | What travelling to a nation's spawn costs this player | +| `residentSpawn(Player)` | What `/resident spawn` costs — Towny prices it as a trip home | + +Spawn travel is not a single config value: Towny prices it by the traveller's relationship to the destination (own town, +nation member, ally, outsider) and caps it at the server's price for that relationship, so a visitor and a resident see +different numbers. `Prices` mirrors that, including the free-spawn admin permissions. Turn an amount into lore with `Menu.costLine` / `Menu.priceLine` rather than formatting it by hand: From 18c8a1b62601bfa08228f732c5fd5837e1fa7424 Mon Sep 17 00:00:00 2001 From: Trilleo Date: Sat, 19 Sep 2026 20:52:43 +0800 Subject: [PATCH 2/6] Backend: Update Minecraft to 26.3 --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 8ea73f2..ccfed6b 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -27,7 +27,7 @@ val serverPlugins: Configuration by configurations.creating { } dependencies { - compileOnly("io.papermc.paper:paper-api:26.2.build.+") + compileOnly("io.papermc.paper:paper-api:26.3.build.+") compileOnly("com.palmergames.bukkit.towny:towny:${providers.gradleProperty("towny_version").get()}") serverPlugins("com.palmergames.bukkit.towny:towny:${providers.gradleProperty("towny_version").get()}") testImplementation(kotlin("test")) From a2f028f4d597ac1f4328868fa9385c546335050e Mon Sep 17 00:00:00 2001 From: Trilleo Date: Sat, 19 Sep 2026 20:53:41 +0800 Subject: [PATCH 3/6] Fix: Change wrong Minecraft version reference in build.gradle.kts --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index ccfed6b..765c609 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -91,7 +91,7 @@ tasks.register("startServer") { workingDir(layout.projectDirectory.dir("run")) classpath(fileTree(layout.projectDirectory.dir("run")) { include("paper-*.jar") }) doFirst { - check(!classpath.isEmpty) { "No paper-*.jar in run/. Download Paper 26.2 from https://papermc.io/downloads/paper into run/." } + check(!classpath.isEmpty) { "No paper-*.jar in run/. Download Paper 26.3 from https://papermc.io/downloads/paper into run/." } } args("--nogui") standardInput = System.`in` From 9421d10bbdb5a756d7f3b4699f4973fbfb146874 Mon Sep 17 00:00:00 2001 From: Trilleo Date: Mon, 21 Sep 2026 19:19:51 +0800 Subject: [PATCH 4/6] Improvement: Revamp lore formation for better visuals --- CHANGELOG.md | 38 + CLAUDE.md | 37 +- README.md | 4 +- docs/DEVELOPER_GUIDE.md | 59 +- docs/UTILITY_GUIDE.md | 8 +- .../plugins/townymenu/guis/LeaderboardMenu.kt | 43 +- .../mc/plugins/townymenu/guis/MainMenu.kt | 51 +- .../mc/plugins/townymenu/guis/MapMenu.kt | 15 +- .../plugins/townymenu/guis/admin/AdminMenu.kt | 39 +- .../townymenu/guis/admin/AdminNamesMenu.kt | 5 +- .../townymenu/guis/admin/AdminNationMenu.kt | 45 +- .../guis/admin/AdminNationToolsMenu.kt | 19 +- .../guis/admin/AdminPermGroupMenu.kt | 5 +- .../townymenu/guis/admin/AdminPermsMenu.kt | 11 +- .../townymenu/guis/admin/AdminPlotMenu.kt | 23 +- .../townymenu/guis/admin/AdminRanksMenu.kt | 12 +- .../guis/admin/AdminResidentListMenu.kt | 5 +- .../townymenu/guis/admin/AdminResidentMenu.kt | 29 +- .../townymenu/guis/admin/AdminServerMenu.kt | 39 +- .../townymenu/guis/admin/AdminTownMenu.kt | 64 +- .../guis/admin/AdminTownToolsMenu.kt | 31 +- .../townymenu/guis/admin/AdminWorldMenu.kt | 13 +- .../guis/admin/PluginSettingsMenu.kt | 6 +- .../townymenu/guis/admin/TownyConfigMenu.kt | 16 +- .../townymenu/guis/common/BankAmountMenu.kt | 2 +- .../plugins/townymenu/guis/common/BankMenu.kt | 2 +- .../townymenu/guis/common/PermissionMenu.kt | 14 +- .../townymenu/guis/common/ToggleMenu.kt | 10 +- .../plugins/townymenu/guis/framework/Icons.kt | 6 +- .../plugins/townymenu/guis/framework/Menu.kt | 49 +- .../townymenu/guis/framework/PagedMenu.kt | 24 +- .../townymenu/guis/nation/NationInfoMenu.kt | 24 +- .../townymenu/guis/nation/NationListMenu.kt | 10 +- .../townymenu/guis/nation/NationMenu.kt | 44 +- .../guis/nation/NationRelationsMenu.kt | 11 +- .../guis/nation/NationSanctionsMenu.kt | 7 +- .../guis/nation/NationSettingsMenu.kt | 28 +- .../townymenu/guis/nation/NationStatusMenu.kt | 25 +- .../townymenu/guis/nation/NationTownsMenu.kt | 13 +- .../townymenu/guis/nation/NoNationMenu.kt | 11 +- .../townymenu/guis/plot/PlotAreaMenu.kt | 27 +- .../townymenu/guis/plot/PlotGroupMenu.kt | 35 +- .../plugins/townymenu/guis/plot/PlotMenu.kt | 98 +- .../townymenu/guis/plot/PlotOverridesMenu.kt | 15 +- .../townymenu/guis/plot/PlotTrustMenu.kt | 12 +- .../townymenu/guis/resident/FriendsMenu.kt | 10 +- .../townymenu/guis/resident/ResidentMenu.kt | 40 +- .../guis/resident/ResidentPlotsMenu.kt | 2 +- .../guis/resident/ResidentProfileMenu.kt | 29 +- .../townymenu/guis/town/JailSentenceMenu.kt | 15 +- .../plugins/townymenu/guis/town/NoTownMenu.kt | 14 +- .../townymenu/guis/town/OutlawsMenu.kt | 10 +- .../townymenu/guis/town/OutpostsMenu.kt | 2 +- .../townymenu/guis/town/TownClaimsMenu.kt | 44 +- .../townymenu/guis/town/TownInfoMenu.kt | 33 +- .../townymenu/guis/town/TownJailMenu.kt | 8 +- .../townymenu/guis/town/TownListMenu.kt | 10 +- .../townymenu/guis/town/TownMembersMenu.kt | 19 +- .../plugins/townymenu/guis/town/TownMenu.kt | 62 +- .../townymenu/guis/town/TownSettingsMenu.kt | 42 +- .../townymenu/guis/town/TownStatusMenu.kt | 13 +- .../townymenu/guis/town/TownTrustMenu.kt | 19 +- .../guis/tutorial/TutorialChapterMenu.kt | 10 +- .../townymenu/guis/tutorial/TutorialMenu.kt | 12 +- .../plugins/townymenu/utils/ItemStackDSL.kt | 4 +- src/main/resources/lang/en_US.yml | 1110 ++++++++-------- src/main/resources/lang/zh_CN.yml | 1123 +++++++++-------- 67 files changed, 2300 insertions(+), 1415 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 50d8541..bb39be5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,44 @@ ## Unreleased +### Improvements + +#### Menus + ++ Every menu has a new look inspired by Hypixel SkyBlock. Values are coloured by what they are — money in gold, counts + in green, dates and times in yellow, nations in aqua, anything dangerous in red — and descriptions and tutorial lessons + pick out their key terms, such as PvP, spawns, outposts, and upkeep, in the same colours everywhere. ++ Every button now tells you what clicking it does, in lines like "Click to open!", "Left-click to edit!", and + "Right-click to clear!": yellow for a click or left-click, aqua for a right-click, and red when the click deletes or + removes something. Buttons that did two things by button, such as editing or clearing a board, used to explain it in + their description; the hints now sit in their own block at the bottom. ++ Switches show a bold ENABLED or DISABLED status and say "Click to enable!" or "Click to disable!" instead of "Click + to toggle", and permission cells say "Click to allow!" or "Click to deny!". ++ Progress bars show how far along you are: claims used against the claim limit, outposts, progress towards the next + town or nation level, and lessons read in the tutorial. ++ Menus have a black glass background so the icons stand out, the back button is now "Go Back" and names the menu it + returns to, and page arrows name the page they lead to. ++ Leaderboards mark the top three with gold, silver, and bronze ranks, sort buttons point at the current order with an + aqua arrow, and lists of pending invites use bullet points. ++ Server owners who edited their language files in `plugins/TownyMenu/lang/` keep their own text and colours. To get + the new look, move your edits aside and let TownyMenu copy the new files on the next start; the header of + `en_US.yml` lists the colour palette. + +#### Misc + ++ The sort button in the town and nation directories now goes both ways: left-click moves to the next sort order and + right-click goes back to the previous one, so you no longer have to click all the way around to reach the order you + just passed. + +### Technical Details + +#### Misc + ++ TownyMenu now builds against Minecraft 26.3 (Paper API 26.3). Run it on a Paper 26.3 server. ++ Menus gain `hints(...)` for click hints from the new shared `click.*` translation keys, `progressBar(current, max)`, + `pageArrow(...)`, and a public `title`. The old `common.click-*` keys, `icon.currently`, and `icon.click-toggle` are + gone; the developer guide documents the click-hint rules and the colour palette. + ## Version 1.0.2 ### New Features diff --git a/CLAUDE.md b/CLAUDE.md index 298d0ed..6457115 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -4,7 +4,7 @@ TownyMenu is a Minecraft Paper plugin that adds a GUI layer on top of [Towny](https://github.com/TownyAdvanced/Towny): players manage their town, nation, and plots through inventory menus instead of typing Towny commands. It targets -Minecraft 26.2 (Paper API 26.2), hard-depends on Towny, and is written in Kotlin. [README.md](README.md) has the +Minecraft 26.3 (Paper API 26.3), hard-depends on Towny, and is written in Kotlin. [README.md](README.md) has the player-facing overview. ## Tech Stack @@ -13,7 +13,7 @@ player-facing overview. |:---------------|:-------------------------------------------------| | Language | Kotlin 2.3.10 | | Build | Gradle 9.7.1 (Kotlin DSL) | -| Platform | Paper API 26.2 (MC 26.2) | +| Platform | Paper API 26.3 (MC 26.3) | | Towny | 0.103.2.7 (`towny_version` in gradle.properties) | | Java toolchain | JDK 25 | @@ -41,7 +41,8 @@ Before finishing any task that changes the plugin, do all of the following: 3. **Translate every new string** — player-facing text never lives in Kotlin. Add each key to **both** [en_US.yml](src/main/resources/lang/en_US.yml) and [zh_CN.yml](src/main/resources/lang/zh_CN.yml) in the same task, - with a real Simplified Chinese translation, and remove keys the change no longer uses. `LangFilesTest` fails the + with a real Simplified Chinese translation coloured the same way as the English (see the colour palette under + Translations), and remove keys the change no longer uses. `LangFilesTest` fails the build when the files disagree or a key is missing or unused. See the Translations section below. 4. **Check the README** — if the change affects anything [README.md](README.md) mentions (features, commands, @@ -57,7 +58,7 @@ Before finishing any task that changes the plugin, do all of the following: The local test server lives in `run/` (gitignored). `copyPlugin` deletes every `TownyMenu-*.jar` and `towny-*.jar` already in `run/plugins/` before copying, so a version bump never leaves two copies for Bukkit to load. It puts the -matching Towny jar there too, but the Paper 26.2 jar (`run/paper-*.jar`) must be downloaded by hand +matching Towny jar there too, but the Paper 26.3 jar (`run/paper-*.jar`) must be downloaded by hand from https://papermc.io/downloads/paper, and `eula.txt` accepted, before `startServer` works. The server console reads commands from the terminal running Gradle. @@ -122,11 +123,24 @@ Extend `Menu` (or `PagedMenu` for lists) and implement `build()`, which runs on - **Lay every icon's lore out in the same blocks** — a tooltip reads name → description → data → actions, and a new icon follows that order or it looks out of place beside the others. With an `Icons` builder the description is the `description` argument, the data and cost lines are the `extra` varargs, and everything about clicking is - `actions = listOf(...)`; with `itemStack { }` directly, use `loreWrapped(...)`, `loreBreak()` between data blocks, and + `actions = hints(...)`; with `itemStack { }` directly, use `loreWrapped(...)`, `loreBreak()` between data blocks, and `loreActions(...)` to close. Never hand-roll the spacing: no `""` lore line to separate blocks, no divider drawn by hand, no blank line under the name — `LoreBlocks` adds all three, collapses repeats, and trims a block that turns out empty. The mistake to watch for is a click hint left among the data lines; it belongs in `actions`, which is what puts it below the divider. See [The shape of an icon](docs/DEVELOPER_GUIDE.md#the-shape-of-an-icon). +- **Tell the player what every click does** — a clickable icon gets a SkyBlock-style hint ending in `!`, taken from the + shared `click.*` keys with `hints(...)` (`actions = hints("click.open")`) or a menu-specific key in the same colours: + yellow for a click or left-click, aqua for a right-click, red when it deletes or removes something. A button that + acts differently per mouse button lists one hint per button, left first (`hints("click.edit", "click.clear")`), and + its description never explains the clicks. An on/off setting uses `Icons.toggle`, which writes its own + ENABLED/DISABLED status and "Click to enable!"/"Click to disable!" hint. Only purely informational icons go without a + hint. See [Click hints](docs/DEVELOPER_GUIDE.md#click-hints). +- **Show progress as a bar** — any "used of limit" or "towards the next level" figure gets a `progressBar(current, max)` + line under its number, and none when the limit is zero or unlimited. +- **Use the framework's chrome, never your own** — `backButton(slot)` (a "Go Back" arrow naming the parent menu), + `pageArrow(...)` for hand-paged menus, `tutorialButton(...)`, and the black glass filler `render()` lays down. Lists of + names inside lore use `common.list-entry` (`• name`). No colour tags in Kotlin, not even for a selection marker: add a + translation key (as `sort.selected` / `sort.option` do). ## Translations @@ -135,6 +149,19 @@ Extend `Menu` (or `PagedMenu` for lists) and implement `build()`, which runs on falling back to `en_US`. - Values are MiniMessage with `{placeholder}` arguments. Arguments are inserted verbatim, so escape player-written text with `TownyUtil.name()` / `TownyUtil.text()` first. Colours belong in the translation, not in Kotlin. +- **Every new string follows the [colour palette](docs/DEVELOPER_GUIDE.md#colour-palette)** (Hypixel SkyBlock style), + in both languages: + - Labels and descriptions ``; the value after a label takes its kind's colour — `` money and town + names, `` nations, `` counts, `` dates and times, `` player names and other neutral + values, `` a count that is bad news (outlaws, prisoners). A ratio greys its slash: + `"Claims: {claims}/{max}"`. + - A description highlights one to three key terms, closing each tag so the grey resumes, and a term always gets + the same colour: `` danger (PvP, enemies, outlaws, jail, debt, ruins, "permanently"), `` money and + leadership (bank, taxes, upkeep, price, mayor, capital, home block), `` land and friendship (claims, + chunks, plots, land, allies, friends, trust), `` spawns, outposts, teleports, `` nation zone, + `` menu and button names. Example: `"Teleport to your town spawn."` + - Click hints end in `!` (Chinese `!`, `点击…!` / `左键…!` / `右键…!`) and are coloured by button as above. + - `command.*` help text stays plain: no tags. - Keys are grouped by menu (`town.*`, `plot-group.*`); reuse `common.*`, `toggle.*`, and `icon.*` for shared text. - Key names must appear as whole string literals (`tr(if (on) "a.on" else "a.off")`, not `"a.$state"`) so `LangFilesTest` can see them. The only runtime-built keys are `plot-type.*` and `command.*`. diff --git a/README.md b/README.md index 22e97fe..eb6b74f 100644 --- a/README.md +++ b/README.md @@ -58,7 +58,7 @@ | Dependency | Version | |:-----------|:-----------| -| Paper | 26.2+ | +| Paper | 26.3+ | | Java | 25+ | | Towny | 0.103.2.7+ | @@ -72,7 +72,7 @@ TownyMenu is an addon: Towny must be installed on the server, or TownyMenu will The compiled JAR is placed in `build/libs/`. Run `./gradlew copyPlugin` to copy it, along with the matching Towny jar, into `run/plugins/` for the local test server — any older copy of either is deleted first — or `./gradlew startServer` -to copy them and start the server. Before the first start, download a Paper 26.2 jar +to copy them and start the server. Before the first start, download a Paper 26.3 jar from [papermc.io](https://papermc.io/downloads/paper) into `run/`, then accept the EULA in `run/eula.txt` after the first launch. diff --git a/docs/DEVELOPER_GUIDE.md b/docs/DEVELOPER_GUIDE.md index ffe7249..169ae31 100644 --- a/docs/DEVELOPER_GUIDE.md +++ b/docs/DEVELOPER_GUIDE.md @@ -287,6 +287,14 @@ permissions, bank, ranks, pickers) in `guis/common`, and feature menus in `guis/ - **Lay every icon's lore out in the same blocks.** A tooltip reads name — description — data — actions. Everything an icon says about clicking goes in the `actions` argument of an `Icons` builder (or `loreActions` in the `itemStack` DSL), never among its data lines. Never hand-roll the spacing between blocks. See [Icons](#icons). +- **Every clickable icon says what a click does.** Give it a hint from the shared `click.*` keys with `hints(...)` + (`actions = hints("click.open")`), or a menu-specific one when no shared hint fits. See + [Click hints](#click-hints). +- **Show progress as a bar.** A "used of limit" or "towards the next level" figure gets a `progressBar(current, max)` + line under it, and none when the limit is zero or unlimited. +- **Use the framework's chrome.** `backButton`, `pageArrow`, `tutorialButton`, and the black filler `render()` lays + down; never a hand-built arrow or pane. Lists of names in lore use `common.list-entry`, and even a selection marker + comes from a translation key rather than a colour tag in Kotlin. - **Keep an empty row above the bottom row.** The back button, tutorial button, and page controls sit in the bottom row; leave the row above it empty so they stand apart from the menu's content. Only grids that need every row, such as the chunk map and the 4×4 permission grid, skip it. @@ -305,19 +313,24 @@ open inventory's holder — there is no registry and nothing to clean up when a |:-----------------------------------------|:---------------------------------------------------------------------------------| | `build()` | Abstract. Place items and click actions. Called on every `render()`. | | `open()` | Renders and opens the menu, or re-renders in place if it is already open. | -| `render()` | Clears the inventory (grey filler) and calls `build()`. | +| `render()` | Clears the inventory (black glass filler) and calls `build()`. | | `button(slot, item, action?)` | Places an item; `action` receives the `ClickType`. | | `guarded(slot, node, item, action)` | Like `button`, but shows a grey "no permission" icon without `node`. | | `layout(vararg slots)` | Fills slots in order, for optional buttons; extra buttons are logged, skipped. | -| `backButton(slot)` | Back arrow to `back`, or a close button when `back` is `null`. | +| `backButton(slot)` | "Go Back" arrow naming `back`'s title, or a close button when `back` is `null`. | +| `pageArrow(previous, target, pages)` | A page-turning arrow naming the page it leads to, for menus that page by hand. | | `tutorialButton(slot, chapter)` | Help button opening the tutorial `Chapter` that explains this menu. | +| `list.cycle(current, click)` | Next option on a left click, previous on a right; hint `click.next`/`previous`. | | `costLine(amount)` | A `Cost: …` lore line, or `null` without an economy or when the action is free. | | `priceLine(amount)` | A `Price: …` lore line for something on sale; a price of zero is still shown. | +| `progressBar(current, max)` | A progress bar lore line with its percentage; a `max` of 0 or less reads full. | +| `hints(vararg keys)` | The translated click hints for `keys`, ready for an icon's `actions`. | | `run(command, probe?, returnTo?, delay)` | Runs a Towny command as the player (see below). | | `runAndClose(command)` | Closes the menu, then runs the command (teleports, books, chat output). | | `prompt(title, label, …) { text -> }` | Shows a text-input dialog; Cancel or empty input reopens the menu. | | `tr(key, "name" to value, …)` | Translates `key` into the viewer's language (see [Translations](#translations)). | | `resident` | The viewer's Towny `Resident`, or `null`. | +| `title` | The translated title, which a child menu's back button names. | ### Running Commands: `MenuActions` @@ -347,7 +360,7 @@ visible page are built: ```kotlin override fun entries(): List = town.residents.map { member -> - MenuEntry({ Icons.resident(player, member, actions = listOf(tr("common.click-view"))) }) { + MenuEntry({ Icons.resident(player, member, actions = hints("click.view")) }) { ResidentProfileMenu(player, member, this).open() } } @@ -453,13 +466,13 @@ place beside the others: | **Name** | `name` | What the button is, one translated line. | | **Description** | `description` (wrapped) | What it does, a sentence or two; `null` when the name says it. | | **Data** | the `extra` varargs | Current values, counts, and the `costLine` / `priceLine` line. | -| **Actions** | `actions = listOf(...)` | What a left- or right-click does, and nothing else. | +| **Actions** | `actions = hints(...)` | What a left- or right-click does, and nothing else. | ```kotlin Icons.icon( Material.ENDER_PEARL, tr("town.spawn"), tr("town.spawn-description"), *listOfNotNull(costLine(Prices.townSpawn(player, town))).toTypedArray(), - actions = listOf(tr("common.click-teleport")) + actions = hints("click.teleport") ) ``` @@ -470,11 +483,20 @@ Teleport to your town's spawn point. <- description <- added for you Cost: $25 <- extra ------------------------------ <- added for you -Click to teleport <- actions +Click to teleport! <- actions ``` `toggle`, `resident`, `town`, and `nation` follow the same order and take the same `actions` argument; they fill the -data block themselves from Towny and put the caller's extra lines in a block of their own below it. +data block themselves from Towny and put the caller's extra lines in a block of their own below it. `toggle` writes its +own hint: its status line reads `ENABLED` or `DISABLED`, and the hint says what a click switches it to. + +#### Click hints + +Click hints follow Hypixel SkyBlock's style: a short sentence ending in `!`, coloured by the mouse button — yellow for a +click or left-click, aqua for a right-click, red when the click deletes, removes, or gives something up. The shared +hints live under `click.*` (`click.open`, `click.view`, `click.teleport`, `click.edit` + `click.clear`, `click.delete`, +…); `hints("click.edit", "click.clear")` turns keys into the list `actions` expects. A button with a left and a right +action lists both, left first. Menu-specific hints (`invites.left-accept`) follow the same colours. Two rules keep new icons in line with the rest: @@ -575,7 +597,7 @@ bank: deposit-description: "Move money from your balance into the bank." ``` -- **Colours go in the translation**, so translators see the whole line. +- **Colours go in the translation**, so translators see the whole line. Follow the palette below. - **Placeholders are inserted verbatim.** Escape player-written text with `TownyUtil.name()` / `TownyUtil.text()`. - **Group keys by menu** (`town-details.*`) and reuse `common.*`, `icon.*`, and `toggle.*` for shared text. - **Write keys as whole string literals.** `tr(if (held) "rank.assigned" else "rank.not-assigned")` is fine; @@ -583,6 +605,27 @@ bank: runtime-built keys (read with `Lang.find`, which returns `null` instead of the key). - **Quote YAML keys that YAML 1.1 reads as booleans**: `"on"`, `"off"`, `"yes"`, `"no"`. +### Colour Palette + +Every language file uses one palette, so the same kind of text looks the same in every menu. The header of `en_US.yml` +repeats it for server owners. + +| Colour | Used for | +|:-----------------|:--------------------------------------------------------------------------| +| `` | Labels (`Balance:`) and descriptions. | +| `` | Neutral values: player names, locations, plot types, free text. | +| `` | Money and prices, town names, leadership (mayor, capital, home block). | +| `` | Nation names and nation-wide things (nation zone). | +| `` | Counts, land and plots, allies, friends, trust, "on". | +| `` | Dates and times, menu and button names mentioned in text, click hints. | +| `` | Spawns, outposts, and teleports. | +| `` | Danger: PvP, enemies, outlaws, jail, debt, ruins, anything permanent. | + +A description stays grey and picks out one to three key terms in their colour, closing each tag so the grey resumes: +`"Teleport to your town spawn."`. A value line colours only the value: +`"Balance: {balance}"`, and a ratio greys its slash: `"{claims}/{max}"`. Lists use +`common.list-entry` (`• name`) and progress uses `Menu.progressBar`. + ### LangFilesTest `./gradlew build` runs `LangFilesTest`, which fails when: diff --git a/docs/UTILITY_GUIDE.md b/docs/UTILITY_GUIDE.md index d7397ce..cd0ad05 100644 --- a/docs/UTILITY_GUIDE.md +++ b/docs/UTILITY_GUIDE.md @@ -27,10 +27,10 @@ import net.trilleo.mc.plugins.townymenu.utils.itemStack val icon = itemStack(Material.EMERALD) { name("Deposit") - loreWrapped("Move money from your balance into the town bank.") + loreWrapped("Move money from your balance into the town bank.") loreBreak() - lore("Balance: $120") - loreActions(listOf("Click to deposit")) + lore("Balance: $120") + loreActions(listOf("Click to deposit!")) glow(true) } ``` @@ -334,7 +334,7 @@ import net.trilleo.mc.plugins.townymenu.utils.itemStack val item = itemStack(Material.BELL) { name("Town Settings") loreWrapped("PvP, mobs, fire, explosions, and whether the town is open to new residents.") - loreActions(listOf("Click to open")) + loreActions(listOf("Click to open!")) } ``` diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/LeaderboardMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/LeaderboardMenu.kt index f546d22..df44a79 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/LeaderboardMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/LeaderboardMenu.kt @@ -40,7 +40,10 @@ class LeaderboardMenu(player: Player, back: Menu) : Menu(player, player.tr("lead val row = layout(19, 20, 21, 22, 23, 24, 25, 28, 29, 30, 31, 32, 33, 34) row.add( PermissionNodes.TOWNY_COMMAND_TOWNY_TOP_RESIDENTS, - Icons.icon(Material.BELL, tr("leaderboard.town-residents"), tr("leaderboard.town-residents-description")) + Icons.icon( + Material.BELL, tr("leaderboard.town-residents"), tr("leaderboard.town-residents-description"), + actions = hints("click.view") + ) ) { townList(tr("leaderboard.town-residents")) { it.numResidents to tr( @@ -54,7 +57,8 @@ class LeaderboardMenu(player: Player, back: Menu) : Menu(player, player.tr("lead Icons.icon( Material.BEACON, tr("leaderboard.nation-residents"), - tr("leaderboard.nation-residents-description") + tr("leaderboard.nation-residents-description"), + actions = hints("click.view") ) ) { nationList(tr("leaderboard.nation-residents")) { @@ -66,7 +70,10 @@ class LeaderboardMenu(player: Player, back: Menu) : Menu(player, player.tr("lead } row.add( PermissionNodes.TOWNY_COMMAND_TOWNY_TOP_LAND, - Icons.icon(Material.GRASS_BLOCK, tr("leaderboard.town-land"), tr("leaderboard.town-land-description")) + Icons.icon( + Material.GRASS_BLOCK, tr("leaderboard.town-land"), tr("leaderboard.town-land-description"), + actions = hints("click.view") + ) ) { townList(tr("leaderboard.town-land")) { it.numTownBlocks to tr( @@ -78,7 +85,10 @@ class LeaderboardMenu(player: Player, back: Menu) : Menu(player, player.tr("lead } row.add( PermissionNodes.TOWNY_COMMAND_TOWNY_TOP_LAND, - Icons.icon(Material.OAK_SIGN, tr("leaderboard.resident-land"), tr("leaderboard.resident-land-description")) + Icons.icon( + Material.OAK_SIGN, tr("leaderboard.resident-land"), tr("leaderboard.resident-land-description"), + actions = hints("click.view") + ) ) { residentList( tr("leaderboard.resident-land"), @@ -91,7 +101,8 @@ class LeaderboardMenu(player: Player, back: Menu) : Menu(player, player.tr("lead Icons.icon( Material.GOLD_INGOT, tr("leaderboard.town-balance"), - tr("leaderboard.town-balance-description") + tr("leaderboard.town-balance-description"), + actions = hints("click.view") ) ) { townList(tr("leaderboard.town-balance")) { @@ -106,7 +117,8 @@ class LeaderboardMenu(player: Player, back: Menu) : Menu(player, player.tr("lead Icons.icon( Material.GOLD_BLOCK, tr("leaderboard.nation-balance"), - tr("leaderboard.nation-balance-description") + tr("leaderboard.nation-balance-description"), + actions = hints("click.view") ) ) { nationList(tr("leaderboard.nation-balance")) { @@ -121,7 +133,8 @@ class LeaderboardMenu(player: Player, back: Menu) : Menu(player, player.tr("lead row.add( Icons.icon( Material.EMERALD, tr("leaderboard.town-baltop"), - tr("leaderboard.town-baltop-description", "town" to TownyUtil.name(town.name)) + tr("leaderboard.town-baltop-description", "town" to TownyUtil.name(town.name)), + actions = hints("click.view") ) ) { residentList(tr("leaderboard.town-baltop"), town.residents, limit = false) @@ -133,7 +146,8 @@ class LeaderboardMenu(player: Player, back: Menu) : Menu(player, player.tr("lead PermissionNodes.TOWNY_COMMAND_NATION_BALTOP, Icons.icon( Material.EMERALD_BLOCK, tr("leaderboard.nation-baltop"), - tr("leaderboard.nation-baltop-description", "nation" to TownyUtil.name(nation.name)) + tr("leaderboard.nation-baltop-description", "nation" to TownyUtil.name(nation.name)), + actions = hints("click.view") ) ) { residentList(tr("leaderboard.nation-baltop"), nation.residents, limit = false) @@ -145,7 +159,12 @@ class LeaderboardMenu(player: Player, back: Menu) : Menu(player, player.tr("lead backButton(49) } - private fun rank(index: Int) = tr("leaderboard.rank", "rank" to index + 1) + private fun rank(index: Int) = when (index) { + 0 -> tr("leaderboard.rank-first") + 1 -> tr("leaderboard.rank-second") + 2 -> tr("leaderboard.rank-third") + else -> tr("leaderboard.rank", "rank" to index + 1) + } /** Opens [towns] ranked by the first value of [score], showing its second value as a lore line. */ private fun > townList(title: String, score: (Town) -> Pair) = @@ -155,7 +174,7 @@ class LeaderboardMenu(player: Player, back: Menu) : Menu(player, player.tr("lead MenuEntry({ Icons.town( player, town, rank(index), value.second, - actions = listOf(tr("common.click-details")) + actions = listOf(tr("click.details")) ) }) { TownInfoMenu(player, town, menu).open() @@ -170,7 +189,7 @@ class LeaderboardMenu(player: Player, back: Menu) : Menu(player, player.tr("lead MenuEntry({ Icons.nation( player, nation, rank(index), value.second, - actions = listOf(tr("common.click-details")) + actions = listOf(tr("click.details")) ) }) { NationInfoMenu(player, nation, menu).open() @@ -197,7 +216,7 @@ class LeaderboardMenu(player: Player, back: Menu) : Menu(player, player.tr("lead MenuEntry({ Icons.resident( player, target, rank(index), value.second, - actions = listOf(tr("common.click-view")) + actions = listOf(tr("click.view")) ) }) { ResidentProfileMenu(player, target, menu).open() diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/MainMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/MainMenu.kt index 71ca2fb..5213510 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/MainMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/MainMenu.kt @@ -39,7 +39,10 @@ class MainMenu(player: Player) : Menu(player, player.tr("main.title"), 6) { TownMenu(player, this).open() } } else { - button(20, Icons.icon(Material.BELL, tr("main.town"), tr("main.town-none"))) { + button(20, Icons.icon( + Material.BELL, tr("main.town"), tr("main.town-none"), + actions = hints("click.open") + )) { NoTownMenu(player, this).open() } } @@ -52,7 +55,10 @@ class MainMenu(player: Player) : Menu(player, player.tr("main.title"), 6) { ).open() } - town != null -> button(22, Icons.icon(Material.BEACON, tr("main.nation"), tr("main.nation-none"))) { + town != null -> button(22, Icons.icon( + Material.BEACON, tr("main.nation"), tr("main.nation-none"), + actions = hints("click.open") + )) { NoNationMenu(player, this).open() } @@ -65,41 +71,60 @@ class MainMenu(player: Player) : Menu(player, player.tr("main.title"), 6) { Material.GRASS_BLOCK, tr("main.plot"), tr("main.plot-description"), tr( "main.plot-here", - "town" to (plot?.townOrNull?.let { TownyUtil.name(it.name) } ?: tr("main.wilderness"))))) { + "town" to (plot?.townOrNull?.let { TownyUtil.name(it.name) } ?: tr("main.wilderness"))), + actions = hints("click.open") + ) + ) { PlotMenu(player, this).open() } button( 28, Icons.icon( Material.CLOCK, tr("main.prices"), tr("main.prices-description"), - tr("town-status.new-day", "time" to TownyUtil.duration(player, TownyUtil.secondsUntilNewDay())) + tr("town-status.new-day", "time" to TownyUtil.duration(player, TownyUtil.secondsUntilNewDay())), + actions = hints("click.view") ) ) { PricesMenu(player, this).open() } - button(29, Icons.icon(Material.FILLED_MAP, tr("main.map"), tr("main.map-description"))) { + button(29, Icons.icon( + Material.FILLED_MAP, tr("main.map"), tr("main.map-description"), + actions = hints("click.open") + )) { MapMenu( player, this ).open() } - button(30, Icons.icon(Material.BELL, tr("main.towns"), tr("main.towns-description"))) { + button(30, Icons.icon( + Material.BELL, tr("main.towns"), tr("main.towns-description"), + actions = hints("click.browse") + )) { TownListMenu( player, this ).open() } - button(31, Icons.icon(Material.KNOWLEDGE_BOOK, tr("main.tutorial"), tr("main.tutorial-description"))) { + button(31, Icons.icon( + Material.KNOWLEDGE_BOOK, tr("main.tutorial"), tr("main.tutorial-description"), + actions = hints("click.open") + )) { TutorialMenu(player, this).open() } - button(32, Icons.icon(Material.BEACON, tr("main.nations"), tr("main.nations-description"))) { + button(32, Icons.icon( + Material.BEACON, tr("main.nations"), tr("main.nations-description"), + actions = hints("click.browse") + )) { NationListMenu( player, this ).open() } - button(34, Icons.icon(Material.LECTERN, tr("main.leaderboards"), tr("main.leaderboards-description"))) { + button(34, Icons.icon( + Material.LECTERN, tr("main.leaderboards"), tr("main.leaderboards-description"), + actions = hints("click.view") + )) { LeaderboardMenu(player, this).open() } @@ -108,14 +133,18 @@ class MainMenu(player: Player) : Menu(player, player.tr("main.title"), 6) { button( 33, Icons.icon( Material.PAPER, if (invites > 0) tr("main.invites-count", "count" to invites) else tr("main.invites"), - tr("main.invites-description") + tr("main.invites-description"), + actions = hints("click.view") ) ) { InvitesMenu(player, this).open() } if (player.hasPermission(AdminMenu.PERMISSION)) { - button(53, Icons.icon(Material.COMMAND_BLOCK, tr("main.admin"), tr("main.admin-description"))) { + button(53, Icons.icon( + Material.COMMAND_BLOCK, tr("main.admin"), tr("main.admin-description"), + actions = hints("click.open") + )) { AdminMenu( player, this diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/MapMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/MapMenu.kt index 9a5d3a8..9650267 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/MapMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/MapMenu.kt @@ -58,19 +58,28 @@ class MapMenu(player: Player, back: Menu?) : Menu(player, player.tr("map.title") val claims = { town.numTownBlocks } guarded( 47, PermissionNodes.TOWNY_COMMAND_TOWN_CLAIM_TOWN, - Icons.icon(Material.GRASS_BLOCK, tr("map.claim"), tr("map.claim-description")) + Icons.icon( + Material.GRASS_BLOCK, tr("map.claim"), tr("map.claim-description"), + actions = hints("click.claim") + ) ) { run("towny:town claim", claims, delayTicks = 20) } guarded( 48, PermissionNodes.TOWNY_COMMAND_TOWN_UNCLAIM, - Icons.icon(Material.COARSE_DIRT, tr("map.unclaim"), tr("map.unclaim-description")) + Icons.icon( + Material.COARSE_DIRT, tr("map.unclaim"), tr("map.unclaim-description"), + actions = hints("click.unclaim") + ) ) { run("towny:town unclaim", claims, delayTicks = 20) } } backButton(49) - button(50, Icons.icon(Material.CLOCK, tr("map.refresh"), tr("map.refresh-description"))) { render() } + button(50, Icons.icon( + Material.CLOCK, tr("map.refresh"), tr("map.refresh-description"), + actions = hints("click.refresh") + )) { render() } tutorialButton(53, Tutorial.GETTING_STARTED) } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminMenu.kt index d2d7352..71fc9af 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminMenu.kt @@ -26,34 +26,48 @@ class AdminMenu(player: Player, back: Menu?) : Menu(player, player.tr("admin.tit return backButton(40) } - button(10, Icons.icon(Material.COMPARATOR, tr("admin.config"), tr("admin.config-description"))) { + button(10, Icons.icon( + Material.COMPARATOR, tr("admin.config"), tr("admin.config-description"), + actions = hints("click.open") + )) { TownyConfigMenu(player, "", this).open() } button( 12, Icons.icon( Material.GRASS_BLOCK, tr("admin.worlds"), tr("admin.worlds-description"), - tr("admin.worlds-count", "count" to TownyUniverse.getInstance().townyWorlds.size) + tr("admin.worlds-count", "count" to TownyUniverse.getInstance().townyWorlds.size), + actions = hints("click.view") ) ) { worlds().open() } - button(14, Icons.icon(Material.COMMAND_BLOCK, tr("admin.server"), tr("admin.server-description"))) { + button(14, Icons.icon( + Material.COMMAND_BLOCK, tr("admin.server"), tr("admin.server-description"), + actions = hints("click.open") + )) { AdminServerMenu(player, this).open() } - button(16, Icons.icon(Material.WRITABLE_BOOK, tr("admin.plugin"), tr("admin.plugin-description"))) { + button(16, Icons.icon( + Material.WRITABLE_BOOK, tr("admin.plugin"), tr("admin.plugin-description"), + actions = hints("click.open") + )) { PluginSettingsMenu(player, this).open() } val towny = TownyAPI.getInstance() button( - 18, Icons.icon(Material.GRASS_BLOCK, tr("admin-plot.open"), tr("admin-plot.open-description")) + 18, Icons.icon( + Material.GRASS_BLOCK, tr("admin-plot.open"), tr("admin-plot.open-description"), + actions = hints("click.open") + ) ) { AdminPlotMenu(player, this).open() } button( 20, Icons.icon( Material.BELL, tr("admin.towns"), tr("admin.towns-description"), - tr("admin.count", "count" to towny.towns.size) + tr("admin.count", "count" to towny.towns.size), + actions = hints("click.browse") ) ) { lateinit var list: Menu @@ -69,7 +83,8 @@ class AdminMenu(player: Player, back: Menu?) : Menu(player, player.tr("admin.tit button( 22, Icons.icon( Material.BEACON, tr("admin.nations"), tr("admin.nations-description"), - tr("admin.count", "count" to towny.nations.size) + tr("admin.count", "count" to towny.nations.size), + actions = hints("click.browse") ) ) { lateinit var list: Menu @@ -85,13 +100,17 @@ class AdminMenu(player: Player, back: Menu?) : Menu(player, player.tr("admin.tit button( 24, Icons.icon( Material.PLAYER_HEAD, tr("admin.residents"), tr("admin.residents-description"), - tr("admin.count", "count" to towny.residents.size) + tr("admin.count", "count" to towny.residents.size), + actions = hints("click.browse") ) ) { AdminResidentListMenu(player, this).open() } - button(26, Icons.icon(Material.IRON_DOOR, tr("admin-perms.open"), tr("admin-perms.open-description"))) { + button(26, Icons.icon( + Material.IRON_DOOR, tr("admin-perms.open"), tr("admin-perms.open-description"), + actions = hints("click.open") + )) { AdminPermsMenu(player, this).open() } @@ -113,7 +132,7 @@ class AdminMenu(player: Player, back: Menu?) : Menu(player, player.tr("admin.tit tr("admin-world.using-towny", "value" to TownyUtil.yesNo(player, world.isUsingTowny)), tr("admin-world.towns", "count" to world.townsInWorld.size) ) - loreActions(listOf(tr("common.click-view"))) + loreActions(listOf(tr("click.view"))) glow(world.isUsingTowny) } } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminNamesMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminNamesMenu.kt index f1fa223..a226259 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminNamesMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminNamesMenu.kt @@ -44,7 +44,10 @@ class AdminNamesMenu( override fun controls() { guarded( 47, node, - Icons.icon(Material.NAME_TAG, tr("admin-tools.add"), tr("admin-tools.add-description")) + Icons.icon( + Material.NAME_TAG, tr("admin-tools.add"), tr("admin-tools.add-description"), + actions = hints("click.type-name") + ) ) { prompt(addTitle, addLabel) { name -> run("$command add ${TownyUtil.argument(name)}", ::count) diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminNationMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminNationMenu.kt index f5eb409..89f5778 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminNationMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminNationMenu.kt @@ -38,7 +38,10 @@ class AdminNationMenu(player: Player, private val nation: Nation, back: Menu) : grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_NATION_TOGGLE, - Icons.icon(Material.LEVER, tr("admin-nation.toggles"), tr("admin-nation.toggles-description")) + Icons.icon( + Material.LEVER, tr("admin-nation.toggles"), tr("admin-nation.toggles-description"), + actions = hints("click.open") + ) ) { toggles().open() } @@ -48,7 +51,8 @@ class AdminNationMenu(player: Player, private val nation: Nation, back: Menu) : Material.NAME_TAG, tr("admin.rename"), null, - tr("common.current", "value" to TownyUtil.name(nation.name)) + tr("common.current", "value" to TownyUtil.name(nation.name)), + actions = hints("click.rename") ) ) { prompt(tr("admin.rename"), tr("common.new-name"), initial = nation.name) { name -> @@ -59,7 +63,9 @@ class AdminNationMenu(player: Player, private val nation: Nation, back: Menu) : PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_NATION_SET, Icons.icon( Material.PLAYER_HEAD, tr("nation-details.leader"), tr("admin-nation.leader-description"), - tr("common.current", "value" to (nation.king?.let { TownyUtil.name(it.name) } ?: "-")))) { + tr("common.current", "value" to (nation.king?.let { TownyUtil.name(it.name) } ?: "-")), + actions = hints("click.choose-player") + )) { ListMenu(player, tr("nation-details.leader-title"), this) { nation.capital?.residents.orEmpty().filter { !it.isKing }.sortedBy { it.name.lowercase() } .map { candidate -> @@ -78,14 +84,19 @@ class AdminNationMenu(player: Player, private val nation: Nation, back: Menu) : PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_NATION_SET, Icons.icon( Material.GOLDEN_HELMET, tr("nation-details.capital"), null, - tr("common.current", "value" to (nation.capital?.let { TownyUtil.name(it.name) } ?: "-")))) { + tr("common.current", "value" to (nation.capital?.let { TownyUtil.name(it.name) } ?: "-")), + actions = hints("click.choose-town") + )) { townList(tr("nation-details.capital-title"), tr("nation-details.capital-click")) { town -> run("$command set capital ${town.name}", { nation.capital }, returnTo = this) } } grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_NATION_ADD, - Icons.icon(Material.LIME_DYE, tr("admin-nation.add"), tr("admin-nation.add-description")) + Icons.icon( + Material.LIME_DYE, tr("admin-nation.add"), tr("admin-nation.add-description"), + actions = hints("click.choose-town") + ) ) { Pickers.town(this, tr("admin-nation.add"), { !it.hasNation() }) { town -> run("$command add ${town.name}", { nation.numTowns }) @@ -95,7 +106,8 @@ class AdminNationMenu(player: Player, private val nation: Nation, back: Menu) : PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_NATION_KICK, Icons.icon( Material.IRON_BOOTS, tr("admin-nation.kick"), tr("admin-nation.kick-description"), - tr("admin-nation.towns", "count" to nation.numTowns) + tr("admin-nation.towns", "count" to nation.numTowns), + actions = hints("click.choose-town") ) ) { townList(tr("admin-nation.kick"), tr("picker.select")) { town -> @@ -110,7 +122,8 @@ class AdminNationMenu(player: Player, private val nation: Nation, back: Menu) : Material.EMERALD, tr("bank.deposit"), tr("admin.deposit-description"), - tr("bank.balance", "balance" to TownyUtil.balance(nation)) + tr("bank.balance", "balance" to TownyUtil.balance(nation)), + actions = hints("click.type-amount") ) ) { prompt(tr("bank.deposit-title"), tr("common.amount")) { amount -> @@ -123,7 +136,8 @@ class AdminNationMenu(player: Player, private val nation: Nation, back: Menu) : Material.REDSTONE, tr("bank.withdraw"), tr("admin.withdraw-description"), - tr("bank.balance", "balance" to TownyUtil.balance(nation)) + tr("bank.balance", "balance" to TownyUtil.balance(nation)), + actions = hints("click.type-amount") ) ) { prompt(tr("bank.withdraw-title"), tr("common.amount")) { amount -> @@ -132,7 +146,10 @@ class AdminNationMenu(player: Player, private val nation: Nation, back: Menu) : } grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_NATION_BANKHISTORY, - Icons.icon(Material.WRITTEN_BOOK, tr("bank.history"), tr("bank.history-description")) + Icons.icon( + Material.WRITTEN_BOOK, tr("bank.history"), tr("bank.history-description"), + actions = hints("click.view") + ) ) { runAndClose("$command bankhistory") } @@ -140,13 +157,19 @@ class AdminNationMenu(player: Player, private val nation: Nation, back: Menu) : grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_NATION_DELETE, - Icons.icon(Material.TNT, tr("admin-nation.delete"), tr("admin-nation.delete-description")) + Icons.icon( + Material.TNT, tr("admin-nation.delete"), tr("admin-nation.delete-description"), + actions = hints("click.delete") + ) ) { run("$command delete", ::exists, returnTo = back ?: this) } grid.add( - Icons.icon(Material.ANVIL, tr("admin-nation-tools.open"), tr("admin-nation-tools.open-description")) + Icons.icon( + Material.ANVIL, tr("admin-nation-tools.open"), tr("admin-nation-tools.open-description"), + actions = hints("click.open") + ) ) { AdminNationToolsMenu(player, nation, this).open() } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminNationToolsMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminNationToolsMenu.kt index 3cf59cf..2e4a495 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminNationToolsMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminNationToolsMenu.kt @@ -33,7 +33,8 @@ class AdminNationToolsMenu(player: Player, private val nation: Nation, back: Men Icons.icon( Material.EXPERIENCE_BOTTLE, tr("admin-nation-tools.level"), tr("admin-nation-tools.level-description"), - tr("common.current", "value" to nation.levelNumber) + tr("common.current", "value" to nation.levelNumber), + actions = hints("click.set") ) ) { prompt( @@ -50,7 +51,7 @@ class AdminNationToolsMenu(player: Player, private val nation: Nation, back: Men Icons.icon( Material.STRUCTURE_VOID, tr("admin-nation-tools.merge"), tr("admin-nation-tools.merge-description", "nation" to TownyUtil.name(nation.name)), - tr("admin-town-tools.merge-force") + actions = hints("click.choose-nation", "admin-town-tools.merge-force") ) ) { click -> val force = click.isRightClick @@ -62,7 +63,8 @@ class AdminNationToolsMenu(player: Player, private val nation: Nation, back: Men PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_NATION_TRANSFER, Icons.icon( Material.BELL, tr("admin-nation-tools.transfer"), - tr("admin-nation-tools.transfer-description", "nation" to TownyUtil.name(nation.name)) + tr("admin-nation-tools.transfer-description", "nation" to TownyUtil.name(nation.name)), + actions = hints("click.choose-town") ) ) { Pickers.town(this, tr("admin-nation-tools.transfer-title"), { !nation.hasTown(it) }) { town -> @@ -73,7 +75,8 @@ class AdminNationToolsMenu(player: Player, private val nation: Nation, back: Men PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_NATION_RECHECK, Icons.icon( Material.RECOVERY_COMPASS, tr("admin-nation-tools.recheck"), - tr("admin-nation-tools.recheck-description") + tr("admin-nation-tools.recheck-description"), + actions = hints("click.run") ) ) { runAndClose("$command recheck") @@ -82,7 +85,8 @@ class AdminNationToolsMenu(player: Player, private val nation: Nation, back: Men PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_NATION_SANCTIONTOWN, Icons.icon( Material.RED_BANNER, tr("nation-towns.sanctions"), tr("admin-nation-tools.sanctions-description"), - tr("nation-towns.sanctions-count", "count" to nation.sanctionedTowns.size) + tr("nation-towns.sanctions-count", "count" to nation.sanctionedTowns.size), + actions = hints("click.view") ) ) { AdminNamesMenu( @@ -93,7 +97,10 @@ class AdminNationToolsMenu(player: Player, private val nation: Nation, back: Men } grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_NATION_RANK, - Icons.icon(Material.NAME_TAG, tr("admin-nation-tools.ranks"), tr("admin-nation-tools.ranks-description")) + Icons.icon( + Material.NAME_TAG, tr("admin-nation-tools.ranks"), tr("admin-nation-tools.ranks-description"), + actions = hints("click.choose-player") + ) ) { lateinit var list: Menu list = ListMenu(player, tr("admin-town-tools.ranks-title"), this) { menu -> diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminPermGroupMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminPermGroupMenu.kt index 8fa3f3f..093a69d 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminPermGroupMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminPermGroupMenu.kt @@ -34,7 +34,10 @@ class AdminPermGroupMenu(player: Player, private val group: String, back: Menu) override fun controls() { guarded( 47, PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWNYPERMS, - Icons.icon(Material.NAME_TAG, tr("admin-perms.add-node"), tr("admin-perms.add-node-description")) + Icons.icon( + Material.NAME_TAG, tr("admin-perms.add-node"), tr("admin-perms.add-node-description"), + actions = hints("click.type-node") + ) ) { prompt(tr("admin-perms.add-node"), tr("admin-perms.node-label"), maxLength = 128) { node -> run("$command addperm ${TownyUtil.argument(node)}", { nodes().size }) diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminPermsMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminPermsMenu.kt index 25e243c..116fb21 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminPermsMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminPermsMenu.kt @@ -26,7 +26,8 @@ class AdminPermsMenu(player: Player, back: Menu) : Menu(player, player.tr("admin PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWNYPERMS, Icons.icon( Material.BOOKSHELF, tr("admin-perms.groups"), tr("admin-perms.groups-description"), - tr("admin-perms.groups-count", "count" to groups().size) + tr("admin-perms.groups-count", "count" to groups().size), + actions = hints("click.view") ) ) { groupList().open() @@ -35,7 +36,8 @@ class AdminPermsMenu(player: Player, back: Menu) : Menu(player, player.tr("admin PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWNYPERMS, Icons.icon( Material.NAME_TAG, tr("admin-perms.town-ranks"), tr("admin-perms.town-ranks-description"), - tr("admin-perms.ranks-count", "count" to TownyPerms.getTownRanks().size) + tr("admin-perms.ranks-count", "count" to TownyPerms.getTownRanks().size), + actions = hints("click.view") ) ) { AdminRanksMenu(player, nation = false, back = this).open() @@ -44,7 +46,8 @@ class AdminPermsMenu(player: Player, back: Menu) : Menu(player, player.tr("admin PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWNYPERMS, Icons.icon( Material.BEACON, tr("admin-perms.nation-ranks"), tr("admin-perms.nation-ranks-description"), - tr("admin-perms.ranks-count", "count" to TownyPerms.getNationRanks().size) + tr("admin-perms.ranks-count", "count" to TownyPerms.getNationRanks().size), + actions = hints("click.view") ) ) { AdminRanksMenu(player, nation = true, back = this).open() @@ -63,7 +66,7 @@ class AdminPermsMenu(player: Player, back: Menu) : Menu(player, player.tr("admin itemStack(Material.BOOKSHELF) { name("${TownyUtil.text(group)}") lore(tr("admin-perms.node-count", "count" to TownyPerms.getPermsOfGroup(group).size)) - loreActions(listOf(tr("common.click-details"))) + loreActions(listOf(tr("click.details"))) } }) { AdminPermGroupMenu(player, group, menu).open() } } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminPlotMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminPlotMenu.kt index e25486b..43e8ca6 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminPlotMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminPlotMenu.kt @@ -47,7 +47,10 @@ class AdminPlotMenu(player: Player, back: Menu) : Menu(player, player.tr("admin- val grid = layout(20, 21, 22, 23, 24) grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_PLOT_CLAIM, - Icons.icon(Material.PLAYER_HEAD, tr("admin-plot.claim"), tr("admin-plot.claim-description")) + Icons.icon( + Material.PLAYER_HEAD, tr("admin-plot.claim"), tr("admin-plot.claim-description"), + actions = hints("click.choose-player") + ) ) { Pickers.resident(this, tr("admin-plot.claim-title"), { true }) { target -> run("towny:townyadmin plot claim ${target.name}", { this.plot?.residentOrNull }) @@ -58,7 +61,8 @@ class AdminPlotMenu(player: Player, back: Menu) : Menu(player, player.tr("admin- PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_PLOT_TRUST, Icons.icon( Material.TRIPWIRE_HOOK, tr("plot.trusted"), tr("admin-plot.trust-description"), - tr("plot.trusted-count", "count" to plot.trustedResidents.size) + tr("plot.trusted-count", "count" to plot.trustedResidents.size), + actions = hints("click.view") ) ) { AdminNamesMenu( @@ -69,7 +73,10 @@ class AdminPlotMenu(player: Player, back: Menu) : Menu(player, player.tr("admin- } grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_SET_PLOT, - Icons.icon(Material.BELL, tr("admin-plot.move"), tr("admin-plot.move-description")) + Icons.icon( + Material.BELL, tr("admin-plot.move"), tr("admin-plot.move-description"), + actions = hints("click.choose-town") + ) ) { Pickers.town(this, tr("admin-plot.move-title"), { it != this.plot?.townOrNull }) { town -> run("towny:townyadmin set plot ${town.name}", { this.plot?.townOrNull }) @@ -78,7 +85,10 @@ class AdminPlotMenu(player: Player, back: Menu) : Menu(player, player.tr("admin- } grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_UNCLAIM, - Icons.icon(Material.COARSE_DIRT, tr("admin-plot.unclaim"), tr("admin-plot.unclaim-description")) + Icons.icon( + Material.COARSE_DIRT, tr("admin-plot.unclaim"), tr("admin-plot.unclaim-description"), + actions = hints("admin-plot.left-unclaim", "admin-plot.right-unclaim-area") + ) ) { click -> if (click.isRightClick) { prompt(tr("admin-plot.unclaim-title"), tr("claims.radius"), initial = "1", maxLength = 3) { radius -> @@ -88,7 +98,10 @@ class AdminPlotMenu(player: Player, back: Menu) : Menu(player, player.tr("admin- run("towny:townyadmin unclaim", { this.plot?.townOrNull }) } } - button(50, Icons.icon(Material.CLOCK, tr("map.refresh"), tr("plot.refresh-description"))) { render() } + button(50, Icons.icon( + Material.CLOCK, tr("map.refresh"), tr("plot.refresh-description"), + actions = hints("click.refresh") + )) { render() } backButton(49) } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminRanksMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminRanksMenu.kt index 9b354db..4f47ea8 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminRanksMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminRanksMenu.kt @@ -36,7 +36,7 @@ class AdminRanksMenu(player: Player, private val nation: Boolean, back: Menu) : itemStack(Material.NAME_TAG) { name("${TownyUtil.name(rank)}") lore(tr("admin-perms.node-count", "count" to nodes.size)) - loreActions(listOf(tr("common.left-details"), tr("admin-perms.right-remove"))) + loreActions(listOf(tr("click.left-details"), tr("admin-perms.right-remove"))) } }) { click -> if (click.isRightClick) { @@ -50,7 +50,10 @@ class AdminRanksMenu(player: Player, private val nation: Boolean, back: Menu) : override fun controls() { guarded( 47, PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWNYPERMS, - Icons.icon(Material.PAPER, tr("admin-perms.add-rank"), tr("admin-perms.add-rank-description")) + Icons.icon( + Material.PAPER, tr("admin-perms.add-rank"), tr("admin-perms.add-rank-description"), + actions = hints("click.type-name") + ) ) { prompt(tr("admin-perms.add-rank"), tr("admin-perms.rank-label")) { rank -> run("$command addrank ${TownyUtil.nameArgument(rank)}", { ranks().size }) @@ -58,7 +61,10 @@ class AdminRanksMenu(player: Player, private val nation: Boolean, back: Menu) : } guarded( 48, PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWNYPERMS, - Icons.icon(Material.WRITABLE_BOOK, tr("admin-perms.rename-rank"), tr("admin-perms.rename-rank-description")) + Icons.icon( + Material.WRITABLE_BOOK, tr("admin-perms.rename-rank"), tr("admin-perms.rename-rank-description"), + actions = hints("click.choose") + ) ) { val options = ranks().sorted().map { it to "${TownyUtil.name(it)}" } Pickers.option(this, tr("admin-perms.rename-rank"), options, null, Material.NAME_TAG) { rank -> diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminResidentListMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminResidentListMenu.kt index bed0201..a0a490a 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminResidentListMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminResidentListMenu.kt @@ -20,7 +20,7 @@ class AdminResidentListMenu(player: Player, back: Menu) : PagedMenu(player, play .filter { it.name.contains(filter, ignoreCase = true) } .sortedWith(compareBy({ !it.isOnline }, { it.name.lowercase() })) .map { resident -> - MenuEntry({ Icons.resident(player, resident, actions = listOf(tr("common.click-view"))) }) { + MenuEntry({ Icons.resident(player, resident, actions = listOf(tr("click.view"))) }) { AdminResidentMenu(player, resident, this).open() } } @@ -29,7 +29,8 @@ class AdminResidentListMenu(player: Player, back: Menu) : PagedMenu(player, play button( 47, Icons.icon( Material.COMPASS, tr("admin.search"), tr("admin.search-description"), - tr("admin.filter", "filter" to if (filter.isEmpty()) tr("common.none") else TownyUtil.text(filter)) + tr("admin.filter", "filter" to if (filter.isEmpty()) tr("common.none") else TownyUtil.text(filter)), + actions = hints("click.search", "click.clear") ) ) { click -> if (click.isRightClick) { diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminResidentMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminResidentMenu.kt index ea6ea56..252e3ec 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminResidentMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminResidentMenu.kt @@ -34,13 +34,16 @@ class AdminResidentMenu(player: Player, private val target: Resident, back: Menu val town = target.townOrNull if (town != null) { - grid.add(Icons.town(player, town, actions = listOf(tr("common.click-view")))) { + grid.add(Icons.town(player, town, actions = listOf(tr("click.view")))) { AdminTownMenu(player, town, this).open() } if (!target.isMayor) { grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWN_KICK, - Icons.icon(Material.IRON_BOOTS, tr("admin-resident.kick"), tr("admin-resident.kick-description")) + Icons.icon( + Material.IRON_BOOTS, tr("admin-resident.kick"), tr("admin-resident.kick-description"), + actions = hints("click.kick") + ) ) { run("towny:townyadmin town ${town.name} kick ${target.name}", { target.hasTown() }) } @@ -51,7 +54,8 @@ class AdminResidentMenu(player: Player, private val target: Resident, back: Menu Icons.icon( Material.BELL, tr("admin-resident.add-to-town"), - tr("admin-resident.add-to-town-description") + tr("admin-resident.add-to-town-description"), + actions = hints("click.choose-town") ) ) { Pickers.town(this, tr("admin-resident.add-to-town"), { true }) { picked -> @@ -64,7 +68,8 @@ class AdminResidentMenu(player: Player, private val target: Resident, back: Menu PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_RESIDENT_RENAME, Icons.icon( Material.NAME_TAG, tr("admin.rename"), tr("admin-resident.rename-description"), - tr("common.current", "value" to TownyUtil.name(target.name)) + tr("common.current", "value" to TownyUtil.name(target.name)), + actions = hints("click.rename") ) ) { prompt(tr("admin.rename"), tr("common.new-name"), initial = target.name, maxLength = 16) { name -> @@ -75,7 +80,8 @@ class AdminResidentMenu(player: Player, private val target: Resident, back: Menu PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_SET_TITLE, Icons.icon( Material.OAK_HANGING_SIGN, tr("resident-profile.title"), tr("resident-profile.title-description"), - tr("common.current", "value" to TownyUtil.text(target.title)) + tr("common.current", "value" to TownyUtil.text(target.title)), + actions = hints("click.edit", "click.clear") ) ) { click -> editTitle( @@ -89,7 +95,8 @@ class AdminResidentMenu(player: Player, private val target: Resident, back: Menu PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_SET_SURNAME, Icons.icon( Material.OAK_SIGN, tr("resident-profile.surname"), tr("resident-profile.surname-description"), - tr("common.current", "value" to TownyUtil.text(target.surname)) + tr("common.current", "value" to TownyUtil.text(target.surname)), + actions = hints("click.edit", "click.clear") ) ) { click -> editTitle( @@ -114,14 +121,20 @@ class AdminResidentMenu(player: Player, private val target: Resident, back: Menu if (target.isJailed) { grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_RESIDENT_UNJAIL, - Icons.icon(Material.IRON_BARS, tr("admin-resident.unjail"), tr("admin-resident.unjail-description")) + Icons.icon( + Material.IRON_BARS, tr("admin-resident.unjail"), tr("admin-resident.unjail-description"), + actions = hints("click.release") + ) ) { run("towny:townyadmin resident ${target.name} unjail", { target.isJailed }) } } grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_RESIDENT_DELETE, - Icons.icon(Material.TNT, tr("admin-resident.delete"), tr("admin-resident.delete-description")) + Icons.icon( + Material.TNT, tr("admin-resident.delete"), tr("admin-resident.delete-description"), + actions = hints("click.delete") + ) ) { run("towny:townyadmin resident ${target.name} delete", ::exists, returnTo = back ?: this) } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminServerMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminServerMenu.kt index edb1569..35160ef 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminServerMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminServerMenu.kt @@ -18,7 +18,10 @@ class AdminServerMenu(player: Player, back: Menu) : Menu(player, player.tr("admi override fun build() { guarded( 10, PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_NEWDAY, - Icons.icon(Material.CLOCK, tr("admin-server.new-day"), tr("admin-server.new-day-description")) + Icons.icon( + Material.CLOCK, tr("admin-server.new-day"), tr("admin-server.new-day-description"), + actions = hints("click.run") + ) ) { DialogUtil.confirm( player, @@ -30,13 +33,19 @@ class AdminServerMenu(player: Player, back: Menu) : Menu(player, player.tr("admi } guarded( 11, PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_NEWHOUR, - Icons.icon(Material.COMPASS, tr("admin-server.new-hour"), tr("admin-server.new-hour-description")) + Icons.icon( + Material.COMPASS, tr("admin-server.new-hour"), tr("admin-server.new-hour-description"), + actions = hints("click.run") + ) ) { runAndClose("towny:townyadmin newhour") } guarded( 12, PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_BACKUP, - Icons.icon(Material.CHEST, tr("admin-server.backup"), tr("admin-server.backup-description")) + Icons.icon( + Material.CHEST, tr("admin-server.backup"), tr("admin-server.backup-description"), + actions = hints("click.run") + ) ) { runAndClose("towny:townyadmin backup") } @@ -45,7 +54,8 @@ class AdminServerMenu(player: Player, back: Menu) : Menu(player, player.tr("admi Icons.icon( Material.ENDER_CHEST, tr("admin-server.save-database"), - tr("admin-server.save-database-description") + tr("admin-server.save-database-description"), + actions = hints("click.run") ) ) { runAndClose("towny:townyadmin database save") @@ -55,7 +65,8 @@ class AdminServerMenu(player: Player, back: Menu) : Menu(player, player.tr("admi Icons.icon( Material.RECOVERY_COMPASS, tr("admin-server.check-outposts"), - tr("admin-server.check-outposts-description") + tr("admin-server.check-outposts-description"), + actions = hints("click.run") ) ) { runAndClose("towny:townyadmin checkoutposts") @@ -63,7 +74,10 @@ class AdminServerMenu(player: Player, back: Menu) : Menu(player, player.tr("admi guarded( 15, PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_PURGE, - Icons.icon(Material.BONE, tr("admin-server.purge"), tr("admin-server.purge-description")) + Icons.icon( + Material.BONE, tr("admin-server.purge"), tr("admin-server.purge-description"), + actions = hints("click.choose-days") + ) ) { prompt( tr("admin-server.purge"), @@ -77,7 +91,10 @@ class AdminServerMenu(player: Player, back: Menu) : Menu(player, player.tr("admi } guarded( 16, PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_CHECKPERM, - Icons.icon(Material.SPYGLASS, tr("admin-server.check-perm"), tr("admin-server.check-perm-description")) + Icons.icon( + Material.SPYGLASS, tr("admin-server.check-perm"), tr("admin-server.check-perm-description"), + actions = hints("click.choose-player") + ) ) { Pickers.resident(this, tr("admin-server.check-perm"), { it.isOnline }) { target -> prompt(tr("admin-server.check-perm"), tr("admin-perms.node-label"), maxLength = 128) { node -> @@ -121,7 +138,8 @@ class AdminServerMenu(player: Player, back: Menu) : Menu(player, player.tr("admi Icons.icon( Material.GOLD_BLOCK, tr("admin-server.deposit-all"), - tr("admin-server.deposit-all-description") + tr("admin-server.deposit-all-description"), + actions = hints("click.type-amount") ) ) { prompt( @@ -186,7 +204,10 @@ class AdminServerMenu(player: Player, back: Menu) : Menu(player, player.tr("admi } private fun reload(slot: Int, material: Material, target: String, name: String, description: String) { - guarded(slot, PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_RELOAD, Icons.icon(material, name, description)) { + guarded( + slot, PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_RELOAD, + Icons.icon(material, name, description, actions = hints("click.reload")) + ) { runAndClose("towny:townyadmin reload $target") } } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminTownMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminTownMenu.kt index af9a666..670cfdc 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminTownMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminTownMenu.kt @@ -43,13 +43,19 @@ class AdminTownMenu(player: Player, private val town: Town, back: Menu) : grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWN_SPAWN, - Icons.icon(Material.ENDER_PEARL, tr("admin-town.spawn"), tr("admin-town.spawn-description")) + Icons.icon( + Material.ENDER_PEARL, tr("admin-town.spawn"), tr("admin-town.spawn-description"), + actions = hints("click.teleport") + ) ) { runAndClose("$command spawn") } grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWN_TOGGLE, - Icons.icon(Material.LEVER, tr("town.settings"), tr("admin-town.toggles-description")) + Icons.icon( + Material.LEVER, tr("town.settings"), tr("admin-town.toggles-description"), + actions = hints("click.open") + ) ) { toggles().open() } @@ -59,7 +65,8 @@ class AdminTownMenu(player: Player, private val town: Town, back: Menu) : Material.NAME_TAG, tr("admin.rename"), null, - tr("common.current", "value" to TownyUtil.name(town.name)) + tr("common.current", "value" to TownyUtil.name(town.name)), + actions = hints("click.rename") ) ) { prompt(tr("admin.rename"), tr("common.new-name"), initial = town.name) { name -> @@ -70,7 +77,9 @@ class AdminTownMenu(player: Player, private val town: Town, back: Menu) : PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_SET_MAYOR, Icons.icon( Material.GOLDEN_HELMET, tr("admin-town.mayor"), tr("admin-town.mayor-description"), - tr("common.current", "value" to (town.mayor?.let { TownyUtil.name(it.name) } ?: "-")))) { + tr("common.current", "value" to (town.mayor?.let { TownyUtil.name(it.name) } ?: "-")), + actions = hints("click.choose-player") + )) { residentList(tr("admin-town.mayor-title"), { !it.isMayor }) { resident -> run( "towny:townyadmin set mayor ${town.name} ${resident.name}", @@ -81,7 +90,10 @@ class AdminTownMenu(player: Player, private val town: Town, back: Menu) : } grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWN_ADD, - Icons.icon(Material.LIME_DYE, tr("admin-town.add"), tr("admin-town.add-description")) + Icons.icon( + Material.LIME_DYE, tr("admin-town.add"), tr("admin-town.add-description"), + actions = hints("click.type-name") + ) ) { prompt(tr("admin-town.add"), tr("common.player-name")) { name -> run("$command add ${TownyUtil.argument(name)}", { town.numResidents }) @@ -91,7 +103,8 @@ class AdminTownMenu(player: Player, private val town: Town, back: Menu) : PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWN_KICK, Icons.icon( Material.IRON_BOOTS, tr("admin-town.kick"), tr("admin-town.kick-description"), - tr("icon.town.residents", "count" to town.numResidents) + tr("icon.town.residents", "count" to town.numResidents), + actions = hints("click.choose-player") ) ) { residentList(tr("admin-town.kick-title"), { !it.isMayor }) { resident -> @@ -102,7 +115,8 @@ class AdminTownMenu(player: Player, private val town: Town, back: Menu) : PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_GIVEBONUS, Icons.icon( Material.GRASS_BLOCK, tr("admin-town.give-bonus"), tr("admin-town.give-bonus-description"), - tr("common.current", "value" to town.bonusBlocks) + tr("common.current", "value" to town.bonusBlocks), + actions = hints("click.type-amount") ) ) { prompt(tr("admin-town.give-bonus"), tr("common.amount")) { amount -> @@ -113,7 +127,8 @@ class AdminTownMenu(player: Player, private val town: Town, back: Menu) : PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWN_GIVEBOUGHTBLOCKS, Icons.icon( Material.MOSS_BLOCK, tr("admin-town.give-bought"), tr("admin-town.give-bought-description"), - tr("common.current", "value" to town.purchasedBlocks) + tr("common.current", "value" to town.purchasedBlocks), + actions = hints("click.type-amount") ) ) { prompt(tr("admin-town.give-bought"), tr("common.amount")) { amount -> @@ -128,7 +143,8 @@ class AdminTownMenu(player: Player, private val town: Town, back: Menu) : Material.EMERALD, tr("bank.deposit"), tr("admin.deposit-description"), - tr("bank.balance", "balance" to TownyUtil.balance(town)) + tr("bank.balance", "balance" to TownyUtil.balance(town)), + actions = hints("click.type-amount") ) ) { prompt(tr("bank.deposit-title"), tr("common.amount")) { amount -> @@ -141,7 +157,8 @@ class AdminTownMenu(player: Player, private val town: Town, back: Menu) : Material.REDSTONE, tr("bank.withdraw"), tr("admin.withdraw-description"), - tr("bank.balance", "balance" to TownyUtil.balance(town)) + tr("bank.balance", "balance" to TownyUtil.balance(town)), + actions = hints("click.type-amount") ) ) { prompt(tr("bank.withdraw-title"), tr("common.amount")) { amount -> @@ -150,7 +167,10 @@ class AdminTownMenu(player: Player, private val town: Town, back: Menu) : } grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWN_BANKHISTORY, - Icons.icon(Material.WRITTEN_BOOK, tr("bank.history"), tr("bank.history-description")) + Icons.icon( + Material.WRITTEN_BOOK, tr("bank.history"), tr("bank.history-description"), + actions = hints("click.view") + ) ) { runAndClose("$command bankhistory") } @@ -158,12 +178,15 @@ class AdminTownMenu(player: Player, private val town: Town, back: Menu) : val nation = town.nationOrNull if (nation != null) { - grid.add(Icons.nation(player, nation, actions = listOf(tr("common.click-view")))) { + grid.add(Icons.nation(player, nation, actions = listOf(tr("click.view")))) { AdminNationMenu(player, nation, this).open() } grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWN_LEAVENATION, - Icons.icon(Material.OAK_DOOR, tr("admin-town.leave-nation"), tr("admin-town.leave-nation-description")) + Icons.icon( + Material.OAK_DOOR, tr("admin-town.leave-nation"), tr("admin-town.leave-nation-description"), + actions = hints("click.remove") + ) ) { run("$command leavenation", { town.hasNation() }) } @@ -171,20 +194,29 @@ class AdminTownMenu(player: Player, private val town: Town, back: Menu) : if (town.isRuined) { grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWN_UNRUIN, - Icons.icon(Material.MOSSY_COBBLESTONE, tr("admin-town.unruin"), tr("admin-town.unruin-description")) + Icons.icon( + Material.MOSSY_COBBLESTONE, tr("admin-town.unruin"), tr("admin-town.unruin-description"), + actions = hints("click.restore") + ) ) { run("$command unruin", { town.isRuined }) } } grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWN_DELETE, - Icons.icon(Material.TNT, tr("admin-town.delete"), tr("admin-town.delete-description")) + Icons.icon( + Material.TNT, tr("admin-town.delete"), tr("admin-town.delete-description"), + actions = hints("click.delete") + ) ) { run("$command delete", ::exists, returnTo = back ?: this) } grid.add( - Icons.icon(Material.ANVIL, tr("admin-town-tools.open"), tr("admin-town-tools.open-description")) + Icons.icon( + Material.ANVIL, tr("admin-town-tools.open"), tr("admin-town-tools.open-description"), + actions = hints("click.open") + ) ) { AdminTownToolsMenu(player, town, this).open() } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminTownToolsMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminTownToolsMenu.kt index fbbfe65..97e4085 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminTownToolsMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminTownToolsMenu.kt @@ -33,7 +33,8 @@ class AdminTownToolsMenu(player: Player, private val town: Town, back: Menu) : PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWN_SETTOWNLEVEL, Icons.icon( Material.EXPERIENCE_BOTTLE, tr("admin-town-tools.level"), tr("admin-town-tools.level-description"), - tr("common.current", "value" to town.levelNumber) + tr("common.current", "value" to town.levelNumber), + actions = hints("click.set") ) ) { prompt( @@ -50,7 +51,7 @@ class AdminTownToolsMenu(player: Player, private val town: Town, back: Menu) : Icons.icon( Material.STRUCTURE_VOID, tr("admin-town-tools.merge"), tr("admin-town-tools.merge-description", "town" to TownyUtil.name(town.name)), - tr("admin-town-tools.merge-force") + actions = hints("click.choose-town", "admin-town-tools.merge-force") ) ) { click -> val force = click.isRightClick @@ -65,7 +66,8 @@ class AdminTownToolsMenu(player: Player, private val town: Town, back: Menu) : Icons.icon( Material.RED_BANNER, tr("admin-town-tools.not-for-sale"), tr("admin-town-tools.not-for-sale-description"), - tr("common.price", "price" to TownyUtil.money(town.forSalePrice)) + tr("common.price", "price" to TownyUtil.money(town.forSalePrice)), + actions = hints("click.stop-selling") ) ) { run("$command notforsale", { town.isForSale }) @@ -75,7 +77,8 @@ class AdminTownToolsMenu(player: Player, private val town: Town, back: Menu) : PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWN_FORSALE, Icons.icon( Material.GREEN_BANNER, tr("admin-town-tools.for-sale"), - tr("admin-town-tools.for-sale-description") + tr("admin-town-tools.for-sale-description"), + actions = hints("click.set-price") ) ) { prompt(tr("admin-town-tools.for-sale-title"), tr("common.price-label"), initial = "0") { price -> @@ -90,7 +93,8 @@ class AdminTownToolsMenu(player: Player, private val town: Town, back: Menu) : Icons.icon( Material.IRON_SWORD, tr("admin-town-tools.unconquer"), tr("admin-town-tools.unconquer-description"), - tr("town-status.conquered-days", "days" to town.conqueredDays) + tr("town-status.conquered-days", "days" to town.conqueredDays), + actions = hints("click.free") ) ) { run("$command toggle conquered off", { town.isConquered }) @@ -100,14 +104,18 @@ class AdminTownToolsMenu(player: Player, private val town: Town, back: Menu) : PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWN_CHECKOUTPOSTS, Icons.icon( Material.RECOVERY_COMPASS, tr("admin-server.check-outposts"), - tr("admin-town-tools.check-outposts-description") + tr("admin-town-tools.check-outposts-description"), + actions = hints("click.run") ) ) { runAndClose("$command checkoutposts") } grid.add( PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWN_RANK, - Icons.icon(Material.NAME_TAG, tr("admin-town-tools.ranks"), tr("admin-town-tools.ranks-description")) + Icons.icon( + Material.NAME_TAG, tr("admin-town-tools.ranks"), tr("admin-town-tools.ranks-description"), + actions = hints("click.choose-player") + ) ) { members(town.residents.toList()) { target, list -> RankMenu.create(player, target, nation = false, back = list, admin = town.name).open() @@ -117,7 +125,8 @@ class AdminTownToolsMenu(player: Player, private val town: Town, back: Menu) : PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWN_OUTLAW, Icons.icon( Material.IRON_BARS, tr("town.outlaws"), tr("admin-town-tools.outlaws-description"), - tr("town.outlaws-count", "count" to town.outlaws.size) + tr("town.outlaws-count", "count" to town.outlaws.size), + actions = hints("click.view") ) ) { AdminNamesMenu( @@ -129,7 +138,8 @@ class AdminTownToolsMenu(player: Player, private val town: Town, back: Menu) : PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWN_TRUST, Icons.icon( Material.TRIPWIRE_HOOK, tr("common.trusted"), tr("admin-town-tools.trust-description"), - tr("plot.trusted-count", "count" to town.trustedResidents.size) + tr("plot.trusted-count", "count" to town.trustedResidents.size), + actions = hints("click.view") ) ) { AdminNamesMenu( @@ -141,7 +151,8 @@ class AdminTownToolsMenu(player: Player, private val town: Town, back: Menu) : PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_TOWN_TRUSTTOWN, Icons.icon( Material.BELL, tr("admin-town-tools.trusted-towns"), tr("admin-town-tools.trusted-towns-description"), - tr("nation.towns-count", "count" to town.trustedTowns.size) + tr("nation.towns-count", "count" to town.trustedTowns.size), + actions = hints("click.view") ) ) { AdminNamesMenu( diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminWorldMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminWorldMenu.kt index 488fc6c..a35443e 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminWorldMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminWorldMenu.kt @@ -30,7 +30,10 @@ class AdminWorldMenu(player: Player, private val world: TownyWorld, back: Menu) guarded( 10, PermissionNodes.TOWNY_COMMAND_TOWNYWORLD_TOGGLE, - Icons.icon(Material.LEVER, tr("admin-world.toggles"), tr("admin-world.toggles-description")) + Icons.icon( + Material.LEVER, tr("admin-world.toggles"), tr("admin-world.toggles-description"), + actions = hints("click.open") + ) ) { toggles().open() } @@ -38,7 +41,8 @@ class AdminWorldMenu(player: Player, private val world: TownyWorld, back: Menu) 12, PermissionNodes.TOWNY_COMMAND_TOWNYWORLD_SET, Icons.icon( Material.NAME_TAG, tr("admin-world.rename-wild"), tr("admin-world.rename-wild-description"), - tr("common.current", "value" to TownyUtil.text(world.unclaimedZoneName)) + tr("common.current", "value" to TownyUtil.text(world.unclaimedZoneName)), + actions = hints("click.rename") ) ) { prompt(tr("admin-world.rename-wild"), tr("common.new-name"), initial = world.unclaimedZoneName) { name -> @@ -47,7 +51,10 @@ class AdminWorldMenu(player: Player, private val world: TownyWorld, back: Menu) } guarded( 14, PermissionNodes.TOWNY_COMMAND_TOWNYWORLD_SET, - Icons.icon(Material.BARRIER, tr("admin-world.reset"), tr("admin-world.reset-description")) + Icons.icon( + Material.BARRIER, tr("admin-world.reset"), tr("admin-world.reset-description"), + actions = hints("click.reset") + ) ) { run("$command set usedefault", ::snapshot) } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/PluginSettingsMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/PluginSettingsMenu.kt index 48652b0..8575a6f 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/PluginSettingsMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/PluginSettingsMenu.kt @@ -30,7 +30,7 @@ class PluginSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("a ) ) tr("admin-plugin.language-auto") else TownyUtil.text(language) ), - actions = listOf(tr("common.click-change")) + actions = listOf(tr("click.change")) ) ) { val options = @@ -44,7 +44,7 @@ class PluginSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("a Icons.icon( Material.NAME_TAG, tr("admin-plugin.prefix"), tr("admin-plugin.prefix-description"), tr("common.current", "value" to config.messagePrefix), - actions = listOf(tr("common.click-change")) + actions = listOf(tr("click.change")) ) ) { prompt( @@ -97,7 +97,7 @@ class PluginSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("a Icons.icon( Material.GOLD_NUGGET, tr("admin-plugin.bank-amounts"), tr("admin-plugin.bank-amounts-description"), tr("common.current", "value" to config.bankAmounts.joinToString(", ").ifEmpty { tr("common.none") }), - actions = listOf(tr("common.click-change")) + actions = listOf(tr("click.change")) ) ) { prompt( diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/TownyConfigMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/TownyConfigMenu.kt index 2bdb8b1..ece48d1 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/TownyConfigMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/TownyConfigMenu.kt @@ -29,13 +29,16 @@ class TownyConfigMenu(player: Player, private val section: String, back: Menu) : if (child.description.isNotEmpty()) loreWrapped("${shorten(child.description)}") loreBreak() lore(tr("admin-config.settings-count", "count" to TownyConfig.count(child.path))) - loreActions(listOf(tr("common.click-view"))) + loreActions(listOf(tr("click.view"))) } }) { TownyConfigMenu(player, child.path, this).open() } } + TownyConfig.settings(section).map { settingEntry(this, it) } override fun controls() { - button(47, Icons.icon(Material.COMPASS, tr("admin-config.search"), tr("admin-config.search-description"))) { + button(47, Icons.icon( + Material.COMPASS, tr("admin-config.search"), tr("admin-config.search-description"), + actions = hints("click.search") + )) { prompt(tr("admin-config.search-title"), tr("admin-config.search-label")) { query -> ListMenu(player, tr("admin-config.results-title", "query" to TownyUtil.text(query)), this) { list -> TownyConfig.search(query).map { settingEntry(list, it) } @@ -44,7 +47,10 @@ class TownyConfigMenu(player: Player, private val section: String, back: Menu) : } guarded( 51, PermissionNodes.TOWNY_COMMAND_TOWNYADMIN_RELOAD, - Icons.icon(Material.REPEATER, tr("admin-config.reload"), tr("admin-config.reload-description")) + Icons.icon( + Material.REPEATER, tr("admin-config.reload"), tr("admin-config.reload-description"), + actions = hints("click.reload") + ) ) { run(RELOAD, ::loadedConfig) } @@ -95,8 +101,8 @@ class TownyConfigMenu(player: Player, private val section: String, back: Menu) : menu.tr( when { !editable -> "menu.no-permission" - kind == Kind.BOOLEAN -> "icon.click-toggle" - else -> "common.click-change" + kind == Kind.BOOLEAN -> if (on) "icon.click-disable" else "icon.click-enable" + else -> "click.change" } ) ) diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/BankAmountMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/BankAmountMenu.kt index ee29135..0f4abf8 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/BankAmountMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/BankAmountMenu.kt @@ -70,7 +70,7 @@ class BankAmountMenu( row.add( Icons.icon( Material.NAME_TAG, tr("bank.custom"), tr("bank.custom-description"), - actions = listOf(tr("common.click-change")) + actions = hints("click.type-amount") ) ) { prompt( diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/BankMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/BankMenu.kt index 1a04e29..513f081 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/BankMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/BankMenu.kt @@ -56,7 +56,7 @@ class BankMenu( if (isNation) PermissionNodes.TOWNY_COMMAND_NATION_BANKHISTORY else PermissionNodes.TOWNY_COMMAND_TOWN_BANKHISTORY, Icons.icon( Material.WRITTEN_BOOK, tr("bank.history"), tr("bank.history-description"), - actions = listOf(tr("common.click-view")) + actions = listOf(tr("click.view")) ) ) { runAndClose("$command bankhistory") diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/PermissionMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/PermissionMenu.kt index 6fa0888..a0ad520 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/PermissionMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/PermissionMenu.kt @@ -59,8 +59,8 @@ class PermissionMenu( val allowed = perms.getPerm(level, action) val cell = itemStack(if (allowed) Material.LIME_CONCRETE else Material.RED_CONCRETE) { name("${if (allowed) "" else ""}${levelName(level)}: ${actionName(action)}") - lore(tr("icon.currently", "value" to tr(if (allowed) "perm.allowed" else "perm.denied"))) - loreActions(listOf(tr("icon.click-toggle"))) + lore(tr("icon.status", "value" to tr(if (allowed) "perm.allowed" else "perm.denied"))) + loreActions(hints(if (allowed) "perm.click-deny" else "perm.click-allow")) } guarded(11 + row * 9 + column, node, cell) { run("$command ${level.arg} ${action.arg} ${if (allowed) "off" else "on"}", ::snapshot) @@ -68,11 +68,17 @@ class PermissionMenu( } } - guarded(25, node, Icons.icon(Material.WATER_BUCKET, tr("perm.reset"), tr("perm.reset-description"))) { + guarded(25, node, Icons.icon( + Material.WATER_BUCKET, tr("perm.reset"), tr("perm.reset-description"), + actions = hints("click.reset") + )) { run("$command reset", ::snapshot) } overrides?.let { open -> - button(34, Icons.icon(Material.PLAYER_HEAD, tr("perm.overrides"), tr("perm.overrides-description"))) { + button(34, Icons.icon( + Material.PLAYER_HEAD, tr("perm.overrides"), tr("perm.overrides-description"), + actions = hints("click.open") + )) { open(this).open() } } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/ToggleMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/ToggleMenu.kt index a4a446a..9895eca 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/ToggleMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/ToggleMenu.kt @@ -3,7 +3,6 @@ package net.trilleo.mc.plugins.townymenu.guis.common import com.palmergames.bukkit.towny.permissions.PermissionNodes import net.trilleo.mc.plugins.townymenu.guis.framework.Icons import net.trilleo.mc.plugins.townymenu.guis.framework.Menu -import net.trilleo.mc.plugins.townymenu.utils.itemStack import org.bukkit.Material import org.bukkit.entity.Player import org.bukkit.event.inventory.ClickType @@ -46,13 +45,13 @@ class ToggleMenu( val bottom = inventory.size - 9 if (page > 0) { - button(bottom, pageArrow("menu.previous-page", page, pages)) { + button(bottom, pageArrow(true, page, pages)) { page-- render() } } if (page < pages - 1) { - button(bottom + 8, pageArrow("menu.next-page", page + 2, pages)) { + button(bottom + 8, pageArrow(false, page + 2, pages)) { page++ render() } @@ -60,11 +59,6 @@ class ToggleMenu( backButton(bottom + 4) } - private fun pageArrow(key: String, target: Int, pages: Int) = itemStack(Material.ARROW) { - name(tr(key)) - lore(tr("menu.page", "page" to target, "pages" to pages)) - } - private companion object { const val PAGE_SIZE = 21 } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/framework/Icons.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/framework/Icons.kt index 66c8e27..888df96 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/framework/Icons.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/framework/Icons.kt @@ -38,14 +38,14 @@ object Icons { loreActions(actions) } - /** A toggle switch showing its current [value]; clicking should flip it. */ + /** A toggle switch showing its current [value]; its action hint names what clicking flips it to. */ fun toggle(player: Player, material: Material, name: String, value: Boolean, description: String): ItemStack = itemStack(material) { name(name) loreWrapped("$description") loreBreak() - lore(player.tr("icon.currently", "value" to TownyUtil.onOff(player, value))) - loreActions(listOf(player.tr("icon.click-toggle"))) + lore(player.tr("icon.status", "value" to player.tr(if (value) "icon.enabled" else "icon.disabled"))) + loreActions(listOf(player.tr(if (value) "icon.click-disable" else "icon.click-enable"))) glow(value) } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/framework/Menu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/framework/Menu.kt index 9aaa011..5b27f00 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/framework/Menu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/framework/Menu.kt @@ -20,6 +20,7 @@ import org.bukkit.event.inventory.ClickType import org.bukkit.inventory.Inventory import org.bukkit.inventory.InventoryHolder import org.bukkit.inventory.ItemStack +import kotlin.math.roundToInt /** * Base class for every chest menu. @@ -37,7 +38,7 @@ import org.bukkit.inventory.ItemStack */ abstract class Menu( val player: Player, - title: String, + val title: String, rows: Int, val back: Menu? = null, ) : InventoryHolder { @@ -124,10 +125,38 @@ abstract class Menu( if (target == null) { button(slot, itemStack(Material.BARRIER) { name(tr("menu.close")) }) { player.closeInventory() } } else { - button(slot, itemStack(Material.ARROW) { name(tr("menu.back")) }) { target.open() } + button(slot, itemStack(Material.ARROW) { + name(tr("menu.back")) + lore(tr("menu.back-to", "menu" to target.title)) + }) { target.open() } } } + /** A page-turning arrow whose lore names the [target] page of [pages]. */ + protected fun pageArrow(previous: Boolean, target: Int, pages: Int): ItemStack = itemStack(Material.ARROW) { + name(tr(if (previous) "menu.previous-page" else "menu.next-page")) + lore(tr("menu.page", "page" to target, "pages" to pages)) + loreActions(hints("click.turn-page")) + } + + /** The translated click hints for [keys], ready for an icon's `actions`. */ + fun hints(vararg keys: String): List = keys.map { tr(it) } + + /** + * A progress bar lore line for [current] out of [max], with the percentage after it. A [max] of zero or less + * reads as full, so an unlimited allowance never shows as empty. + */ + fun progressBar(current: Number, max: Number): String { + val ratio = if (max.toDouble() <= 0) 1.0 else (current.toDouble() / max.toDouble()).coerceIn(0.0, 1.0) + val filled = (ratio * BAR_WIDTH).roundToInt() + return tr( + "common.progress-bar", + "filled" to " ".repeat(filled), + "empty" to " ".repeat(BAR_WIDTH - filled), + "percent" to (ratio * 100).roundToInt() + ) + } + /** * A `Cost: …` lore line for a button that charges [amount], or `null` when the server has no * economy or the action is free. Splat it into an icon with @@ -143,13 +172,24 @@ abstract class Menu( fun priceLine(amount: Double): String? = if (TownyUtil.economy) tr("common.price", "price" to TownyUtil.money(amount)) else null + /** + * The option after [current] in this list on a left click, or the one before it on a right click, wrapping at + * either end, for buttons that step through a list of choices such as a sort order. + */ + protected fun List.cycle(current: T, click: ClickType): T { + val step = if (click.isRightClick) size - 1 else 1 + return this[(indexOf(current).coerceAtLeast(0) + step) % size] + } + /** Places a help button opening the tutorial [chapter] that explains this menu. */ protected fun tutorialButton(slot: Int, chapter: Chapter) { button( slot, Icons.icon( Material.KNOWLEDGE_BOOK, tr("tutorial.help"), tr("tutorial.help-description"), tr("tutorial.chapter-line", "chapter" to tr(chapter.title)), - tr("tutorial.progress", "read" to chapter.readCount(player), "total" to chapter.lessons.size) + tr("tutorial.progress", "read" to chapter.readCount(player), "total" to chapter.lessons.size), + progressBar(chapter.readCount(player), chapter.lessons.size), + actions = hints("click.open") ) ) { TutorialChapterMenu(player, chapter, this).open() @@ -194,8 +234,9 @@ abstract class Menu( companion object { private val CLICK_SOUND = Sound.sound(Key.key("minecraft:ui.button.click"), Sound.Source.UI, 0.5f, 1f) - private val FILLER = itemStack(Material.GRAY_STAINED_GLASS_PANE) { hideTooltip(true) } + private val FILLER = itemStack(Material.BLACK_STAINED_GLASS_PANE) { hideTooltip(true) } + private const val BAR_WIDTH = 20 } private fun locked(item: ItemStack): ItemStack = itemStack(Material.GRAY_DYE) { diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/framework/PagedMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/framework/PagedMenu.kt index b456427..89826f5 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/framework/PagedMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/framework/PagedMenu.kt @@ -42,33 +42,13 @@ abstract class PagedMenu(player: Player, title: String, back: Menu?) : Menu(play if (all.isEmpty()) button(22, emptyItem) if (page > 0) { - button( - 45, - itemStack(Material.ARROW) { - name(tr("menu.previous-page")); lore( - tr( - "menu.page", - "page" to page, - "pages" to pages - ) - ) - }) { + button(45, pageArrow(true, page, pages)) { page-- render() } } if (page < pages - 1) { - button( - 53, - itemStack(Material.ARROW) { - name(tr("menu.next-page")); lore( - tr( - "menu.page", - "page" to page + 2, - "pages" to pages - ) - ) - }) { + button(53, pageArrow(false, page + 2, pages)) { page++ render() } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationInfoMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationInfoMenu.kt index e798305..ab22082 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationInfoMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationInfoMenu.kt @@ -29,7 +29,8 @@ class NationInfoMenu(player: Player, private val nation: Nation, back: Menu) : Icons.icon( Material.WRITABLE_BOOK, tr("nation-info.manage"), - tr("nation-info.manage-description") + tr("nation-info.manage-description"), + actions = hints("click.open") ) ) { NationMenu(player, this).open() @@ -38,7 +39,8 @@ class NationInfoMenu(player: Player, private val nation: Nation, back: Menu) : grid.add( Icons.icon( Material.ENDER_PEARL, tr("town-info.visit"), tr("nation-info.visit-description"), - *listOfNotNull(costLine(Prices.nationSpawn(player, nation))).toTypedArray() + *listOfNotNull(costLine(Prices.nationSpawn(player, nation))).toTypedArray(), + actions = hints("click.teleport") ) ) { runAndClose("towny:nation spawn ${nation.name}") @@ -48,7 +50,8 @@ class NationInfoMenu(player: Player, private val nation: Nation, back: Menu) : Material.BELL, tr("nation.towns"), null, - tr("nation.towns-count", "count" to nation.numTowns) + tr("nation.towns-count", "count" to nation.numTowns), + actions = hints("click.view") ) ) { NationTownsMenu(player, nation, this).open() @@ -56,7 +59,8 @@ class NationInfoMenu(player: Player, private val nation: Nation, back: Menu) : grid.add( Icons.icon( Material.SHIELD, tr("nation.relations"), null, - tr("icon.nation.relations", "allies" to nation.allies.size, "enemies" to nation.enemies.size) + tr("icon.nation.relations", "allies" to nation.allies.size, "enemies" to nation.enemies.size), + actions = hints("click.view") ) ) { NationRelationsMenu(player, nation, this).open() @@ -66,7 +70,10 @@ class NationInfoMenu(player: Player, private val nation: Nation, back: Menu) : if (viewer != null && town != null && viewer.isMayor && !town.hasNation() && nation.isOpen) { grid.add( PermissionNodes.TOWNY_COMMAND_NATION_JOIN, - Icons.icon(Material.OAK_DOOR, tr("nation-info.join"), tr("nation-info.join-description")) + Icons.icon( + Material.OAK_DOOR, tr("nation-info.join"), tr("nation-info.join-description"), + actions = hints("click.join") + ) ) { run("towny:nation join ${nation.name}", { town.hasNation() }) } @@ -79,7 +86,8 @@ class NationInfoMenu(player: Player, private val nation: Nation, back: Menu) : Icons.icon( Material.SHIELD, tr("nation-info.end-alliance"), - tr("nation-info.end-alliance-description") + tr("nation-info.end-alliance-description"), + actions = hints("click.end-alliance") ) ) { run("towny:nation ally remove ${nation.name}", snapshot) @@ -90,7 +98,8 @@ class NationInfoMenu(player: Player, private val nation: Nation, back: Menu) : Icons.icon( Material.SHIELD, tr("nation.propose-alliance"), - tr("nation-info.propose-alliance-description") + tr("nation-info.propose-alliance-description"), + actions = hints("click.propose") ) ) { run("towny:nation ally add ${nation.name}", snapshot) @@ -101,6 +110,7 @@ class NationInfoMenu(player: Player, private val nation: Nation, back: Menu) : Material.IRON_SWORD, tr(if (own.hasEnemy(nation)) "nation-info.make-peace" else "nation.declare-enemy"), tr(if (own.hasEnemy(nation)) "nation-info.make-peace-description" else "nation-info.declare-enemy-description"), + actions = hints(if (own.hasEnemy(nation)) "click.make-peace" else "click.declare-enemy") ) ) { run("towny:nation enemy ${if (own.hasEnemy(nation)) "remove" else "add"} ${nation.name}", snapshot) } } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationListMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationListMenu.kt index c4bfed3..89d4da0 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationListMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationListMenu.kt @@ -32,7 +32,7 @@ class NationListMenu(player: Player, back: Menu) : PagedMenu(player, player.tr(" .sortedWith(sort.comparator) .map { nation -> MenuEntry({ - Icons.nation(player, nation, actions = listOf(tr("common.click-details"))) + Icons.nation(player, nation, actions = listOf(tr("click.details"))) }) { NationInfoMenu(player, nation, this).open() } } @@ -41,10 +41,10 @@ class NationListMenu(player: Player, back: Menu) : PagedMenu(player, player.tr(" val sorts = Sort.entries.filter { it != Sort.BALANCE || TownyUtil.economy } button(47, itemStack(Material.HOPPER) { name(tr("sort.current", "sort" to tr(sort.label))) - lore(sorts.map { (if (it == sort) "▶ " else " ") + tr(it.label) }) - loreActions(listOf(tr("common.click-change"))) - }) { - sort = sorts[(sorts.indexOf(sort) + 1) % sorts.size] + lore(sorts.map { tr(if (it == sort) "sort.selected" else "sort.option", "sort" to tr(it.label)) }) + loreActions(hints("click.next", "click.previous")) + }) { click -> + sort = sorts.cycle(sort, click) render() } } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationMenu.kt index 7a570a5..43e3007 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationMenu.kt @@ -54,7 +54,8 @@ class NationMenu(player: Player, back: Menu?) : Menu(player, player.tr("nation.t Material.BELL, tr("nation.towns"), tr("nation.towns-description"), - tr("nation.towns-count", "count" to nation.numTowns) + tr("nation.towns-count", "count" to nation.numTowns), + actions = hints("click.view") ) ) { NationTownsMenu(player, nation, this).open() @@ -62,7 +63,8 @@ class NationMenu(player: Player, back: Menu?) : Menu(player, player.tr("nation.t grid.add( Icons.icon( Material.PLAYER_HEAD, tr("town.residents"), tr("nation.residents-description"), - tr("icon.town.residents", "count" to nation.numResidents) + tr("icon.town.residents", "count" to nation.numResidents), + actions = hints("click.view") ) ) { residents(nation).open() @@ -73,32 +75,46 @@ class NationMenu(player: Player, back: Menu?) : Menu(player, player.tr("nation.t Material.GOLD_INGOT, tr("nation.bank"), tr("town.bank-description"), - tr("bank.balance", "balance" to TownyUtil.balance(nation)) + tr("bank.balance", "balance" to TownyUtil.balance(nation)), + actions = hints("click.open") ) ) { BankMenu(player, nation, this).open() } } - grid.add(Icons.icon(Material.SHIELD, tr("nation.relations"), tr("nation.relations-description"))) { + grid.add(Icons.icon( + Material.SHIELD, tr("nation.relations"), tr("nation.relations-description"), + actions = hints("click.view") + )) { NationRelationsMenu(player, nation, this).open() } - grid.add(Icons.icon(Material.LEVER, tr("nation.settings"), tr("nation.settings-description"))) { + grid.add(Icons.icon( + Material.LEVER, tr("nation.settings"), tr("nation.settings-description"), + actions = hints("click.open") + )) { toggles().open() } - grid.add(Icons.icon(Material.WRITABLE_BOOK, tr("nation.details"), tr("nation.details-description"))) { + grid.add(Icons.icon( + Material.WRITABLE_BOOK, tr("nation.details"), tr("nation.details-description"), + actions = hints("click.open") + )) { NationSettingsMenu(player, this).open() } grid.add( Icons.icon( Material.ENDER_PEARL, tr("nation.spawn"), tr("nation.spawn-description"), - *listOfNotNull(costLine(Prices.nationSpawn(player, nation))).toTypedArray() + *listOfNotNull(costLine(Prices.nationSpawn(player, nation))).toTypedArray(), + actions = hints("click.teleport") ) ) { runAndClose("towny:nation spawn") } grid.add( PermissionNodes.TOWNY_COMMAND_NATION_SAY, - Icons.icon(Material.GOAT_HORN, tr("nation.announce"), tr("nation.announce-description")) + Icons.icon( + Material.GOAT_HORN, tr("nation.announce"), tr("nation.announce-description"), + actions = hints("click.write") + ) ) { prompt(tr("nation.announce-title"), tr("common.message"), maxLength = 200) { text -> run("towny:nation say $text") @@ -107,14 +123,20 @@ class NationMenu(player: Player, back: Menu?) : Menu(player, player.tr("nation.t if (viewer.isKing) { grid.add( PermissionNodes.TOWNY_COMMAND_NATION_DELETE, - Icons.icon(Material.TNT, tr("nation.delete"), tr("nation.delete-description")) + Icons.icon( + Material.TNT, tr("nation.delete"), tr("nation.delete-description"), + actions = hints("click.delete") + ) ) { run("towny:nation delete", { viewer.hasNation() }, returnTo = MainMenu(player)) } } else if (viewer.isMayor) { grid.add( PermissionNodes.TOWNY_COMMAND_NATION_LEAVE, - Icons.icon(Material.OAK_DOOR, tr("nation.leave"), tr("nation.leave-description")) + Icons.icon( + Material.OAK_DOOR, tr("nation.leave"), tr("nation.leave-description"), + actions = hints("click.leave") + ) ) { run("towny:nation leave", { viewer.hasNation() }, returnTo = MainMenu(player)) } @@ -132,7 +154,7 @@ class NationMenu(player: Player, back: Menu?) : Menu(player, player.tr("nation.t .thenBy { it.name.lowercase() }) .map { member -> MenuEntry({ - Icons.resident(player, member, actions = listOf(tr("common.click-view"))) + Icons.resident(player, member, actions = listOf(tr("click.view"))) }) { ResidentProfileMenu(player, member, menu).open() } } } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationRelationsMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationRelationsMenu.kt index a3c0c67..48d83b8 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationRelationsMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationRelationsMenu.kt @@ -36,7 +36,7 @@ class NationRelationsMenu(player: Player, private val nation: Nation, back: Menu private fun relation(other: Nation, label: String, canRemove: Boolean, removeCommand: String): MenuEntry { val actions = listOfNotNull( - tr("common.left-details"), + tr("click.left-details"), if (canRemove) tr("nation-relations.right-remove") else null ) return MenuEntry({ Icons.nation(player, other, label, actions = actions) }) { click -> @@ -56,7 +56,8 @@ class NationRelationsMenu(player: Player, private val nation: Nation, back: Menu Icons.icon( Material.SHIELD, tr("nation.propose-alliance"), - tr("nation-relations.propose-alliance-description") + tr("nation-relations.propose-alliance-description"), + actions = hints("click.choose-nation") ) ) { Pickers.nation( @@ -71,7 +72,8 @@ class NationRelationsMenu(player: Player, private val nation: Nation, back: Menu Icons.icon( Material.IRON_SWORD, tr("nation.declare-enemy"), - tr("nation-relations.declare-enemy-description") + tr("nation-relations.declare-enemy-description"), + actions = hints("click.choose-nation") ) ) { Pickers.nation( @@ -86,7 +88,8 @@ class NationRelationsMenu(player: Player, private val nation: Nation, back: Menu 51, Icons.icon( Material.PAPER, tr("nation-relations.sent-requests"), null, tr("common.pending", "count" to pending.size), "", - *pending.take(10).map { "- ${TownyUtil.name(it.receiver.name)}" }.toTypedArray() + *pending.take(10) + .map { tr("common.list-entry", "entry" to TownyUtil.name(it.receiver.name)) }.toTypedArray() ) ) } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationSanctionsMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationSanctionsMenu.kt index ef92c1e..7531288 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationSanctionsMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationSanctionsMenu.kt @@ -30,7 +30,7 @@ class NationSanctionsMenu(player: Player, private val nation: Nation, back: Menu val canEdit = canEdit return nation.sanctionedTowns.sortedBy { it.name.lowercase() }.map { town -> val actions = listOfNotNull( - tr("common.left-details"), + tr("click.left-details"), if (canEdit) tr("nation-sanctions.right-lift") else null ) MenuEntry({ Icons.town(player, town, actions = actions) }) { click -> @@ -48,7 +48,10 @@ class NationSanctionsMenu(player: Player, private val nation: Nation, back: Menu if (resident?.nationOrNull != nation) return guarded( 47, PermissionNodes.TOWNY_COMMAND_NATION_SANCTIONTOWN, - Icons.icon(Material.RED_BANNER, tr("nation-sanctions.add"), tr("nation-sanctions.add-description")) + Icons.icon( + Material.RED_BANNER, tr("nation-sanctions.add"), tr("nation-sanctions.add-description"), + actions = hints("click.choose-town") + ) ) { Pickers.town( this, diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationSettingsMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationSettingsMenu.kt index 9c84cd5..65703ee 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationSettingsMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationSettingsMenu.kt @@ -31,7 +31,8 @@ class NationSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("n tr("nation-details.rename"), null, tr("common.current", "value" to TownyUtil.name(nation.name)), - *listOfNotNull(costLine(TownySettings.getNationRenameCost())).toTypedArray() + *listOfNotNull(costLine(TownySettings.getNationRenameCost())).toTypedArray(), + actions = hints("click.rename") ) ) { prompt(tr("nation-details.rename-title"), tr("common.new-name"), initial = nation.name) { name -> @@ -40,7 +41,10 @@ class NationSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("n } grid.add( PermissionNodes.TOWNY_COMMAND_NATION_SET_BOARD, - Icons.icon(Material.OAK_SIGN, tr("nation-details.board"), tr("town-details.board-description")) + Icons.icon( + Material.OAK_SIGN, tr("nation-details.board"), tr("town-details.board-description"), + actions = hints("click.edit", "click.clear") + ) ) { click -> if (click.isRightClick) { run("towny:nation set board none", { nation.board }) @@ -62,7 +66,8 @@ class NationSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("n Material.PAPER, tr("nation-details.tag"), tr("common.tag-description"), - tr("common.current", "value" to TownyUtil.text(nation.tag)) + tr("common.current", "value" to TownyUtil.text(nation.tag)), + actions = hints("click.set") ) ) { prompt(tr("nation-details.tag-title"), tr("common.tag"), initial = nation.tag, maxLength = 16) { tag -> @@ -75,7 +80,8 @@ class NationSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("n Material.LIGHT_BLUE_DYE, tr("nation-details.map-color"), tr("nation-details.map-color-description"), - *listOfNotNull(costLine(TownySettings.getNationSetMapColourCost())).toTypedArray() + *listOfNotNull(costLine(TownySettings.getNationSetMapColourCost())).toTypedArray(), + actions = hints("click.choose") ) ) { val colors = TownySettings.getNationColorsMap().keys.sorted().map { it to "${TownyUtil.name(it)}" } @@ -88,7 +94,8 @@ class NationSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("n Icons.icon( Material.GOLDEN_HELMET, tr("nation-details.capital"), null, tr("common.current", "value" to (nation.capital?.let { TownyUtil.name(it.name) } ?: "-")), - *listOfNotNull(costLine(TownySettings.getNationCapitalChangeCost())).toTypedArray() + *listOfNotNull(costLine(TownySettings.getNationCapitalChangeCost())).toTypedArray(), + actions = hints("click.choose-town") ) ) { ListMenu(player, tr("nation-details.capital-title"), this) { @@ -103,7 +110,9 @@ class NationSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("n PermissionNodes.TOWNY_COMMAND_NATION_SET_KING, Icons.icon( Material.PLAYER_HEAD, tr("nation-details.leader"), tr("nation-details.leader-description"), - tr("common.current", "value" to (nation.king?.let { TownyUtil.name(it.name) } ?: "-")))) { + tr("common.current", "value" to (nation.king?.let { TownyUtil.name(it.name) } ?: "-")), + actions = hints("click.choose-player") + )) { ListMenu(player, tr("nation-details.leader-title"), this) { nation.capital?.residents.orEmpty().filter { !it.isKing }.sortedBy { it.name.lowercase() } .map { candidate -> @@ -120,7 +129,10 @@ class NationSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("n } grid.add( PermissionNodes.TOWNY_COMMAND_NATION_SET_SPAWN, - Icons.icon(Material.RESPAWN_ANCHOR, tr("common.set-spawn"), tr("nation-details.set-spawn-description")) + Icons.icon( + Material.RESPAWN_ANCHOR, tr("common.set-spawn"), tr("nation-details.set-spawn-description"), + actions = hints("click.set-here") + ) ) { run("towny:nation set spawn", { runCatching { nation.spawn }.getOrNull() }) } @@ -171,7 +183,7 @@ class NationSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("n "$label", null, tr("common.current", "value" to current), - actions = listOf(tr("common.click-change")) + actions = listOf(tr("click.change")) ) ) { prompt(label, tr("common.amount"), initial = read().toString()) { amount -> diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationStatusMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationStatusMenu.kt index bf05225..22e7b82 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationStatusMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationStatusMenu.kt @@ -38,15 +38,22 @@ class NationStatusMenu(player: Player, private val nation: Nation, back: Menu) : val progress = if (byTowns) nation.numTowns else nation.numResidents val next = thresholds.getOrNull(number + 1) return Icons.icon( - Material.EXPERIENCE_BOTTLE, tr("nation-status.level"), tr("nation-status.level-description"), - tr("town-status.level-number", "level" to number, "max" to TownySettings.getNationLevelMax()), - tr("town-status.level-name", "name" to TownyUtil.name(nation.formattedName)), - when { - nation.manualNationLevel > -1 -> tr("town-status.level-manual") - next == null -> tr("town-status.level-highest") - byTowns -> tr("nation-status.next-level-towns", "current" to progress, "needed" to next) - else -> tr("town-status.next-level-residents", "current" to progress, "needed" to next) - } + Material.EXPERIENCE_BOTTLE, tr("nation-status.level"), tr("nation-status.level-description"), *buildList { + add(tr("town-status.level-number", "level" to number, "max" to TownySettings.getNationLevelMax())) + add(tr("town-status.level-name", "name" to TownyUtil.name(nation.formattedName))) + add( + when { + nation.manualNationLevel > -1 -> tr("town-status.level-manual") + next == null -> tr("town-status.level-highest") + byTowns -> tr("nation-status.next-level-towns", "current" to progress, "needed" to next) + else -> tr("town-status.next-level-residents", "current" to progress, "needed" to next) + } + ) + if (nation.manualNationLevel == -1 && next != null) { + val floor = thresholds.getOrElse(number) { 0 } + add(progressBar(progress - floor, next - floor)) + } + }.toTypedArray() ) } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationTownsMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationTownsMenu.kt index 0bb9bd9..f2809a5 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationTownsMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationTownsMenu.kt @@ -29,7 +29,7 @@ class NationTownsMenu(player: Player, private val nation: Nation, back: Menu) : .map { town -> val lines = listOfNotNull(if (nation.isCapital(town)) tr("nation-towns.capital") else null) val actions = listOfNotNull( - tr("common.left-details"), + tr("click.left-details"), if (canKick && !nation.isCapital(town)) tr("nation-towns.right-remove") else null ) MenuEntry({ Icons.town(player, town, *lines.toTypedArray(), actions = actions) }) { click -> @@ -48,7 +48,10 @@ class NationTownsMenu(player: Player, private val nation: Nation, back: Menu) : val sent = { nation.sentInvites.size } guarded( 47, PermissionNodes.TOWNY_COMMAND_NATION_INVITE_ADD, - Icons.icon(Material.BELL, tr("nation-towns.invite"), tr("nation-towns.invite-description")) + Icons.icon( + Material.BELL, tr("nation-towns.invite"), tr("nation-towns.invite-description"), + actions = hints("click.choose-town") + ) ) { Pickers.town(this, tr("nation-towns.invite-title"), { !it.hasNation() }) { picked -> run("towny:nation add ${picked.name}", sent) @@ -57,7 +60,8 @@ class NationTownsMenu(player: Player, private val nation: Nation, back: Menu) : button( 48, Icons.icon( Material.RED_BANNER, tr("nation-towns.sanctions"), tr("nation-towns.sanctions-description"), - tr("nation-towns.sanctions-count", "count" to nation.sanctionedTowns.size) + tr("nation-towns.sanctions-count", "count" to nation.sanctionedTowns.size), + actions = hints("click.view") ) ) { NationSanctionsMenu(player, nation, this).open() @@ -67,7 +71,8 @@ class NationTownsMenu(player: Player, private val nation: Nation, back: Menu) : 51, Icons.icon( Material.PAPER, tr("common.sent-invites"), null, tr("common.pending", "count" to pending.size), "", - *pending.take(10).map { "- ${TownyUtil.name(it.receiver.name)}" }.toTypedArray() + *pending.take(10) + .map { tr("common.list-entry", "entry" to TownyUtil.name(it.receiver.name)) }.toTypedArray() ) ) } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NoNationMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NoNationMenu.kt index d01c78f..2eb8af2 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NoNationMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NoNationMenu.kt @@ -23,7 +23,8 @@ class NoNationMenu(player: Player, back: Menu) : Menu(player, player.tr("no-nati Material.BEACON, tr("no-nation.found"), tr("no-nation.found-description"), - *listOfNotNull(price).toTypedArray() + *listOfNotNull(price).toTypedArray(), + actions = hints("click.found") ) ) { prompt(tr("no-nation.found-title"), tr("no-nation.nation-name")) { name -> @@ -34,7 +35,10 @@ class NoNationMenu(player: Player, back: Menu) : Menu(player, player.tr("no-nati ) } } - button(13, Icons.icon(Material.OAK_DOOR, tr("no-nation.browse"), tr("no-nation.browse-description"))) { + button(13, Icons.icon( + Material.OAK_DOOR, tr("no-nation.browse"), tr("no-nation.browse-description"), + actions = hints("click.browse") + )) { NationListMenu(player, this).open() } val invites = resident?.townOrNull?.receivedInvites?.size ?: 0 @@ -44,7 +48,8 @@ class NoNationMenu(player: Player, back: Menu) : Menu(player, player.tr("no-nati Material.PAPER, tr("main.invites"), tr("no-nation.invites-description"), - tr("common.pending", "count" to invites) + tr("common.pending", "count" to invites), + actions = hints("click.view") ) ) { InvitesMenu(player, this).open() diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotAreaMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotAreaMenu.kt index 80c9649..dbf43c5 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotAreaMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotAreaMenu.kt @@ -30,7 +30,7 @@ class PlotAreaMenu(player: Player, back: Menu) : Menu(player, player.tr("plot-ar 21, Icons.icon( if (circle) Material.SNOWBALL else Material.PAINTING, tr("plot-area.shape"), null, tr("common.current", "value" to tr(if (circle) "plot-area.circle" else "plot-area.square")), - actions = listOf(tr("common.click-change")) + actions = listOf(tr("click.change")) ) ) { circle = !circle @@ -40,7 +40,7 @@ class PlotAreaMenu(player: Player, back: Menu) : Menu(player, player.tr("plot-ar 23, Icons.icon( Material.COMPASS, tr("plot-area.radius"), tr("plot-area.radius-description"), tr("common.current", "value" to radius), - actions = listOf(tr("common.click-change")) + actions = listOf(tr("click.change")) ) ) { prompt(tr("plot-area.radius-title"), tr("claims.radius"), initial = radius, maxLength = 3) { @@ -53,14 +53,20 @@ class PlotAreaMenu(player: Player, back: Menu) : Menu(player, player.tr("plot-ar val actions = layout(29, 30, 31, 32, 33) actions.add( PermissionNodes.TOWNY_COMMAND_PLOT_CLAIM, - Icons.icon(Material.EMERALD, tr("plot-area.buy"), tr("plot-area.buy-description")) + Icons.icon( + Material.EMERALD, tr("plot-area.buy"), tr("plot-area.buy-description"), + actions = hints("click.buy") + ) ) { run("towny:plot claim $area", owned, delayTicks = CLAIM_DELAY) } if (TownyUtil.economy) { actions.add( PermissionNodes.TOWNY_COMMAND_PLOT_FORSALE, - Icons.icon(Material.GREEN_BANNER, tr("plot-area.sell"), tr("plot-area.sell-description")) + Icons.icon( + Material.GREEN_BANNER, tr("plot-area.sell"), tr("plot-area.sell-description"), + actions = hints("click.set-price") + ) ) { val price = TownyAPI.getInstance().getTown(player.location)?.plotPrice?.takeIf { it >= 0 } ?: 0.0 prompt( @@ -75,13 +81,19 @@ class PlotAreaMenu(player: Player, back: Menu) : Menu(player, player.tr("plot-ar } actions.add( PermissionNodes.TOWNY_COMMAND_PLOT_NOTFORSALE, - Icons.icon(Material.RED_BANNER, tr("plot-area.not-for-sale"), tr("plot-area.not-for-sale-description")) + Icons.icon( + Material.RED_BANNER, tr("plot-area.not-for-sale"), tr("plot-area.not-for-sale-description"), + actions = hints("click.stop-selling") + ) ) { run("towny:plot notforsale $area") } actions.add( PermissionNodes.TOWNY_COMMAND_PLOT_UNCLAIM, - Icons.icon(Material.COARSE_DIRT, tr("plot-area.give-up"), tr("plot-area.give-up-description")) + Icons.icon( + Material.COARSE_DIRT, tr("plot-area.give-up"), tr("plot-area.give-up-description"), + actions = hints("click.give-up") + ) ) { run("towny:plot unclaim $area", owned, delayTicks = CLAIM_DELAY) } @@ -89,7 +101,8 @@ class PlotAreaMenu(player: Player, back: Menu) : Menu(player, player.tr("plot-ar PermissionNodes.TOWNY_COMMAND_PLOT_UNCLAIM, Icons.icon( Material.LAVA_BUCKET, tr("plot-area.give-up-all"), tr("plot-area.give-up-all-description"), - tr("profile.plots-owned", "count" to (resident?.townBlocks?.size ?: 0)) + tr("profile.plots-owned", "count" to (resident?.townBlocks?.size ?: 0)), + actions = hints("click.give-up") ) ) { run("towny:plot unclaim all", owned, delayTicks = CLAIM_DELAY) diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotGroupMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotGroupMenu.kt index b5f4181..ec18282 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotGroupMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotGroupMenu.kt @@ -37,7 +37,10 @@ class PlotGroupMenu(player: Player, back: Menu) : Menu(player, player.tr("plot-g val groups = layout(19, 20, 21, 22, 23, 24, 25) groups.add( PermissionNodes.TOWNY_COMMAND_PLOT_GROUP_ADD, - Icons.icon(Material.CHEST, tr("plot-group.add"), tr("plot-group.add-description")) + Icons.icon( + Material.CHEST, tr("plot-group.add"), tr("plot-group.add-description"), + actions = hints("click.type-name") + ) ) { prompt(tr("plot-group.add-title"), tr("plot-group.group-name")) { name -> run("towny:plot group add ${TownyUtil.nameArgument(name)}", groupProbe) @@ -49,14 +52,15 @@ class PlotGroupMenu(player: Player, back: Menu) : Menu(player, player.tr("plot-g Icons.icon( Material.HOPPER, tr("plot-group.remove"), - tr("plot-group.remove-description", "group" to TownyUtil.name(group.name)) + tr("plot-group.remove-description", "group" to TownyUtil.name(group.name)), + actions = hints("click.remove") ) ) { run("towny:plot group remove", groupProbe) } groups.add( PermissionNodes.TOWNY_COMMAND_PLOT_GROUP_RENAME, - Icons.icon(Material.NAME_TAG, tr("plot-group.rename"), null) + Icons.icon(Material.NAME_TAG, tr("plot-group.rename"), null, actions = hints("click.rename")) ) { prompt(tr("plot-group.rename-title"), tr("common.new-name"), initial = group.name) { name -> run("towny:plot group rename ${TownyUtil.nameArgument(name)}", groupProbe) @@ -70,7 +74,8 @@ class PlotGroupMenu(player: Player, back: Menu) : Menu(player, player.tr("plot-g tr( "common.price", "price" to if (group.price >= 0) TownyUtil.money(group.price) else tr("plot-group.not-for-sale") - ) + ), + actions = hints("click.set-price") ) ) { prompt(tr("plot-group.sell-title"), tr("common.price-label"), initial = "0") { price -> @@ -79,7 +84,10 @@ class PlotGroupMenu(player: Player, back: Menu) : Menu(player, player.tr("plot-g } groups.add( PermissionNodes.TOWNY_COMMAND_PLOT_GROUP_NOTFORSALE, - Icons.icon(Material.RED_BANNER, tr("plot-group.stop-selling"), null) + Icons.icon( + Material.RED_BANNER, tr("plot-group.stop-selling"), null, + actions = hints("click.stop-selling") + ) ) { run("towny:plot group notforsale", groupProbe) } @@ -89,7 +97,8 @@ class PlotGroupMenu(player: Player, back: Menu) : Menu(player, player.tr("plot-g Icons.icon( Material.LAVA_BUCKET, tr("plot-group.delete"), - tr("plot-group.delete-description", "group" to TownyUtil.name(group.name)) + tr("plot-group.delete-description", "group" to TownyUtil.name(group.name)), + actions = hints("click.delete") ) ) { run("towny:plot group delete", groupProbe) @@ -99,7 +108,10 @@ class PlotGroupMenu(player: Player, back: Menu) : Menu(player, player.tr("plot-g val districts = layout(28, 29, 30, 31) districts.add( PermissionNodes.TOWNY_COMMAND_PLOT_DISTRICT_ADD, - Icons.icon(Material.BARREL, tr("plot-group.district-add"), tr("plot-group.district-add-description")) + Icons.icon( + Material.BARREL, tr("plot-group.district-add"), tr("plot-group.district-add-description"), + actions = hints("click.type-name") + ) ) { prompt(tr("plot-group.district-add-title"), tr("plot-group.district-name")) { name -> run("towny:plot district add ${TownyUtil.nameArgument(name)}", districtProbe) @@ -108,13 +120,13 @@ class PlotGroupMenu(player: Player, back: Menu) : Menu(player, player.tr("plot-g if (district != null) { districts.add( PermissionNodes.TOWNY_COMMAND_PLOT_DISTRICT_REMOVE, - Icons.icon(Material.HOPPER, tr("plot-group.district-remove"), null) + Icons.icon(Material.HOPPER, tr("plot-group.district-remove"), null, actions = hints("click.remove")) ) { run("towny:plot district remove", districtProbe) } districts.add( PermissionNodes.TOWNY_COMMAND_PLOT_DISTRICT_RENAME, - Icons.icon(Material.NAME_TAG, tr("plot-group.district-rename"), null) + Icons.icon(Material.NAME_TAG, tr("plot-group.district-rename"), null, actions = hints("click.rename")) ) { prompt(tr("plot-group.district-rename-title"), tr("common.new-name"), initial = district.name) { name -> run("towny:plot district rename ${TownyUtil.nameArgument(name)}", districtProbe) @@ -122,7 +134,10 @@ class PlotGroupMenu(player: Player, back: Menu) : Menu(player, player.tr("plot-g } districts.add( PermissionNodes.TOWNY_COMMAND_PLOT_DISTRICT_DELETE, - Icons.icon(Material.LAVA_BUCKET, tr("plot-group.district-delete"), null) + Icons.icon( + Material.LAVA_BUCKET, tr("plot-group.district-delete"), null, + actions = hints("click.delete") + ) ) { run("towny:plot district delete", districtProbe) } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotMenu.kt index db61244..5f1aa76 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotMenu.kt @@ -40,14 +40,20 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title if (plot == null) wilderness() else claimed(plot) guarded( 48, PermissionNodes.TOWNY_COMMAND_PLOT_PERM_HUD, - Icons.icon(Material.SPYGLASS, tr("plot.hud"), tr("plot.hud-description")) + Icons.icon(Material.SPYGLASS, tr("plot.hud"), tr("plot.hud-description"), actions = hints("click.show-hud")) ) { runAndClose("towny:plot perm hud") } - button(47, Icons.icon(Material.FILLED_MAP, tr("main.map"), tr("common.map-description"))) { + button(47, Icons.icon( + Material.FILLED_MAP, tr("main.map"), tr("common.map-description"), + actions = hints("click.open") + )) { MapMenu(player, this).open() } - button(50, Icons.icon(Material.CLOCK, tr("map.refresh"), tr("plot.refresh-description"))) { render() } + button(50, Icons.icon( + Material.CLOCK, tr("map.refresh"), tr("plot.refresh-description"), + actions = hints("click.refresh") + )) { render() } tutorialButton(53, Tutorial.PLOTS) backButton(49) } @@ -69,7 +75,8 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title Material.GRASS_BLOCK, tr("plot.claim", "town" to TownyUtil.name(town.name)), tr("plot.claim-description"), - *listOfNotNull(costLine(Prices.claim(town))).toTypedArray() + *listOfNotNull(costLine(Prices.claim(town))).toTypedArray(), + actions = hints("click.claim") ) ) { run("towny:town claim", { town.numTownBlocks }, delayTicks = 20) @@ -78,13 +85,17 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title PermissionNodes.TOWNY_COMMAND_TOWN_CLAIM_OUTPOST, Icons.icon( Material.COMPASS, tr("plot.claim-outpost"), tr("plot.claim-outpost-description"), - *outpostCost().toTypedArray() + *outpostCost().toTypedArray(), + actions = hints("click.claim") ) ) { run("towny:town claim outpost", { town.numTownBlocks }, delayTicks = 20) } } - grid.add(Icons.icon(Material.MAP, tr("plot.area"), tr("plot.area-description"))) { + grid.add(Icons.icon( + Material.MAP, tr("plot.area"), tr("plot.area-description"), + actions = hints("click.open") + )) { PlotAreaMenu(player, this).open() } } @@ -150,14 +161,18 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title grid.add( PermissionNodes.TOWNY_COMMAND_PLOT_CLAIM, Icons.icon( Material.EMERALD, tr("plot.buy"), tr("plot.buy-description"), - *listOfNotNull(priceLine(price)).toTypedArray() + *listOfNotNull(priceLine(price)).toTypedArray(), + actions = hints("click.buy") ) ) { run("towny:plot claim", ownerProbe) } } if (owner != null && owner == viewer) { grid.add( PermissionNodes.TOWNY_COMMAND_PLOT_UNCLAIM, - Icons.icon(Material.COARSE_DIRT, tr("plot.give-up"), tr("plot.give-up-description")) + Icons.icon( + Material.COARSE_DIRT, tr("plot.give-up"), tr("plot.give-up-description"), + actions = hints("click.give-up") + ) ) { run("towny:plot unclaim", ownerProbe) } @@ -169,7 +184,8 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title Material.RED_BANNER, tr("plot.not-for-sale"), tr("plot.not-for-sale-description"), - *groupLines + *groupLines, + actions = hints("click.stop-selling") ) ) { run("$scope notforsale", saleProbe) @@ -177,7 +193,10 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title } else { grid.add( if (group != null) PermissionNodes.TOWNY_COMMAND_PLOT_GROUP_FORSALE else PermissionNodes.TOWNY_COMMAND_PLOT_FORSALE, - Icons.icon(Material.GREEN_BANNER, tr("plot.for-sale"), tr("plot.for-sale-description"), *groupLines) + Icons.icon( + Material.GREEN_BANNER, tr("plot.for-sale"), tr("plot.for-sale-description"), *groupLines, + actions = hints("click.set-price") + ) ) { prompt( tr("plot.for-sale-title"), @@ -197,8 +216,8 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title Material.IRON_BOOTS, tr("plot.evict"), tr("plot.evict-description", "owner" to TownyUtil.name(owner.name)), - *listOfNotNull(if (group == null) tr("plot.evict-resell") else null).toTypedArray(), - *groupLines + *groupLines, + actions = listOfNotNull(tr("click.evict"), if (group == null) tr("plot.evict-resell") else null) ) ) { click -> run( @@ -211,7 +230,8 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title Icons.icon( Material.OAK_SIGN, tr("plot.type"), tr("plot.type-description"), tr("common.current", "value" to TownyUtil.plotType(player, plot.type.name)), - *groupLines + *groupLines, + actions = hints("click.choose") ) ) { val types = listOf("reset" to "${TownyUtil.plotType(player, "default")}") + @@ -232,7 +252,10 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title } grid.add( PermissionNodes.TOWNY_COMMAND_PLOT_SET_NAME, - Icons.icon(Material.NAME_TAG, tr("plot.rename"), tr("plot.rename-description")) + Icons.icon( + Material.NAME_TAG, tr("plot.rename"), tr("plot.rename-description"), + actions = hints("click.left-rename", "click.clear") + ) ) { click -> if (click.isRightClick) { run("towny:plot set name", { plot.name }) @@ -242,14 +265,20 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title } } } - grid.add(Icons.icon(Material.LEVER, tr("plot.settings"), tr("plot.settings-description"), *groupLines)) { + grid.add(Icons.icon( + Material.LEVER, tr("plot.settings"), tr("plot.settings-description"), *groupLines, + actions = hints("click.open") + )) { toggles(plot, group != null).open() } val permNode = if (group != null) PermissionNodes.TOWNY_COMMAND_PLOT_GROUP_SET else PermissionNodes.TOWNY_COMMAND_PLOT_SET_PERM grid.add( permNode, - Icons.icon(Material.IRON_DOOR, tr("common.permissions"), tr("plot.permissions-description"), *groupLines) + Icons.icon( + Material.IRON_DOOR, tr("common.permissions"), tr("plot.permissions-description"), *groupLines, + actions = hints("click.edit-permissions") + ) ) { PermissionMenu( player, tr("plot.permissions-title"), this, "$scope set perm", permNode, owner != null, @@ -261,7 +290,8 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title Icons.icon( Material.TRIPWIRE_HOOK, tr("plot.trusted"), tr("plot.trusted-description"), tr("plot.trusted-count", "count" to (group?.trustedResidents ?: plot.trustedResidents).size), - *groupLines + *groupLines, + actions = hints("click.view") ) ) { PlotTrustMenu(player, plot, this).open() } grid.add( @@ -269,7 +299,8 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title Icons.icon( Material.CLOCK, tr("plot.join-days"), tr("plot.join-days-description"), *joinDayLines(plot, group).ifEmpty { listOf(tr("plot.join-days-none")) }.toTypedArray(), - *groupLines + *groupLines, + actions = hints("plot.left-min-days", "plot.right-max-days") ) ) { click -> val key = if (click.isRightClick) "maxjoindays" else "minjoindays" @@ -292,7 +323,8 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title PermissionNodes.TOWNY_COMMAND_PLOT_JAILCELL, Icons.icon( Material.IRON_CHAIN, tr("plot.jail-cells"), tr("plot.jail-cells-description"), - tr("plot.jail-cells-count", "count" to (plot.jail?.jailCellCount ?: 0)) + tr("plot.jail-cells-count", "count" to (plot.jail?.jailCellCount ?: 0)), + actions = hints("plot.left-add-cell", "plot.right-remove-cell") ) ) { click -> run( @@ -304,7 +336,10 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title if (plot.isOutpost) { grid.add( PermissionNodes.TOWNY_COMMAND_TOWN_SET_OUTPOST, - Icons.icon(Material.RESPAWN_ANCHOR, tr("plot.outpost-spawn"), tr("plot.outpost-spawn-description")) + Icons.icon( + Material.RESPAWN_ANCHOR, tr("plot.outpost-spawn"), tr("plot.outpost-spawn-description"), + actions = hints("click.set-here") + ) ) { run("towny:plot set outpost spawn", { town.allOutpostSpawns.toList() }) } @@ -313,27 +348,40 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title PermissionNodes.TOWNY_COMMAND_TOWN_CLAIM_OUTPOST, Icons.icon( Material.COMPASS, tr("plot.make-outpost"), tr("plot.make-outpost-description"), - *outpostCost().toTypedArray() + *outpostCost().toTypedArray(), + actions = hints("click.make-outpost") ) ) { run("towny:plot set outpost", { plot.isOutpost to town.allOutpostSpawns.size }) } } } - grid.add(Icons.icon(Material.CHEST, tr("plot.groups"), tr("plot.groups-description"))) { + grid.add(Icons.icon( + Material.CHEST, tr("plot.groups"), tr("plot.groups-description"), + actions = hints("click.open") + )) { PlotGroupMenu(player, this).open() } grid.add( PermissionNodes.TOWNY_COMMAND_PLOT_CLEAR, - Icons.icon(Material.BRUSH, tr("plot.clear"), tr("plot.clear-description")) + Icons.icon( + Material.BRUSH, tr("plot.clear"), tr("plot.clear-description"), + actions = hints("click.clear-plot") + ) ) { runAndClose("towny:plot clear") } - grid.add(Icons.icon(Material.MAP, tr("plot.area"), tr("plot.area-description"))) { + grid.add(Icons.icon( + Material.MAP, tr("plot.area"), tr("plot.area-description"), + actions = hints("click.open") + )) { PlotAreaMenu(player, this).open() } if (town != null) { - button(46, Icons.icon(Material.BELL, "${TownyUtil.name(town.name)}", tr("plot.town-description"))) { + button(46, Icons.icon( + Material.BELL, "${TownyUtil.name(town.name)}", tr("plot.town-description"), + actions = hints("click.view") + )) { TownInfoMenu(player, town, this).open() } } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotOverridesMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotOverridesMenu.kt index 0de8d89..9433cb0 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotOverridesMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotOverridesMenu.kt @@ -55,7 +55,10 @@ class PlotOverridesMenu(player: Player, private val plot: TownBlock, back: Menu) val addNode = node(PermissionNodes.TOWNY_COMMAND_PLOT_GROUP_PERM, PermissionNodes.TOWNY_COMMAND_PLOT_PERM_ADD) guarded( 47, addNode, - Icons.icon(Material.PLAYER_HEAD, tr("plot-overrides.add-online"), tr("plot-overrides.add-description")) + Icons.icon( + Material.PLAYER_HEAD, tr("plot-overrides.add-online"), tr("plot-overrides.add-description"), + actions = hints("click.choose-player") + ) ) { Pickers.resident(this, tr("plot-overrides.add-title"), { it !in overrides() }) { picked -> run("$command add ${picked.name}", ::snapshot) @@ -63,7 +66,10 @@ class PlotOverridesMenu(player: Player, private val plot: TownBlock, back: Menu) } guarded( 48, addNode, - Icons.icon(Material.NAME_TAG, tr("plot-overrides.add-name"), tr("plot-overrides.add-description")) + Icons.icon( + Material.NAME_TAG, tr("plot-overrides.add-name"), tr("plot-overrides.add-description"), + actions = hints("click.type-name") + ) ) { prompt(tr("plot-overrides.add-title"), tr("common.player-name")) { name -> run("$command add ${TownyUtil.argument(name)}", ::snapshot) @@ -71,7 +77,10 @@ class PlotOverridesMenu(player: Player, private val plot: TownBlock, back: Menu) } guarded( 51, node(PermissionNodes.TOWNY_COMMAND_PLOT_GROUP_PERM, PermissionNodes.TOWNY_COMMAND_PLOT_PERM_GUI), - Icons.icon(Material.WRITABLE_BOOK, tr("plot-overrides.edit"), tr("plot-overrides.edit-description")) + Icons.icon( + Material.WRITABLE_BOOK, tr("plot-overrides.edit"), tr("plot-overrides.edit-description"), + actions = hints("click.open-editor") + ) ) { runAndClose("$command gui") } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotTrustMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotTrustMenu.kt index ffd1ae1..d6e5180 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotTrustMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotTrustMenu.kt @@ -37,7 +37,7 @@ class PlotTrustMenu(player: Player, private val plot: TownBlock, back: Menu) : override fun entries(): List = trusted().sortedBy { it.name.lowercase() }.map { trusted -> - MenuEntry({ Icons.resident(player, trusted, actions = listOf(tr("common.click-untrust"))) }) { + MenuEntry({ Icons.resident(player, trusted, actions = listOf(tr("click.untrust"))) }) { run("$command remove ${trusted.name}", ::count) } } @@ -46,7 +46,10 @@ class PlotTrustMenu(player: Player, private val plot: TownBlock, back: Menu) : tutorialButton(52, Tutorial.PLOTS) guarded( 47, node, - Icons.icon(Material.PLAYER_HEAD, tr("common.trust-online"), tr("plot-trust.trust-online-description")) + Icons.icon( + Material.PLAYER_HEAD, tr("common.trust-online"), tr("plot-trust.trust-online-description"), + actions = hints("click.choose-player") + ) ) { Pickers.resident(this, tr("plot-trust.trust-title"), { it !in trusted() }) { picked -> run("$command add ${picked.name}", ::count) @@ -54,7 +57,10 @@ class PlotTrustMenu(player: Player, private val plot: TownBlock, back: Menu) : } guarded( 48, node, - Icons.icon(Material.NAME_TAG, tr("common.trust-name"), tr("common.trust-name-description")) + Icons.icon( + Material.NAME_TAG, tr("common.trust-name"), tr("common.trust-name-description"), + actions = hints("click.type-name") + ) ) { prompt( tr("plot-trust.trust-title"), diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/FriendsMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/FriendsMenu.kt index 48d6b83..a6519b7 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/FriendsMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/FriendsMenu.kt @@ -34,7 +34,10 @@ class FriendsMenu(player: Player, back: Menu) : PagedMenu(player, player.tr("fri override fun controls() { tutorialButton(52, Tutorial.PROTECTION) - button(47, Icons.icon(Material.PLAYER_HEAD, tr("friends.add-online"), tr("friends.add-online-description"))) { + button(47, Icons.icon( + Material.PLAYER_HEAD, tr("friends.add-online"), tr("friends.add-online-description"), + actions = hints("click.choose-player") + )) { Pickers.resident( this, tr("friends.add-title"), @@ -42,7 +45,10 @@ class FriendsMenu(player: Player, back: Menu) : PagedMenu(player, player.tr("fri run("towny:resident friend add ${picked.name}", ::friendNames) }.open() } - button(51, Icons.icon(Material.NAME_TAG, tr("friends.add-name"), tr("friends.add-name-description"))) { + button(51, Icons.icon( + Material.NAME_TAG, tr("friends.add-name"), tr("friends.add-name-description"), + actions = hints("click.type-name") + )) { prompt(tr("friends.add-title"), tr("common.player-name")) { name -> run("towny:resident friend add ${TownyUtil.argument(name)}", ::friendNames) } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/ResidentMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/ResidentMenu.kt index f3eb2ae..354089b 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/ResidentMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/ResidentMenu.kt @@ -52,22 +52,34 @@ class ResidentMenu(player: Player, back: Menu?) : Menu(player, player.tr("profil val row = layout(19, 20, 21, 22, 23, 24, 25) row.add( PermissionNodes.TOWNY_COMMAND_RESIDENT_FRIEND, - Icons.icon(Material.POPPY, tr("profile.friends"), tr("profile.friends-description")) + Icons.icon( + Material.POPPY, tr("profile.friends"), tr("profile.friends-description"), + actions = hints("click.view") + ) ) { FriendsMenu(player, this).open() } - row.add(Icons.icon(Material.LEVER, tr("profile.settings"), tr("profile.settings-description"))) { + row.add(Icons.icon( + Material.LEVER, tr("profile.settings"), tr("profile.settings-description"), + actions = hints("click.open") + )) { toggles().open() } row.add( PermissionNodes.TOWNY_COMMAND_RESIDENT_SET_PERM, - Icons.icon(Material.IRON_DOOR, tr("profile.permissions"), tr("profile.permissions-description")) + Icons.icon( + Material.IRON_DOOR, tr("profile.permissions"), tr("profile.permissions-description"), + actions = hints("click.edit-permissions") + ) ) { permissions().open() } row.add( PermissionNodes.TOWNY_COMMAND_RESIDENT_SET_ABOUT, - Icons.icon(Material.WRITABLE_BOOK, tr("profile.about"), tr("profile.about-description")) + Icons.icon( + Material.WRITABLE_BOOK, tr("profile.about"), tr("profile.about-description"), + actions = hints("click.edit", "click.clear") + ) ) { click -> if (click.isRightClick) { run("towny:resident set about none", { resident.about }) @@ -86,7 +98,8 @@ class ResidentMenu(player: Player, back: Menu?) : Menu(player, player.tr("profil PermissionNodes.TOWNY_COMMAND_RESIDENT_SPAWN, Icons.icon( Material.RED_BED, tr("profile.spawn"), tr("profile.spawn-description"), - *listOfNotNull(costLine(Prices.residentSpawn(player))).toTypedArray() + *listOfNotNull(costLine(Prices.residentSpawn(player))).toTypedArray(), + actions = hints("click.teleport") ) ) { runAndClose("towny:resident spawn") @@ -98,7 +111,8 @@ class ResidentMenu(player: Player, back: Menu?) : Menu(player, player.tr("profil tr( "profile.modes-active", "modes" to resident.modes.ifEmpty { listOf(tr("common.none")) }.joinToString(", ") - ) + ), + actions = hints("profile.left-modes-off", "profile.right-modes-reset") ) ) { click -> run("towny:resident set mode ${if (click.isRightClick) "reset" else "clear"}", { resident.modes.toSet() }) @@ -107,7 +121,8 @@ class ResidentMenu(player: Player, back: Menu?) : Menu(player, player.tr("profil row.add( Icons.icon( Material.IRON_BARS, tr("profile.bail"), - tr("profile.bail-description", "cost" to TownyUtil.money(resident.jailBailCost)) + tr("profile.bail-description", "cost" to TownyUtil.money(resident.jailBailCost)), + actions = hints("click.pay") ) ) { run("towny:resident jail paybail", { resident.isJailed }) @@ -125,7 +140,8 @@ class ResidentMenu(player: Player, back: Menu?) : Menu(player, player.tr("profil 37, PermissionNodes.TOWNY_COMMAND_RESIDENT_PLOTLIST, Icons.icon( Material.GRASS_BLOCK, tr("profile.plots"), tr("profile.plots-description"), - tr("profile.plots-owned", "count" to resident.townBlocks.size) + tr("profile.plots-owned", "count" to resident.townBlocks.size), + actions = hints("click.view") ) ) { ResidentPlotsMenu(player, resident, this).open() @@ -137,7 +153,8 @@ class ResidentMenu(player: Player, back: Menu?) : Menu(player, player.tr("profil 42, PermissionNodes.TOWNY_COMMAND_RESIDENT_OUTLAWLIST, Icons.icon( Material.IRON_BARS, tr("profile.outlawed-in"), tr("profile.outlawed-in-description"), - tr("profile.towns-count", "count" to resident.townsOutlawedIn.size) + tr("profile.towns-count", "count" to resident.townsOutlawedIn.size), + actions = hints("click.view") ) ) { towns(tr("profile.outlawed-in-title")) { it.townsOutlawedIn }.open() @@ -146,7 +163,8 @@ class ResidentMenu(player: Player, back: Menu?) : Menu(player, player.tr("profil 43, PermissionNodes.TOWNY_COMMAND_RESIDENT_TRUSTLIST, Icons.icon( Material.TRIPWIRE_HOOK, tr("profile.trusted-in"), tr("profile.trusted-in-description"), - tr("profile.towns-count", "count" to resident.townsTrustedIn.size) + tr("profile.towns-count", "count" to resident.townsTrustedIn.size), + actions = hints("click.view") ) ) { towns(tr("profile.trusted-in-title")) { it.townsTrustedIn }.open() @@ -183,7 +201,7 @@ class ResidentMenu(player: Player, back: Menu?) : Menu(player, player.tr("profil TownyAPI.getInstance().getResident(player)?.let(source).orEmpty() .sortedBy { it.name.lowercase() } .map { town -> - MenuEntry({ Icons.town(player, town, actions = listOf(tr("common.click-details"))) }) { + MenuEntry({ Icons.town(player, town, actions = listOf(tr("click.details"))) }) { TownInfoMenu(player, town, menu).open() } } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/ResidentPlotsMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/ResidentPlotsMenu.kt index 23748ba..d714de5 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/ResidentPlotsMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/ResidentPlotsMenu.kt @@ -56,7 +56,7 @@ class ResidentPlotsMenu(player: Player, private val owner: Resident, back: Menu) ) } }.toTypedArray(), - actions = listOfNotNull(if (town != null) tr("common.click-details") else null) + actions = listOfNotNull(if (town != null) tr("click.details") else null) ) }) { town?.let { TownInfoMenu(player, it, this).open() } } } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/ResidentProfileMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/ResidentProfileMenu.kt index ec39027..2bea998 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/ResidentProfileMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/ResidentProfileMenu.kt @@ -40,6 +40,7 @@ class ResidentProfileMenu(player: Player, private val target: Resident, back: Me if (friend) Material.WITHER_ROSE else Material.POPPY, tr(if (friend) "resident-profile.remove-friend" else "resident-profile.add-friend"), tr("profile.friends-description"), + actions = hints(if (friend) "click.remove" else "click.add") ) ) { run( @@ -54,7 +55,8 @@ class ResidentProfileMenu(player: Player, private val target: Resident, back: Me Icons.icon( Material.NAME_TAG, tr("resident-profile.town-ranks"), - tr("resident-profile.town-ranks-description") + tr("resident-profile.town-ranks-description"), + actions = hints("click.edit-ranks") ) ) { RankMenu.create(player, target, false, this).open() @@ -64,7 +66,8 @@ class ResidentProfileMenu(player: Player, private val target: Resident, back: Me Icons.icon( Material.OAK_HANGING_SIGN, tr("resident-profile.title"), - tr("resident-profile.title-description") + tr("resident-profile.title-description"), + actions = hints("click.edit", "click.clear") ) ) { click -> editTitle( @@ -79,7 +82,8 @@ class ResidentProfileMenu(player: Player, private val target: Resident, back: Me Icons.icon( Material.OAK_SIGN, tr("resident-profile.surname"), - tr("resident-profile.surname-description") + tr("resident-profile.surname-description"), + actions = hints("click.edit", "click.clear") ) ) { click -> editTitle( @@ -95,7 +99,8 @@ class ResidentProfileMenu(player: Player, private val target: Resident, back: Me Icons.icon( Material.GOLDEN_HELMET, tr("resident-profile.make-mayor"), - tr("resident-profile.make-mayor-description") + tr("resident-profile.make-mayor-description"), + actions = hints("click.make-mayor") ) ) { run("towny:town set mayor ${target.name}", { town.mayor }) @@ -105,7 +110,8 @@ class ResidentProfileMenu(player: Player, private val target: Resident, back: Me Icons.icon( Material.IRON_BOOTS, tr("resident-profile.kick"), - tr("resident-profile.kick-description") + tr("resident-profile.kick-description"), + actions = hints("click.kick") ) ) { run( @@ -124,6 +130,7 @@ class ResidentProfileMenu(player: Player, private val target: Resident, back: Me Material.TRIPWIRE_HOOK, tr(if (trusted) "resident-profile.untrust" else "resident-profile.trust"), tr("resident-profile.trust-description"), + actions = hints(if (trusted) "click.untrust" else "click.trust") ) ) { run( @@ -139,13 +146,17 @@ class ResidentProfileMenu(player: Player, private val target: Resident, back: Me Material.IRON_BARS, tr(if (outlaw) "resident-profile.pardon" else "resident-profile.outlaw"), tr("resident-profile.outlaw-description"), + actions = hints(if (outlaw) "click.pardon" else "click.outlaw") ) ) { run("towny:town outlaw ${if (outlaw) "remove" else "add"} ${target.name}", { town.hasOutlaw(target) }) } if (!target.hasTown()) { actions.add( PermissionNodes.TOWNY_COMMAND_TOWN_INVITE_ADD, - Icons.icon(Material.PAPER, tr("resident-profile.invite"), tr("resident-profile.invite-description")) + Icons.icon( + Material.PAPER, tr("resident-profile.invite"), tr("resident-profile.invite-description"), + actions = hints("click.invite") + ) ) { run("towny:town add ${target.name}", { town.sentInvites.size }) } @@ -158,7 +169,8 @@ class ResidentProfileMenu(player: Player, private val target: Resident, back: Me Icons.icon( Material.NAME_TAG, tr("resident-profile.nation-ranks"), - tr("resident-profile.nation-ranks-description") + tr("resident-profile.nation-ranks-description"), + actions = hints("click.edit-ranks") ) ) { RankMenu.create(player, target, true, this).open() @@ -169,7 +181,8 @@ class ResidentProfileMenu(player: Player, private val target: Resident, back: Me Icons.icon( Material.GOLDEN_HELMET, tr("resident-profile.make-leader"), - tr("resident-profile.make-leader-description") + tr("resident-profile.make-leader-description"), + actions = hints("click.make-leader") ) ) { run("towny:nation set king ${target.name}", { nation.king }) diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/JailSentenceMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/JailSentenceMenu.kt index 96e4e3f..ad19db0 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/JailSentenceMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/JailSentenceMenu.kt @@ -47,7 +47,8 @@ class JailSentenceMenu(player: Player, private val town: Town, private val targe Icons.icon( Material.CLOCK, tr("jail-sentence.hours"), tr("jail-sentence.hours-description"), tr("common.current", "value" to hours), - tr("jail-sentence.max-hours", "hours" to TownySettings.getJailedMaxHours()) + tr("jail-sentence.max-hours", "hours" to TownySettings.getJailedMaxHours()), + actions = hints("click.set") ) ) { prompt(tr("jail-sentence.hours-title"), tr("jail-sentence.hours-label"), initial = hours, maxLength = 5) { @@ -60,7 +61,8 @@ class JailSentenceMenu(player: Player, private val town: Town, private val targe Icons.icon( Material.GOLD_NUGGET, tr("jail-sentence.bail"), tr("jail-sentence.bail-description"), tr("common.current", "value" to bail), - tr("jail-sentence.max-bail", "bail" to TownyUtil.money(TownySettings.getBailMaxAmount())) + tr("jail-sentence.max-bail", "bail" to TownyUtil.money(TownySettings.getBailMaxAmount())), + actions = hints("click.set") ) ) { prompt(tr("jail-sentence.bail-title"), tr("common.amount"), initial = bail, maxLength = 12) { @@ -74,7 +76,7 @@ class JailSentenceMenu(player: Player, private val town: Town, private val targe Icons.icon( Material.IRON_BARS, tr("jail-sentence.jail"), null, tr("common.current", "value" to TownJailMenu.jailName(this, town, jail)), - actions = listOf(tr("common.click-change")) + actions = listOf(tr("click.change")) ) ) { val options = jails.mapIndexed { index, option -> @@ -92,7 +94,7 @@ class JailSentenceMenu(player: Player, private val town: Town, private val targe Icons.icon( Material.IRON_CHAIN, tr("jail-sentence.cell"), null, tr("common.current", "value" to cell + 1), - actions = listOf(tr("common.click-change")) + actions = listOf(tr("click.change")) ) ) { val options = (0 until jail.jailCellCount).map { @@ -106,7 +108,10 @@ class JailSentenceMenu(player: Player, private val town: Town, private val targe } row.add( PermissionNodes.TOWNY_COMMAND_TOWN_JAIL, - Icons.icon(Material.LIME_CONCRETE, tr("jail-sentence.confirm"), tr("jail-sentence.confirm-description")) + Icons.icon( + Material.LIME_CONCRETE, tr("jail-sentence.confirm"), tr("jail-sentence.confirm-description"), + actions = hints("click.jail") + ) ) { val bailArgument = if (bailEnabled) " $bail" else "" run( diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/NoTownMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/NoTownMenu.kt index af8ed1e..20e7b21 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/NoTownMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/NoTownMenu.kt @@ -26,7 +26,8 @@ class NoTownMenu(player: Player, back: Menu) : Menu(player, player.tr("no-town.t Material.BELL, tr("no-town.found"), tr("no-town.found-description"), - *listOfNotNull(price).toTypedArray() + *listOfNotNull(price).toTypedArray(), + actions = hints("click.found") ) ) { prompt(tr("no-town.found-title"), tr("no-town.town-name")) { name -> @@ -37,7 +38,10 @@ class NoTownMenu(player: Player, back: Menu) : Menu(player, player.tr("no-town.t ) } } - row.add(Icons.icon(Material.OAK_DOOR, tr("no-town.browse"), tr("no-town.browse-description"))) { + row.add(Icons.icon( + Material.OAK_DOOR, tr("no-town.browse"), tr("no-town.browse-description"), + actions = hints("click.browse") + )) { TownListMenu(player, this).open() } val invites = resident?.receivedInvites?.size ?: 0 @@ -46,7 +50,8 @@ class NoTownMenu(player: Player, back: Menu) : Menu(player, player.tr("no-town.t Material.PAPER, tr("main.invites"), tr("no-town.invites-description"), - tr("common.pending", "count" to invites) + tr("common.pending", "count" to invites), + actions = hints("click.view") ) ) { InvitesMenu(player, this).open() @@ -57,7 +62,8 @@ class NoTownMenu(player: Player, back: Menu) : Menu(player, player.tr("no-town.t PermissionNodes.TOWNY_COMMAND_TOWN_RECLAIM, Icons.icon( Material.MOSSY_STONE_BRICKS, tr("no-town.reclaim"), tr("no-town.reclaim-description"), - *listOfNotNull(cost).toTypedArray() + *listOfNotNull(cost).toTypedArray(), + actions = hints("click.reclaim") ) ) { run("towny:town reclaim", { resident?.hasTown() }, returnTo = back ?: MainMenu(player)) diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/OutlawsMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/OutlawsMenu.kt index ed778aa..317d52a 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/OutlawsMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/OutlawsMenu.kt @@ -37,7 +37,10 @@ class OutlawsMenu(player: Player, private val town: Town, back: Menu) : tutorialButton(52, Tutorial.PROTECTION) guarded( 47, PermissionNodes.TOWNY_COMMAND_TOWN_OUTLAW, - Icons.icon(Material.PLAYER_HEAD, tr("outlaws.add-online"), tr("outlaws.add-online-description")) + Icons.icon( + Material.PLAYER_HEAD, tr("outlaws.add-online"), tr("outlaws.add-online-description"), + actions = hints("click.choose-player") + ) ) { Pickers.resident(this, tr("outlaws.declare"), { it.townOrNull != town && !town.hasOutlaw(it) }) { picked -> run("towny:town outlaw add ${picked.name}", ::count) @@ -45,7 +48,10 @@ class OutlawsMenu(player: Player, private val town: Town, back: Menu) : } guarded( 48, PermissionNodes.TOWNY_COMMAND_TOWN_OUTLAW, - Icons.icon(Material.NAME_TAG, tr("outlaws.add-name"), tr("outlaws.add-name-description")) + Icons.icon( + Material.NAME_TAG, tr("outlaws.add-name"), tr("outlaws.add-name-description"), + actions = hints("click.type-name") + ) ) { prompt( tr("outlaws.declare"), diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/OutpostsMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/OutpostsMenu.kt index 1d465de..a14fc2e 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/OutpostsMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/OutpostsMenu.kt @@ -23,7 +23,7 @@ class OutpostsMenu(player: Player, private val town: Town, back: Menu) : tr("outposts.world", "world" to (location.world?.name ?: "-")), tr("outposts.location", "x" to location.blockX, "y" to location.blockY, "z" to location.blockZ), *listOfNotNull(cost).toTypedArray(), - actions = listOf(tr("common.click-teleport")) + actions = listOf(tr("click.teleport")) ) } MenuEntry(icon) { runAndClose("towny:town outpost ${index + 1}") } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownClaimsMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownClaimsMenu.kt index 4daa5ed..7ab5b47 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownClaimsMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownClaimsMenu.kt @@ -25,6 +25,7 @@ class TownClaimsMenu(player: Player, back: Menu) : Menu(player, player.tr("claim button(4, Icons.icon(Material.GRASS_BLOCK, tr("claims.info"), null, *buildList { add(tr("claims.claimed", "claims" to town.numTownBlocks, "max" to town.maxTownBlocksAsAString)) + if (!town.hasUnlimitedClaims()) add(progressBar(town.numTownBlocks, town.maxTownBlocks)) add( tr( "claims.available", @@ -43,7 +44,8 @@ class TownClaimsMenu(player: Player, back: Menu) : Menu(player, player.tr("claim PermissionNodes.TOWNY_COMMAND_TOWN_CLAIM_TOWN, Icons.icon( Material.GRASS_BLOCK, tr("claims.claim"), tr("claims.claim-description"), - *listOfNotNull(costLine(Prices.claim(town))).toTypedArray() + *listOfNotNull(costLine(Prices.claim(town))).toTypedArray(), + actions = hints("click.claim") ) ) { run("towny:town claim", claims, delayTicks = CLAIM_DELAY) @@ -52,7 +54,8 @@ class TownClaimsMenu(player: Player, back: Menu) : Menu(player, player.tr("claim PermissionNodes.TOWNY_COMMAND_TOWN_CLAIM_TOWN_MULTIPLE, Icons.icon( Material.MOSS_BLOCK, tr("claims.claim-area"), tr("claims.claim-area-description"), - *perClaim(town) + *perClaim(town), + actions = hints("click.choose-radius") ) ) { prompt( @@ -67,7 +70,10 @@ class TownClaimsMenu(player: Player, back: Menu) : Menu(player, player.tr("claim } grid.add( PermissionNodes.TOWNY_COMMAND_TOWN_CLAIM_FILL, - Icons.icon(Material.BONE_MEAL, tr("claims.fill"), tr("claims.fill-description"), *perClaim(town)) + Icons.icon( + Material.BONE_MEAL, tr("claims.fill"), tr("claims.fill-description"), *perClaim(town), + actions = hints("click.claim") + ) ) { run("towny:town claim fill", claims, delayTicks = CLAIM_DELAY) } @@ -76,7 +82,8 @@ class TownClaimsMenu(player: Player, back: Menu) : Menu(player, player.tr("claim PermissionNodes.TOWNY_COMMAND_TOWN_CLAIM_OUTPOST, Icons.icon( Material.COMPASS, tr("claims.outpost"), tr("claims.outpost-description"), - *listOfNotNull(costLine(Prices.outpost())).toTypedArray() + *listOfNotNull(costLine(Prices.outpost())).toTypedArray(), + actions = hints("click.claim") ) ) { run("towny:town claim outpost", claims, delayTicks = CLAIM_DELAY) @@ -84,13 +91,19 @@ class TownClaimsMenu(player: Player, back: Menu) : Menu(player, player.tr("claim } grid.add( PermissionNodes.TOWNY_COMMAND_TOWN_UNCLAIM, - Icons.icon(Material.COARSE_DIRT, tr("claims.unclaim"), tr("claims.unclaim-description"), *perUnclaim()) + Icons.icon( + Material.COARSE_DIRT, tr("claims.unclaim"), tr("claims.unclaim-description"), *perUnclaim(), + actions = hints("click.unclaim") + ) ) { run("towny:town unclaim", claims, delayTicks = CLAIM_DELAY) } grid.add( PermissionNodes.TOWNY_COMMAND_TOWN_UNCLAIM, - Icons.icon(Material.DIRT, tr("claims.unclaim-area"), tr("claims.unclaim-area-description"), *perUnclaim()) + Icons.icon( + Material.DIRT, tr("claims.unclaim-area"), tr("claims.unclaim-area-description"), *perUnclaim(), + actions = hints("click.choose-radius") + ) ) { prompt(tr("claims.unclaim-area-title"), tr("claims.radius"), initial = "1", maxLength = 3) { radius -> run("towny:town unclaim rect ${TownyUtil.argument(radius)}", claims, delayTicks = CLAIM_DELAY) @@ -99,7 +112,8 @@ class TownClaimsMenu(player: Player, back: Menu) : Menu(player, player.tr("claim grid.add( PermissionNodes.TOWNY_COMMAND_TOWN_UNCLAIM_ALL, Icons.icon( - Material.LAVA_BUCKET, tr("claims.unclaim-all"), tr("claims.unclaim-all-description"), *perUnclaim() + Material.LAVA_BUCKET, tr("claims.unclaim-all"), tr("claims.unclaim-all-description"), *perUnclaim(), + actions = hints("click.unclaim") ) ) { run("towny:town unclaim all", claims, delayTicks = CLAIM_DELAY) @@ -109,7 +123,8 @@ class TownClaimsMenu(player: Player, back: Menu) : Menu(player, player.tr("claim PermissionNodes.TOWNY_COMMAND_TOWN_BUY_BONUS, Icons.icon( Material.EMERALD_BLOCK, tr("claims.buy-bonus"), tr("claims.buy-bonus-description"), - tr("claims.price-each", "price" to TownyUtil.money(town.bonusBlockCost)) + tr("claims.price-each", "price" to TownyUtil.money(town.bonusBlockCost)), + actions = hints("click.buy") ) ) { prompt( @@ -124,7 +139,10 @@ class TownClaimsMenu(player: Player, back: Menu) : Menu(player, player.tr("claim } grid.add( PermissionNodes.TOWNY_COMMAND_TOWN_CEDE_PLOT, - Icons.icon(Material.OAK_BOAT, tr("claims.cede"), tr("claims.cede-description")) + Icons.icon( + Material.OAK_BOAT, tr("claims.cede"), tr("claims.cede-description"), + actions = hints("click.choose-town") + ) ) { Pickers.town(this, tr("claims.cede-title"), { it != town }) { picked -> run("towny:town cede plot ${picked.name}") @@ -135,7 +153,8 @@ class TownClaimsMenu(player: Player, back: Menu) : Menu(player, player.tr("claim PermissionNodes.TOWNY_COMMAND_TOWN_TAKEOVERCLAIM, Icons.icon( Material.IRON_SWORD, tr("claims.takeover"), tr("claims.takeover-description"), - *listOfNotNull(costLine(TownySettings.getTakeoverClaimPrice())).toTypedArray() + *listOfNotNull(costLine(TownySettings.getTakeoverClaimPrice())).toTypedArray(), + actions = hints("click.take-over") ) ) { run("towny:town takeoverclaim", claims, delayTicks = CLAIM_DELAY) @@ -154,7 +173,10 @@ class TownClaimsMenu(player: Player, back: Menu) : Menu(player, player.tr("claim ) { run("towny:resident toggle townclaim", { resident?.hasMode("townclaim") }) } - grid.add(Icons.icon(Material.FILLED_MAP, tr("main.map"), tr("common.map-description"))) { + grid.add(Icons.icon( + Material.FILLED_MAP, tr("main.map"), tr("common.map-description"), + actions = hints("click.open") + )) { MapMenu(player, this).open() } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownInfoMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownInfoMenu.kt index 53aa13c..f6ef78e 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownInfoMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownInfoMenu.kt @@ -26,14 +26,18 @@ class TownInfoMenu(player: Player, private val town: Town, back: Menu) : val grid = layout(19, 20, 21, 22, 23, 24, 25) if (viewer?.townOrNull == town) { - grid.add(Icons.icon(Material.WRITABLE_BOOK, tr("town-info.manage"), tr("town-info.manage-description"))) { + grid.add(Icons.icon( + Material.WRITABLE_BOOK, tr("town-info.manage"), tr("town-info.manage-description"), + actions = hints("click.open") + )) { TownMenu(player, this).open() } } grid.add( Icons.icon( Material.ENDER_PEARL, tr("town-info.visit"), tr("town-info.visit-description"), - *listOfNotNull(costLine(Prices.townSpawn(player, town))).toTypedArray() + *listOfNotNull(costLine(Prices.townSpawn(player, town))).toTypedArray(), + actions = hints("click.teleport") ) ) { runAndClose("towny:town spawn ${town.name}") @@ -43,7 +47,8 @@ class TownInfoMenu(player: Player, private val town: Town, back: Menu) : Material.PLAYER_HEAD, tr("town.residents"), null, - tr("icon.town.residents", "count" to town.numResidents) + tr("icon.town.residents", "count" to town.numResidents), + actions = hints("click.view") ) ) { TownMembersMenu(player, town, this).open() @@ -53,7 +58,8 @@ class TownInfoMenu(player: Player, private val town: Town, back: Menu) : Icons.icon( Material.BEACON, tr("town-info.nation", "nation" to TownyUtil.name(nation.name)), - tr("town-info.nation-description") + tr("town-info.nation-description"), + actions = hints("click.view") ) ) { NationInfoMenu(player, nation, this).open() @@ -62,7 +68,10 @@ class TownInfoMenu(player: Player, private val town: Town, back: Menu) : if (viewer != null && !viewer.hasTown() && town.isOpen) { grid.add( PermissionNodes.TOWNY_COMMAND_TOWN_JOIN, - Icons.icon(Material.OAK_DOOR, tr("town-info.join"), tr("town-info.join-description")) + Icons.icon( + Material.OAK_DOOR, tr("town-info.join"), tr("town-info.join-description"), + actions = hints("click.join") + ) ) { run("towny:town join ${town.name}", { viewer.hasTown() }, returnTo = MainMenu(player)) } @@ -70,7 +79,10 @@ class TownInfoMenu(player: Player, private val town: Town, back: Menu) : if (TownyUtil.economy && viewer?.townOrNull != town) { grid.add( PermissionNodes.TOWNY_COMMAND_TOWN_DEPOSIT_OTHERTOWN, - Icons.icon(Material.EMERALD, tr("town-info.donate"), tr("town-info.donate-description")) + Icons.icon( + Material.EMERALD, tr("town-info.donate"), tr("town-info.donate-description"), + actions = hints("click.donate") + ) ) { prompt( tr("town-info.donate-title", "town" to TownyUtil.name(town.name)), @@ -86,7 +98,8 @@ class TownInfoMenu(player: Player, private val town: Town, back: Menu) : grid.add( PermissionNodes.TOWNY_COMMAND_TOWN_BUYTOWN, Icons.icon( Material.GOLD_BLOCK, tr("town-info.buy"), tr("town-info.buy-description"), - *listOfNotNull(priceLine(town.forSalePrice)).toTypedArray() + *listOfNotNull(priceLine(town.forSalePrice)).toTypedArray(), + actions = hints("click.buy") ) ) { run("towny:town buytown ${town.name}", { town.mayor }, returnTo = MainMenu(player)) } } @@ -101,7 +114,8 @@ class TownInfoMenu(player: Player, private val town: Town, back: Menu) : "town" to TownyUtil.name(town.name), "own" to TownyUtil.name(viewerTown.name) ), - *listOfNotNull(costLine(Prices.merge(viewerTown, town))).toTypedArray() + *listOfNotNull(costLine(Prices.merge(viewerTown, town))).toTypedArray(), + actions = hints("click.merge") ) ) { run("towny:town merge ${town.name}") @@ -114,7 +128,8 @@ class TownInfoMenu(player: Player, private val town: Town, back: Menu) : Icons.icon( Material.PAPER, tr("town-info.invite"), - tr("town-info.invite-description", "nation" to TownyUtil.name(nation.name)) + tr("town-info.invite-description", "nation" to TownyUtil.name(nation.name)), + actions = hints("click.invite") ) ) { run("towny:nation add ${town.name}", { nation.sentInvites.size }) diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownJailMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownJailMenu.kt index f210d84..0d90496 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownJailMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownJailMenu.kt @@ -49,7 +49,10 @@ class TownJailMenu(player: Player, private val town: Town, back: Menu) : if (town.hasJails()) { guarded( 47, PermissionNodes.TOWNY_COMMAND_TOWN_JAIL, - Icons.icon(Material.IRON_BARS, tr("town-jail.jail-player"), tr("town-jail.jail-player-description")) + Icons.icon( + Material.IRON_BARS, tr("town-jail.jail-player"), tr("town-jail.jail-player-description"), + actions = hints("click.choose-player") + ) ) { Pickers.resident(this, tr("town-jail.jail-player-title"), ::canJail) { picked -> JailSentenceMenu(player, town, picked, this).open() @@ -61,7 +64,8 @@ class TownJailMenu(player: Player, private val town: Town, back: Menu) : button( 51, Icons.icon( Material.IRON_CHAIN, tr("town-jail.jails"), tr("town-jail.jails-description"), - tr("town-jail.jails-count", "count" to jails(town).size) + tr("town-jail.jails-count", "count" to jails(town).size), + actions = hints("click.view") ) ) { jailList().open() } } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownListMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownListMenu.kt index 9cf9308..e7ff244 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownListMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownListMenu.kt @@ -38,7 +38,7 @@ class TownListMenu(player: Player, back: Menu) : PagedMenu(player, player.tr("to ?.let { tr("town-list.distance", "blocks" to it.toLong()) }, ) MenuEntry({ - Icons.town(player, town, *lines.toTypedArray(), actions = listOf(tr("common.click-details"))) + Icons.town(player, town, *lines.toTypedArray(), actions = listOf(tr("click.details"))) }) { TownInfoMenu(player, town, this).open() } @@ -52,10 +52,10 @@ class TownListMenu(player: Player, back: Menu) : PagedMenu(player, player.tr("to } button(47, itemStack(Material.HOPPER) { name(tr("sort.current", "sort" to tr(sort.label))) - lore(sorts.map { (if (it == sort) "▶ " else " ") + tr(it.label) }) - loreActions(listOf(tr("common.click-change"))) - }) { - sort = sorts[(sorts.indexOf(sort) + 1) % sorts.size] + lore(sorts.map { tr(if (it == sort) "sort.selected" else "sort.option", "sort" to tr(it.label)) }) + loreActions(hints("click.next", "click.previous")) + }) { click -> + sort = sorts.cycle(sort, click) render() } } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownMembersMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownMembersMenu.kt index 9d47593..c491fe4 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownMembersMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownMembersMenu.kt @@ -29,7 +29,7 @@ class TownMembersMenu(player: Player, private val town: Town, back: Menu) : .thenBy { it.name.lowercase() }) .map { member -> MenuEntry({ - Icons.resident(player, member, actions = listOf(tr("common.click-view"))) + Icons.resident(player, member, actions = listOf(tr("click.view"))) }) { ResidentProfileMenu(player, member, this).open() } } @@ -42,7 +42,8 @@ class TownMembersMenu(player: Player, private val town: Town, back: Menu) : Icons.icon( Material.PLAYER_HEAD, tr("town-members.invite-online"), - tr("town-members.invite-online-description") + tr("town-members.invite-online-description"), + actions = hints("click.choose-player") ) ) { Pickers.resident(this, tr("town-members.invite-title"), { !it.hasTown() }) { picked -> @@ -51,7 +52,10 @@ class TownMembersMenu(player: Player, private val town: Town, back: Menu) : } guarded( 48, PermissionNodes.TOWNY_COMMAND_TOWN_INVITE_ADD, - Icons.icon(Material.NAME_TAG, tr("town-members.invite-name"), tr("town-members.invite-name-description")) + Icons.icon( + Material.NAME_TAG, tr("town-members.invite-name"), tr("town-members.invite-name-description"), + actions = hints("click.type-name") + ) ) { prompt( tr("town-members.invite-title"), @@ -60,7 +64,10 @@ class TownMembersMenu(player: Player, private val town: Town, back: Menu) : } guarded( 50, PermissionNodes.TOWNY_COMMAND_TOWN_SAY, - Icons.icon(Material.BELL, tr("town-members.announce"), tr("town-members.announce-description")) + Icons.icon( + Material.BELL, tr("town-members.announce"), tr("town-members.announce-description"), + actions = hints("click.write") + ) ) { prompt(tr("town-members.announce-title"), tr("common.message"), maxLength = 200) { text -> run("towny:town say $text") @@ -71,7 +78,9 @@ class TownMembersMenu(player: Player, private val town: Town, back: Menu) : 51, PermissionNodes.TOWNY_COMMAND_TOWN_INVITE_ADD, Icons.icon( Material.PAPER, tr("common.sent-invites"), tr("common.sent-invites-description"), tr("common.pending", "count" to pending.size), "", - *pending.take(10).map { "- ${TownyUtil.name(it.receiver.name)}" }.toTypedArray() + *pending.take(10) + .map { tr("common.list-entry", "entry" to TownyUtil.name(it.receiver.name)) }.toTypedArray(), + actions = hints("click.revoke-all") ) ) { click -> if (click.isRightClick) run("towny:town invite sent removeall", sent) } } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownMenu.kt index 57ca396..a877c11 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownMenu.kt @@ -77,7 +77,8 @@ class TownMenu(player: Player, back: Menu?) : Menu(player, player.tr("town.title Material.PLAYER_HEAD, tr("town.residents"), tr("town.residents-description"), - tr("icon.town.residents", "count" to town.numResidents) + tr("icon.town.residents", "count" to town.numResidents), + actions = hints("click.view") ) ) { TownMembersMenu(player, town, this).open() @@ -88,7 +89,8 @@ class TownMenu(player: Player, back: Menu?) : Menu(player, player.tr("town.title Material.GOLD_INGOT, tr("town.bank"), tr("town.bank-description"), - tr("bank.balance", "balance" to TownyUtil.balance(town)) + tr("bank.balance", "balance" to TownyUtil.balance(town)), + actions = hints("click.open") ) ) { BankMenu(player, town, this).open() @@ -97,27 +99,43 @@ class TownMenu(player: Player, back: Menu?) : Menu(player, player.tr("town.title grid.add( Icons.icon( Material.GRASS_BLOCK, tr("claims.info"), tr("town.claims-description"), - tr("icon.town.claims", "claims" to town.numTownBlocks, "max" to town.maxTownBlocksAsAString) + tr("icon.town.claims", "claims" to town.numTownBlocks, "max" to town.maxTownBlocksAsAString), + actions = hints("click.open") ) ) { TownClaimsMenu(player, this).open() } - grid.add(Icons.icon(Material.FILLED_MAP, tr("main.map"), tr("common.map-description"))) { + grid.add(Icons.icon( + Material.FILLED_MAP, tr("main.map"), tr("common.map-description"), + actions = hints("click.open") + )) { MapMenu(player, this).open() } - grid.add(Icons.icon(Material.LEVER, tr("town.settings"), tr("town.settings-description"))) { + grid.add(Icons.icon( + Material.LEVER, tr("town.settings"), tr("town.settings-description"), + actions = hints("click.open") + )) { toggles().open() } - grid.add(Icons.icon(Material.WRITABLE_BOOK, tr("town.details"), tr("town.details-description"))) { + grid.add(Icons.icon( + Material.WRITABLE_BOOK, tr("town.details"), tr("town.details-description"), + actions = hints("click.open") + )) { TownSettingsMenu(player, this).open() } grid.add( PermissionNodes.TOWNY_COMMAND_TOWN_SET_PERM, - Icons.icon(Material.IRON_DOOR, tr("common.permissions"), tr("town.permissions-description")) + Icons.icon( + Material.IRON_DOOR, tr("common.permissions"), tr("town.permissions-description"), + actions = hints("click.edit-permissions") + ) ) { permissions().open() } - grid.add(Icons.icon(Material.TRIPWIRE_HOOK, tr("common.trusted"), tr("town.trusted-description"))) { + grid.add(Icons.icon( + Material.TRIPWIRE_HOOK, tr("common.trusted"), tr("town.trusted-description"), + actions = hints("click.view") + )) { TownTrustMenu(player, town, this).open() } grid.add( @@ -125,7 +143,8 @@ class TownMenu(player: Player, back: Menu?) : Menu(player, player.tr("town.title Material.IRON_BARS, tr("town.outlaws"), tr("town.outlaws-description"), - tr("town.outlaws-count", "count" to town.outlaws.size) + tr("town.outlaws-count", "count" to town.outlaws.size), + actions = hints("click.view") ) ) { OutlawsMenu(player, town, this).open() @@ -135,7 +154,8 @@ class TownMenu(player: Player, back: Menu?) : Menu(player, player.tr("town.title PermissionNodes.TOWNY_COMMAND_TOWN_RECLAIM, Icons.icon( Material.MOSSY_STONE_BRICKS, tr("town.reclaim"), tr("town.reclaim-description"), - *reclaimLines().toTypedArray() + *reclaimLines().toTypedArray(), + actions = hints("click.reclaim") ) ) { run("towny:town reclaim", { town.isRuined }) @@ -146,7 +166,8 @@ class TownMenu(player: Player, back: Menu?) : Menu(player, player.tr("town.title Material.IRON_CHAIN, tr("town.jail"), tr("town.jail-description"), - tr("town.jail-count", "count" to town.jailedPlayerCount) + tr("town.jail-count", "count" to town.jailedPlayerCount), + actions = hints("click.open") ) ) { TownJailMenu(player, town, this).open() @@ -155,7 +176,8 @@ class TownMenu(player: Player, back: Menu?) : Menu(player, player.tr("town.title grid.add( Icons.icon( Material.ENDER_PEARL, tr("town.spawn"), tr("town.spawn-description"), - *listOfNotNull(costLine(Prices.townSpawn(player, town))).toTypedArray() + *listOfNotNull(costLine(Prices.townSpawn(player, town))).toTypedArray(), + actions = hints("click.teleport") ) ) { runAndClose("towny:town spawn") @@ -166,7 +188,8 @@ class TownMenu(player: Player, back: Menu?) : Menu(player, player.tr("town.title Material.COMPASS, tr("town.outpost-teleport"), tr("town.outpost-teleport-description"), - *listOfNotNull(costLine(Prices.townSpawn(player, town, outpost = true))).toTypedArray() + *listOfNotNull(costLine(Prices.townSpawn(player, town, outpost = true))).toTypedArray(), + actions = hints("click.choose") ) ) { OutpostsMenu(player, town, this).open() @@ -179,7 +202,8 @@ class TownMenu(player: Player, back: Menu?) : Menu(player, player.tr("town.title if (nation != null) tr( "town.nation-open", "nation" to TownyUtil.name(nation.name) - ) else tr("town.nation-none") + ) else tr("town.nation-none"), + actions = hints("click.open") ) ) { if (town.hasNation()) NationMenu(player, this).open() else NoNationMenu(player, this).open() @@ -188,14 +212,20 @@ class TownMenu(player: Player, back: Menu?) : Menu(player, player.tr("town.title if (viewer.isMayor) { grid.add( PermissionNodes.TOWNY_COMMAND_TOWN_DELETE, - Icons.icon(Material.TNT, tr("town.delete"), tr("town.delete-description")) + Icons.icon( + Material.TNT, tr("town.delete"), tr("town.delete-description"), + actions = hints("click.delete") + ) ) { run("towny:town delete", { viewer.hasTown() }, returnTo = MainMenu(player)) } } else { grid.add( PermissionNodes.TOWNY_COMMAND_TOWN_LEAVE, - Icons.icon(Material.OAK_DOOR, tr("town.leave"), tr("town.leave-description")) + Icons.icon( + Material.OAK_DOOR, tr("town.leave"), tr("town.leave-description"), + actions = hints("click.leave") + ) ) { run("towny:town leave", { viewer.hasTown() }, returnTo = MainMenu(player)) } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownSettingsMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownSettingsMenu.kt index c68659e..e2923d0 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownSettingsMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownSettingsMenu.kt @@ -29,7 +29,8 @@ class TownSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("tow tr("town-details.rename"), null, tr("common.current", "value" to TownyUtil.name(town.name)), - *listOfNotNull(costLine(TownySettings.getTownRenameCost())).toTypedArray() + *listOfNotNull(costLine(TownySettings.getTownRenameCost())).toTypedArray(), + actions = hints("click.rename") ) ) { prompt(tr("town-details.rename-title"), tr("common.new-name"), initial = town.name) { name -> @@ -38,7 +39,10 @@ class TownSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("tow } grid.add( PermissionNodes.TOWNY_COMMAND_TOWN_SET_BOARD, - Icons.icon(Material.OAK_SIGN, tr("town-details.board"), tr("town-details.board-description")) + Icons.icon( + Material.OAK_SIGN, tr("town-details.board"), tr("town-details.board-description"), + actions = hints("click.edit", "click.clear") + ) ) { click -> if (click.isRightClick) { run("towny:town set board none", { town.board }) @@ -60,7 +64,8 @@ class TownSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("tow Material.PAPER, tr("town-details.tag"), tr("common.tag-description"), - tr("common.current", "value" to TownyUtil.text(town.tag)) + tr("common.current", "value" to TownyUtil.text(town.tag)), + actions = hints("click.set") ) ) { prompt(tr("town-details.tag-title"), tr("common.tag"), initial = town.tag, maxLength = 16) { tag -> @@ -71,7 +76,8 @@ class TownSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("tow PermissionNodes.TOWNY_COMMAND_TOWN_SET_MAPCOLOR, Icons.icon( Material.LIME_DYE, tr("common.map-color"), tr("town-details.map-color-description"), - *listOfNotNull(costLine(TownySettings.getTownSetMapColourCost())).toTypedArray() + *listOfNotNull(costLine(TownySettings.getTownSetMapColourCost())).toTypedArray(), + actions = hints("click.choose") ) ) { val colors = TownySettings.getTownColorsMap().keys.sorted().map { it to "${TownyUtil.name(it)}" } @@ -81,25 +87,37 @@ class TownSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("tow } grid.add( PermissionNodes.TOWNY_COMMAND_TOWN_SET_SPAWN, - Icons.icon(Material.RESPAWN_ANCHOR, tr("common.set-spawn"), tr("town-details.set-spawn-description")) + Icons.icon( + Material.RESPAWN_ANCHOR, tr("common.set-spawn"), tr("town-details.set-spawn-description"), + actions = hints("click.set-here") + ) ) { run("towny:town set spawn", { town.spawnOrNull }) } grid.add( PermissionNodes.TOWNY_COMMAND_TOWN_SET_HOMEBLOCK, - Icons.icon(Material.LODESTONE, tr("town-details.home-block"), tr("town-details.home-block-description")) + Icons.icon( + Material.LODESTONE, tr("town-details.home-block"), tr("town-details.home-block-description"), + actions = hints("click.set-here") + ) ) { run("towny:town set homeblock", { town.homeBlockOrNull }) } grid.add( PermissionNodes.TOWNY_COMMAND_TOWN_SET_OUTPOST, - Icons.icon(Material.COMPASS, tr("town-details.outpost"), tr("town-details.outpost-description")) + Icons.icon( + Material.COMPASS, tr("town-details.outpost"), tr("town-details.outpost-description"), + actions = hints("click.set-here") + ) ) { run("towny:town set outpost", { town.allOutpostSpawns.toList() }) } grid.add( PermissionNodes.TOWNY_COMMAND_TOWN_SET_PRIMARYJAIL, - Icons.icon(Material.IRON_BARS, tr("town-details.jail"), tr("town-details.jail-description")) + Icons.icon( + Material.IRON_BARS, tr("town-details.jail"), tr("town-details.jail-description"), + actions = hints("click.set-here") + ) ) { run("towny:town set primaryjail") } @@ -187,7 +205,8 @@ class TownSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("tow Material.RED_BANNER, tr("town-details.not-for-sale"), null, - *listOfNotNull(priceLine(town.forSalePrice)).toTypedArray() + *listOfNotNull(priceLine(town.forSalePrice)).toTypedArray(), + actions = hints("click.stop-selling") ) ) { run("towny:town notforsale", { town.isForSale }) @@ -198,7 +217,8 @@ class TownSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("tow Icons.icon( Material.GREEN_BANNER, tr("town-details.for-sale"), - tr("town-details.for-sale-description") + tr("town-details.for-sale-description"), + actions = hints("click.set-price") ) ) { prompt(tr("town-details.for-sale-title"), tr("common.price-label")) { price -> @@ -228,7 +248,7 @@ class TownSettingsMenu(player: Player, back: Menu) : Menu(player, player.tr("tow "$label", null, tr("common.current", "value" to current), - actions = listOf(tr("common.click-change")) + actions = listOf(tr("click.change")) ) ) { prompt(label, tr("common.amount"), initial = read().toString()) { amount -> diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownStatusMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownStatusMenu.kt index 3de4975..f3c5168 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownStatusMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownStatusMenu.kt @@ -30,7 +30,10 @@ class TownStatusMenu(player: Player, private val town: Town, back: Menu) : info.add( Icons.icon( Material.COMPASS, tr("town-status.outposts"), tr("town-status.outposts-description"), - tr("claims.outposts", "outposts" to town.maxOutpostSpawn, "limit" to town.outpostLimit) + tr("claims.outposts", "outposts" to town.maxOutpostSpawn, "limit" to town.outpostLimit), + *listOfNotNull( + town.outpostLimit.takeIf { it > 0 }?.let { progressBar(town.maxOutpostSpawn, it) } + ).toTypedArray() ) ) } @@ -40,7 +43,7 @@ class TownStatusMenu(player: Player, private val town: Town, back: Menu) : Icons.icon( Material.BEACON, tr("town-status.nation-zone"), tr("town-status.nation-zone-description"), tr("town-status.nation-zone-size", "size" to town.nationZoneSize), - tr("icon.currently", "value" to TownyUtil.onOff(player, town.isNationZoneEnabled)) + tr("icon.status", "value" to tr(if (town.isNationZoneEnabled) "icon.enabled" else "icon.disabled")) ) ) } @@ -78,6 +81,10 @@ class TownStatusMenu(player: Player, private val town: Town, back: Menu) : else -> tr("town-status.next-level-residents", "current" to progress, "needed" to next) } ) + if (town.manualTownLevel == -1 && next != null) { + val floor = thresholds.getOrElse(number) { 0 } + add(progressBar(progress - floor, next - floor)) + } }.toTypedArray() ) } @@ -85,6 +92,7 @@ class TownStatusMenu(player: Player, private val town: Town, back: Menu) : private fun claims(): ItemStack = Icons.icon( Material.GRASS_BLOCK, tr("claims.info"), tr("town-status.claims-description"), *buildList { add(tr("claims.claimed", "claims" to town.numTownBlocks, "max" to town.maxTownBlocksAsAString)) + if (!town.hasUnlimitedClaims()) add(progressBar(town.numTownBlocks, town.maxTownBlocks)) add( tr( "claims.available", @@ -157,6 +165,7 @@ class TownStatusMenu(player: Player, private val town: Town, back: Menu) : warn( Material.TNT, menu.tr("town-status.overclaimed"), menu.tr("claims.claimed", "claims" to town.numTownBlocks, "max" to town.maxTownBlocksAsAString), + menu.progressBar(town.numTownBlocks, town.maxTownBlocks), menu.tr( if (TownySettings.isOverClaimingAllowingStolenLand()) "town-status.overclaimed-stealable" else "town-status.overclaimed-description" diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownTrustMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownTrustMenu.kt index 3b02ddb..d8b0384 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownTrustMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownTrustMenu.kt @@ -26,7 +26,7 @@ class TownTrustMenu(player: Player, private val town: Town, back: Menu) : MenuEntry({ Icons.resident( player, trusted, - actions = listOf(tr(if (canTrust) "common.click-untrust" else "town-trust.resident")) + actions = listOf(tr(if (canTrust) "click.untrust" else "town-trust.resident")) ) }) { if (canTrust) run("towny:town trust remove ${trusted.name}", ::snapshot) @@ -36,7 +36,7 @@ class TownTrustMenu(player: Player, private val town: Town, back: Menu) : MenuEntry({ Icons.town( player, trusted, - actions = listOf(tr(if (canTrustTowns) "common.click-untrust" else "town-trust.town")) + actions = listOf(tr(if (canTrustTowns) "click.untrust" else "town-trust.town")) ) }) { if (canTrustTowns) run("towny:town trusttown remove ${trusted.name}", ::snapshot) @@ -49,7 +49,10 @@ class TownTrustMenu(player: Player, private val town: Town, back: Menu) : tutorialButton(52, Tutorial.PROTECTION) guarded( 47, PermissionNodes.TOWNY_COMMAND_TOWN_TRUST, - Icons.icon(Material.PLAYER_HEAD, tr("common.trust-online"), tr("town-trust.trust-online-description")) + Icons.icon( + Material.PLAYER_HEAD, tr("common.trust-online"), tr("town-trust.trust-online-description"), + actions = hints("click.choose-player") + ) ) { Pickers.resident(this, tr("common.trust-title"), { !town.hasTrustedResident(it) }) { picked -> run("towny:town trust add ${picked.name}", ::snapshot) @@ -57,7 +60,10 @@ class TownTrustMenu(player: Player, private val town: Town, back: Menu) : } guarded( 48, PermissionNodes.TOWNY_COMMAND_TOWN_TRUST, - Icons.icon(Material.NAME_TAG, tr("common.trust-name"), tr("common.trust-name-description")) + Icons.icon( + Material.NAME_TAG, tr("common.trust-name"), tr("common.trust-name-description"), + actions = hints("click.type-name") + ) ) { prompt( tr("common.trust-title"), @@ -66,7 +72,10 @@ class TownTrustMenu(player: Player, private val town: Town, back: Menu) : } guarded( 51, PermissionNodes.TOWNY_COMMAND_TOWN_TRUSTTOWN, - Icons.icon(Material.BELL, tr("town-trust.trust-town"), tr("town-trust.trust-town-description")) + Icons.icon( + Material.BELL, tr("town-trust.trust-town"), tr("town-trust.trust-town-description"), + actions = hints("click.choose-town") + ) ) { Pickers.town( this, diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/tutorial/TutorialChapterMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/tutorial/TutorialChapterMenu.kt index 6c7a2b3..2d6632c 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/tutorial/TutorialChapterMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/tutorial/TutorialChapterMenu.kt @@ -24,6 +24,7 @@ class TutorialChapterMenu(player: Player, private val chapter: Chapter, back: Me loreWrapped("${tr(chapter.description)}") loreBreak() lore(tr("tutorial.progress", "read" to read, "total" to lessons.size)) + lore(progressBar(read, lessons.size)) chapter.link?.let { loreActions(listOf(linkLine(it))) } glow(read == lessons.size) }) { if (chapter.link?.open(player, this) != true) render() } @@ -52,7 +53,8 @@ class TutorialChapterMenu(player: Player, private val chapter: Chapter, back: Me Material.ARROW, tr("tutorial.previous-chapter"), null, - tr("tutorial.chapter-line", "chapter" to tr(previous.title)) + tr("tutorial.chapter-line", "chapter" to tr(previous.title)), + actions = hints("click.open") ) ) { TutorialChapterMenu(player, previous, back).open() @@ -65,7 +67,8 @@ class TutorialChapterMenu(player: Player, private val chapter: Chapter, back: Me Material.ARROW, tr("tutorial.next-chapter"), null, - tr("tutorial.chapter-line", "chapter" to tr(next.title)) + tr("tutorial.chapter-line", "chapter" to tr(next.title)), + actions = hints("click.open") ) ) { TutorialChapterMenu(player, next, back).open() @@ -76,7 +79,8 @@ class TutorialChapterMenu(player: Player, private val chapter: Chapter, back: Me button( 51, Icons.icon( if (allRead) Material.BOOK else Material.WRITABLE_BOOK, - tr(if (allRead) "tutorial.mark-all-unread" else "tutorial.mark-all-read") + tr(if (allRead) "tutorial.mark-all-unread" else "tutorial.mark-all-read"), + actions = hints(if (allRead) "tutorial.click-unread" else "tutorial.click-read") ) ) { Tutorial.setRead(player, lessons, !allRead) diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/tutorial/TutorialMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/tutorial/TutorialMenu.kt index 55dc82c..9fb272f 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/tutorial/TutorialMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/tutorial/TutorialMenu.kt @@ -21,6 +21,7 @@ class TutorialMenu(player: Player, back: Menu?) : Menu(player, player.tr("tutori 4, Icons.icon( Material.KNOWLEDGE_BOOK, tr("tutorial.hub"), tr("tutorial.hub-description"), tr("tutorial.progress", "read" to read, "total" to total), + progressBar(read, total), *listOfNotNull(if (read == total) tr("tutorial.all-read") else null).toTypedArray() ) ) @@ -35,7 +36,8 @@ class TutorialMenu(player: Player, back: Menu?) : Menu(player, player.tr("tutori button( 47, Icons.icon( Material.SPECTRAL_ARROW, tr("tutorial.continue"), tr("tutorial.continue-description"), - tr("tutorial.chapter-line", "chapter" to tr(next.title)) + tr("tutorial.chapter-line", "chapter" to tr(next.title)), + actions = hints("click.open") ) ) { TutorialChapterMenu(player, next, this).open() @@ -43,7 +45,10 @@ class TutorialMenu(player: Player, back: Menu?) : Menu(player, player.tr("tutori } backButton(49) if (read > 0) { - button(51, Icons.icon(Material.WATER_BUCKET, tr("tutorial.reset"), tr("tutorial.reset-description"))) { + button(51, Icons.icon( + Material.WATER_BUCKET, tr("tutorial.reset"), tr("tutorial.reset-description"), + actions = hints("click.reset") + )) { DialogUtil.confirm( player, MiniMessage.miniMessage().deserialize(tr("tutorial.reset-confirm")), null, onYes = { @@ -63,8 +68,9 @@ class TutorialMenu(player: Player, back: Menu?) : Menu(player, player.tr("tutori loreWrapped("${tr(chapter.description)}") loreBreak() lore(tr("tutorial.progress", "read" to read, "total" to total)) + lore(progressBar(read, total)) if (read == total) lore(tr("tutorial.chapter-complete")) - loreActions(listOf(tr("tutorial.click-chapter"))) + loreActions(hints("click.open")) glow(read == total) } } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/utils/ItemStackDSL.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/utils/ItemStackDSL.kt index 428968a..094a716 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/utils/ItemStackDSL.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/utils/ItemStackDSL.kt @@ -20,8 +20,8 @@ import org.bukkit.inventory.meta.SkullMeta * name("Deposit") * loreWrapped("Move money from your balance into the town bank.") * loreBreak() - * lore("Balance: $120") - * loreActions(listOf("Click to deposit")) + * lore("Balance: $120") + * loreActions(listOf("Click to deposit!")) * } * ``` * diff --git a/src/main/resources/lang/en_US.yml b/src/main/resources/lang/en_US.yml index c7453f4..51aecbd 100644 --- a/src/main/resources/lang/en_US.yml +++ b/src/main/resources/lang/en_US.yml @@ -3,6 +3,14 @@ # Values are MiniMessage (https://docs.advntr.dev/minimessage/format.html). Keep every {placeholder}: TownyMenu fills # them in. Keys missing here fall back to the bundled copy of this file, then to English. # Run /townymenu reload after editing. +# +# Colours follow one palette, so the same kind of text looks the same in every menu: +# labels and descriptions neutral values, player names +# money, towns, leadership nations +# counts, land, plots, allies dates and times, menu and button names +# spawns and outposts danger, PvP, enemies, outlaws, jail +# Click hints end with "!": for a click or left-click, for a right-click, +# when the click destroys or removes something. command: usage: "Usage: /{command} " @@ -40,10 +48,10 @@ common: # Shared by several menus (continues the common section above). current: "Current: {value}" - cost: "Cost: {cost}" - price: "Price: {price}" - pending: "Pending: {count}" - founded: "Founded: {date}" + cost: "Cost: {cost}" + price: "Price: {price}" + pending: "Pending: {count}" + founded: "Founded: {date}" amount: "Amount" price-label: "Price" player-name: "Player name" @@ -52,17 +60,11 @@ common: tag: "Tag" tag-description: "A short tag shown in chat." map-color: "Map Color" - map-description: "See the land around you." + map-description: "See the land around you." set-spawn: "Set Spawn Here" permissions: "Permissions" - click-change: "Click to change" - click-details: "Click for details" - click-view: "Click to view" - click-teleport: "Click to teleport" - click-untrust: "Click to untrust" - left-details: "Left-click for details" sent-invites: "Sent Invites" - sent-invites-description: "Right-click to revoke every pending invite." + sent-invites-description: "Invitations your town has sent that nobody has answered yet." trusted: "Trusted" trusted-title: "Trusted" trust-title: "Trust Player" @@ -70,15 +72,92 @@ common: trust-name: "Trust by Name" trust-name-description: "Trust any player Towny knows." duration: "{hours}h {minutes}m" + list-entry: "• {entry}" + progress-bar: "{filled}{empty} {percent}%" menu: close: "Close" - back: "Back" + back: "Go Back" + back-to: "To {menu}" no-permission: "You don't have permission for this." empty: "Nothing here yet" - previous-page: "Previous Page" - next-page: "Next Page" - page: "Page {page}/{pages}" + previous-page: "Previous Page" + next-page: "Next Page" + page: "Page {page}/{pages}" + +click: + open: "Click to open!" + view: "Click to view!" + browse: "Click to browse!" + details: "Click for details!" + left-details: "Left-click for details!" + change: "Click to change!" + next: "Left-click for the next one!" + previous: "Right-click for the previous one!" + turn-page: "Click to turn the page!" + teleport: "Click to teleport!" + choose: "Click to choose!" + choose-player: "Click to choose a player!" + choose-town: "Click to choose a town!" + choose-nation: "Click to choose a nation!" + choose-radius: "Click to choose a radius!" + choose-days: "Click to enter the days!" + type-name: "Click to type a name!" + type-amount: "Click to type an amount!" + type-node: "Click to type a permission node!" + write: "Click to write a message!" + set: "Click to set!" + set-here: "Click to set it here!" + set-price: "Click to set a price!" + stop-selling: "Click to stop selling!" + edit: "Left-click to edit!" + left-rename: "Left-click to rename!" + clear: "Right-click to clear!" + rename: "Click to rename!" + edit-permissions: "Click to edit permissions!" + edit-ranks: "Click to edit ranks!" + claim: "Click to claim!" + unclaim: "Click to unclaim!" + take-over: "Click to take over!" + buy: "Click to buy!" + pay: "Click to pay!" + donate: "Click to donate!" + give-up: "Click to give up!" + evict: "Click to evict!" + clear-plot: "Click to clear!" + invite: "Click to invite!" + join: "Click to join!" + leave: "Click to leave!" + delete: "Click to delete!" + found: "Click to found!" + reclaim: "Click to reclaim!" + merge: "Click to merge!" + kick: "Click to kick!" + make-mayor: "Click to make mayor!" + make-leader: "Click to make leader!" + make-outpost: "Click to make an outpost!" + add: "Click to add!" + remove: "Click to remove!" + trust: "Click to trust!" + untrust: "Click to untrust!" + outlaw: "Click to declare an outlaw!" + pardon: "Click to pardon!" + propose: "Click to propose an alliance!" + end-alliance: "Click to end the alliance!" + declare-enemy: "Click to declare an enemy!" + make-peace: "Click to make peace!" + revoke-all: "Right-click to revoke them all!" + jail: "Click to jail!" + release: "Click to release!" + free: "Click to free!" + restore: "Click to restore!" + reset: "Click to reset!" + run: "Click to run!" + reload: "Click to reload!" + refresh: "Click to refresh!" + search: "Click to search!" + show-hud: "Click to show the HUD!" + open-editor: "Click to open the editor!" dialog: confirm: "Confirm" @@ -87,60 +166,63 @@ dialog: cannot-undo: "This cannot be undone." icon: - currently: "Currently: {value}" - click-toggle: "Click to toggle" - bank: "Bank: {balance}" + bank: "Bank: {balance}" + status: "Status: {value}" + enabled: "ENABLED" + disabled: "DISABLED" + click-enable: "Click to enable!" + click-disable: "Click to disable!" open-public: "Open: {open} · Public: {public}" resident: - town: "Town: {town}" + town: "Town: {town}" mayor: "Mayor" ranks: "Ranks: {ranks}" online: "Online" - last-online: "Last online: {date}" + last-online: "Last online: {date}" town: mayor: "Mayor: {mayor}" - residents: "Residents: {count}" - claims: "Claims: {claims}/{max}" - nation: "Nation: {nation}" + residents: "Residents: {count}" + claims: "Claims: {claims}/{max}" + nation: "Nation: {nation}" for-sale: "For sale: {price}" ruined: "Ruined" nation: leader: "Leader: {leader}" - capital: "Capital: {capital}" - size: "Towns: {towns} · Residents: {residents}" - relations: "Allies: {allies} · Enemies: {enemies}" + capital: "Capital: {capital}" + size: "Towns: {towns} · Residents: {residents}" + relations: "Allies: {allies} · Enemies: {enemies}" flags: "Open: {open} · Public: {public} · Peaceful: {peaceful}" main: title: "Towny" unregistered: "Towny hasn't registered you yet" unregistered-hint: "Try again in a moment." - profile-click: "Click to open your profile" + profile-click: "Click to view your profile!" town: "Town" - town-click: "Click to manage your town" + town-click: "Click to manage your town!" town-none: "You are not in a town. Found one, join one, or answer invites." nation: "Nation" nation-locked: "Nation" - nation-click: "Click to manage your nation" + nation-click: "Click to manage your nation!" nation-none: "Your town is not in a nation. Found one or join one." nation-no-town: "Join a town before joining a nation." plot: "This Plot" - plot-description: "Buy, sell, and configure the plot you are standing in." - plot-here: "Here: {town}" + plot-description: "Buy, sell, and configure the plot you are standing in." + plot-here: "Here: {town}" wilderness: "Wilderness" map: "Map" - map-description: "See who owns the land around you." + map-description: "See who owns the land around you." towns: "Towns" towns-description: "Browse and rank every town." nations: "Nations" nations-description: "Browse and rank every nation." invites: "Invites" - invites-count: "Invites ({count})" - invites-description: "Town invites, nation invites, and alliance requests." + invites-count: "Invites ({count})" + invites-description: "Town invites, nation invites, and alliance requests." admin: "Server Admin" admin-description: "Configure Towny and manage every town, nation, and resident." tutorial: "Tutorial" - tutorial-description: "Learn how towns, plots, nations, and these menus work." + tutorial-description: "Learn how towns, plots, nations, and these menus work." prices: "Prices & New Day" prices-description: "What everything costs on this server, and when the next Towny day starts." leaderboards: "Leaderboards" @@ -167,9 +249,9 @@ map: legend-for-sale: "Glowing tiles are for sale." legend-north: "North is up." claim: "Claim Your Chunk" - claim-description: "Claim the chunk you are standing in." + claim-description: "Claim the chunk you are standing in." unclaim: "Unclaim Your Chunk" - unclaim-description: "Unclaim the chunk you are standing in." + unclaim-description: "Unclaim the chunk you are standing in." refresh: "Refresh" refresh-description: "Redraw the map around your current position." you-are-here: "You are here" @@ -179,9 +261,9 @@ map: type: "Type: {type}" home-block: "Home block" outpost: "Outpost" - for-sale: "For sale: {price}" - click-town: "Click to view town" - right-buy: "Right-click to buy this plot" + for-sale: "For sale: {price}" + click-town: "Click to view the town!" + right-buy: "Right-click to buy this plot!" invites: title: "Invites" @@ -190,36 +272,36 @@ invites: nation: "Invitation for your town to join {nation}" alliance: "Alliance request from {nation}" sender: "Sent by: {sender}" - left-accept: "Left-click to accept" - right-decline: "Right-click to decline" + left-accept: "Left-click to accept!" + right-decline: "Right-click to decline!" bank: title: "Bank: {name}" info: "{name} Bank" - balance: "Balance: {balance}" - daily-tax: "Daily tax: {tax}" + balance: "Balance: {balance}" + daily-tax: "Daily tax: {tax}" deposit: "Deposit" deposit-title: "Deposit" - deposit-description: "Move money from your balance into the bank." + deposit-description: "Move money from your balance into the bank." withdraw: "Withdraw" withdraw-title: "Withdraw" - withdraw-description: "Take money out of the bank." + withdraw-description: "Take money out of the bank." prompt-balance: "Bank balance: {balance}" history: "Bank History" history-description: "Open a book with recent transactions." - click-choose: "Click to choose an amount" + click-choose: "Click to choose an amount!" deposit-menu-title: "Deposit: {name}" withdraw-menu-title: "Withdraw: {name}" - your-balance: "Your balance: {balance}" - minimum: "Minimum: {amount}" - maximum: "Maximum: {amount}" + your-balance: "Your balance: {balance}" + minimum: "Minimum: {amount}" + maximum: "Maximum: {amount}" amount: "{amount}" - amount-line: "Amount: {amount}" + amount-line: "Amount: {amount}" all: "Everything" custom: "Custom Amount" custom-description: "Type any amount yourself." - click-deposit: "Click to deposit" - click-withdraw: "Click to withdraw" + click-deposit: "Click to deposit!" + click-withdraw: "Click to withdraw!" not-enough: "Not enough money" nothing-to-move: "Nothing to move" below-minimum: "Below the {amount} minimum" @@ -227,12 +309,14 @@ bank: perm: gone: "This land no longer exists" - everyone-on: "Click to turn on for everyone" - everyone-off: "Click to turn off for everyone" - every-action-on: "Click to turn on every action" - every-action-off: "Click to turn off every action" + everyone-on: "Click to turn on for everyone!" + everyone-off: "Click to turn off for everyone!" + every-action-on: "Click to turn on every action!" + every-action-off: "Click to turn off every action!" allowed: "Allowed" denied: "Denied" + click-allow: "Click to allow!" + click-deny: "Click to deny!" reset: "Reset" reset-description: "Restore the server's default permissions." residents: "Residents" @@ -250,10 +334,10 @@ perm: item-use: "Item Use" item-use-description: "Use items such as flint and steel or buckets." overrides: "Player Overrides" - overrides-description: "Give single players their own build, break, and interact permissions on this land." + overrides-description: "Give single players their own build, break, and interact permissions on this land." picker: - select: "Click to select" + select: "Click to select!" current: "Current" rank: @@ -261,71 +345,71 @@ rank: nation-title: "Nation Ranks: {name}" assigned: "Assigned" not-assigned: "Not assigned" - click-assign: "Click to assign" - click-remove: "Click to remove" + click-assign: "Click to assign!" + click-remove: "Click to remove!" not-allowed: "You can't assign this rank." town: title: "Your Town" not-in-town: "You are not in a town" - plot-tax: "Plot tax: {tax}" - outposts: "Outposts: {count}" + plot-tax: "Plot tax: {tax}" + outposts: "Outposts: {count}" pvp-mobs: "PvP: {pvp} · Mobs: {mobs}" fire-explosions: "Fire: {fire} · Explosions: {explosions}" residents: "Residents" - residents-description: "View residents, manage ranks, and invite players." + residents-description: "View residents, manage ranks, and invite players." bank: "Town Bank" - bank-description: "Deposit, withdraw, and view bank history." - claims-description: "Claim and unclaim land, create outposts, and buy bonus claims." + bank-description: "Deposit, withdraw, and view bank history." + claims-description: "Claim and unclaim land, create outposts, and buy bonus claims." settings: "Town Settings" settings-title: "Town Settings" - settings-description: "PvP, mobs, fire, explosions, open, public, peaceful, and nation zone." + settings-description: "PvP, mobs, fire, explosions, open, public, peaceful, and nation zone." details: "Town Details" - details-description: "Name, board, tag, taxes, prices, spawn, and sale." + details-description: "Name, board, tag, taxes, prices, spawn, and sale." permissions-title: "Town Permissions" - permissions-description: "Who can build, break, and interact on town-owned land." - trusted-description: "Residents and towns trusted to build anywhere in town." + permissions-description: "Who can build, break, and interact on town-owned land." + trusted-description: "Residents and towns trusted to build anywhere in town." outlaws: "Outlaws" - outlaws-description: "Players declared outlaws of your town." - outlaws-count: "Outlaws: {count}" + outlaws-description: "Players declared outlaws of your town." + outlaws-count: "Outlaws: {count}" spawn: "Town Spawn" - spawn-description: "Teleport to your town spawn." + spawn-description: "Teleport to your town spawn." outpost-teleport: "Outposts" - outpost-teleport-description: "Teleport to one of your town's outposts." + outpost-teleport-description: "Teleport to one of your town's outposts." nation-open: "Open {nation}." nation-none: "Found or join a nation." delete: "Delete Town" - delete-description: "Disband your town permanently. You will be asked to confirm." + delete-description: "Disband your town permanently. You will be asked to confirm." leave: "Leave Town" leave-description: "Leave your town. You will be asked to confirm." jail: "Jail" - jail-description: "Jail residents, release prisoners, and see your jails." - jail-count: "Prisoners: {count}" + jail-description: "Jail residents, release prisoners, and see your jails." + jail-count: "Prisoners: {count}" reclaim: "Reclaim Town" - reclaim-description: "Pay to restore your ruined town and become its mayor." - reclaim-wait: "Available after {hours} hours in ruins" - click-status: "Click for level, limits, and upkeep" + reclaim-description: "Pay to restore your ruined town and become its mayor." + reclaim-wait: "Available after {hours} hours in ruins" + click-status: "Click for level, limits, and upkeep!" no-town: title: "Find a Town" found: "Found a Town" found-title: "Found a Town" - found-description: "Start a new town on the chunk you are standing in." + found-description: "Start a new town on the chunk you are standing in." town-name: "Town name" browse: "Browse Towns" browse-description: "Find an open town to join." invites-description: "Accept an invitation to a town." reclaim: "Reclaim a Ruined Town" - reclaim-description: "Stand in a ruined town and pay to become its mayor." + reclaim-description: "Stand in a ruined town and pay to become its mayor." outlaws: title: "Outlaws" - click-pardon: "Click to pardon" + click-pardon: "Click to pardon!" outlaw: "Outlaw" add-online: "Outlaw Online Player" - add-online-description: "Declare an online player an outlaw." + add-online-description: "Declare an online player an outlaw." add-name: "Outlaw by Name" - add-name-description: "Declare any player Towny knows an outlaw." + add-name-description: "Declare any player Towny knows an outlaw." declare: "Declare Outlaw" outposts: @@ -336,105 +420,105 @@ outposts: town-jail: title: "Town Jail" - hours-left: "Hours left: {hours}" - bail: "Bail: {bail}" + hours-left: "Hours left: {hours}" + bail: "Bail: {bail}" held-in: "Held in: {jail}, cell {cell}" - click-unjail: "Click to release" + click-unjail: "Click to release!" jail-player: "Jail a Player" jail-player-title: "Jail Player" - jail-player-description: "Send an online resident to one of your jails." + jail-player-description: "Send an online resident to one of your jails." no-jails: "No Jails" - no-jails-description: "Set a plot's type to Jail to build your town's first jail." + no-jails-description: "Set a plot's type to Jail to build your town's first jail." jails: "Jails" jails-title: "Town Jails" - jails-description: "Every jail plot in your town." - jails-count: "Jails: {count}" + jails-description: "Every jail plot in your town." + jails-count: "Jails: {count}" primary: "Primary jail" - cells: "Cells: {count}" - prisoners: "Prisoners: {count}" + cells: "Cells: {count}" + prisoners: "Prisoners: {count}" jail-number: "Jail #{number}" jail-sentence: title: "Jail {player}" hours: "Sentence" - hours-description: "How many hours the player stays in jail." + hours-description: "How many hours the player stays in jail." hours-title: "Jail Sentence" hours-label: "Hours" - max-hours: "Longest sentence: {hours} hours" + max-hours: "Longest sentence: {hours} hours" bail: "Bail" bail-description: "What the player can pay to leave early." bail-title: "Bail" - max-bail: "Highest bail: {bail}" + max-bail: "Highest bail: {bail}" jail: "Jail" cell: "Cell" cell-number: "Cell {number}" confirm: "Jail Player" - confirm-description: "Send the player to jail with this sentence." + confirm-description: "Send the player to jail with this sentence." claims: title: "Town Claims" info: "Claims" - claimed: "Claimed: {claims}/{max}" - available: "Available: {available}" + claimed: "Claimed: {claims}/{max}" + available: "Available: {available}" unlimited: "Unlimited" - bonus: "Bonus claims: {bonus} · Purchased: {purchased}" - outposts: "Outposts: {outposts}/{limit}" - price: "Claim price: {price}" + bonus: "Bonus claims: {bonus} · Purchased: {purchased}" + outposts: "Outposts: {outposts}/{limit}" + price: "Claim price: {price}" claim: "Claim This Chunk" - claim-description: "Claim the chunk you are standing in. It must touch your town." + claim-description: "Claim the chunk you are standing in. It must touch your town." claim-area: "Claim Area" claim-area-title: "Claim Area" - claim-area-description: "Claim a square of chunks around you." + claim-area-description: "Claim a square of chunks around you." radius: "Radius in chunks" radius-hint: "A radius of 1 claims a 3×3 square." fill: "Fill Gaps" - fill-description: "Claim wilderness fully enclosed by your town around you." + fill-description: "Claim wilderness fully enclosed by your town around you." outpost: "Claim Outpost" - outpost-description: "Claim this chunk as an outpost away from your town." + outpost-description: "Claim this chunk as an outpost away from your town." unclaim: "Unclaim This Chunk" - unclaim-description: "Return the chunk you are standing in to the wilderness." + unclaim-description: "Return the chunk you are standing in to the wilderness." unclaim-area: "Unclaim Area" unclaim-area-title: "Unclaim Area" - unclaim-area-description: "Unclaim a square of chunks around you." + unclaim-area-description: "Unclaim a square of chunks around you." unclaim-all: "Unclaim Everything" - unclaim-all-description: "Unclaim all town land except the home block." + unclaim-all-description: "Unclaim all town land except the home block." buy-bonus: "Buy Bonus Claims" buy-bonus-title: "Buy Bonus Claims" - buy-bonus-description: "Buy extra claim slots." - price-each: "Price each: {price}" - refund-each: "Refund each: {refund}" + buy-bonus-description: "Buy extra claim slots." + price-each: "Price each: {price}" + refund-each: "Refund each: {refund}" bonus-amount: "Number of claims" auto-claim: "Auto Claim" - auto-claim-description: "Claim every chunk you walk into." + auto-claim-description: "Claim every chunk you walk into." cede: "Cede This Plot" cede-title: "Cede Plot to Town" - cede-description: "Give the chunk you stand in to another town. Its mayor must be online to accept." + cede-description: "Give the chunk you stand in to another town. Its mayor must be online to accept." takeover: "Take Over Claim" - takeover-description: "Take the chunk you stand in from an overclaimed town that borders yours." + takeover-description: "Take the chunk you stand in from an overclaimed town that borders yours." town-info: gone: "This town no longer exists" manage: "Manage Your Town" manage-description: "Open your town's management menu." visit: "Visit" - visit-description: "Teleport to this town's spawn." + visit-description: "Teleport to this town's spawn." nation: "Nation: {nation}" nation-description: "View this town's nation." join: "Join Town" join-description: "This town is open to everyone." donate: "Donate" donate-title: "Donate to {town}" - donate-description: "Deposit money into this town's bank." + donate-description: "Deposit money into this town's bank." buy: "Buy Town" - buy-description: "Become this town's mayor." + buy-description: "Become this town's mayor." invite: "Invite to Nation" invite-description: "Invite this town to join {nation}." merge: "Merge into Your Town" - merge-description: "Ask the mayor of {town} to merge their town into {own}. They must be online to accept." + merge-description: "Ask the mayor of {town} to merge their town into {own}. They must be online to accept." town-list: title: "Towns" - distance: "Distance: {blocks} blocks" + distance: "Distance: {blocks} blocks" town-members: title: "Residents: {town}" @@ -453,18 +537,18 @@ town-details: rename-title: "Rename Town" board: "Town Board" board-title: "Town Board" - board-description: "Left-click to edit the message residents see on login. Right-click to clear it." + board-description: "The message residents see when they log in." tag: "Town Tag" tag-title: "Town Tag" map-color-title: "Town Map Color" map-color-description: "The colour of your town on web maps." - set-spawn-description: "Move the town spawn to where you are standing." + set-spawn-description: "Move the town spawn to where you are standing." home-block: "Set Home Block Here" - home-block-description: "Make the chunk you are standing in the town's home block." + home-block-description: "Make the chunk you are standing in the town's home block." outpost: "Set Outpost Spawn Here" - outpost-description: "Set the spawn of the outpost you are standing in." + outpost-description: "Set the spawn of the outpost you are standing in." jail: "Set Primary Jail" - jail-description: "Make the jail plot you are standing in the town's primary jail." + jail-description: "Make the jail plot you are standing in the town's primary jail." taxes: "Daily Resident Tax" tax-cap: "Percentage Tax Cap" plot-tax: "Daily Plot Tax" @@ -482,37 +566,37 @@ town-details: town-status: title: "Status: {town}" level: "Town Level" - level-description: "Your level sets how much land, how many outposts, and how much upkeep your town has." - level-number: "Level: {level}/{max}" + level-description: "Your level sets how much land, how many outposts, and how much upkeep your town has." + level-number: "Level: {level}/{max}" level-name: "Title: {name}" level-manual: "An admin set this level by hand." level-highest: "This is the highest level." - next-level-residents: "Next level at {needed} residents (now {current})" - next-level-claims: "Next level at {needed} claims (now {current})" - claims-description: "The land your town holds and how much more it may claim." - max-purchased: "Bonus claims you may buy: {count}" + next-level-residents: "Next level at {needed} residents (now {current})" + next-level-claims: "Next level at {needed} claims (now {current})" + claims-description: "The land your town holds and how much more it may claim." + max-purchased: "Bonus claims you may buy: {count}" outposts: "Outposts" - outposts-description: "Outposts let your town claim land away from its borders." + outposts-description: "Outposts let your town claim land away from its borders." upkeep: "Daily Upkeep" - upkeep-description: "What your town bank pays on the next new day." + upkeep-description: "What your town bank pays on the next new day." upkeep-exempt: "This town pays no upkeep." - upkeep-daily: "Upkeep: {cost}" - upkeep-penalty: "Overclaim penalty: {cost}" - upkeep-peaceful: "Peaceful: {cost}" - upkeep-total: "Total: {cost}" - new-day: "Next new day in: {time}" + upkeep-daily: "Upkeep: {cost}" + upkeep-penalty: "Overclaim penalty: {cost}" + upkeep-peaceful: "Peaceful: {cost}" + upkeep-total: "Total: {cost}" + new-day: "Next new day in: {time}" nation-zone: "Nation Zone" - nation-zone-description: "Protected wilderness around your town, given by your nation." - nation-zone-size: "Size: {size} chunks" + nation-zone-description: "Protected wilderness around your town, given by your nation." + nation-zone-size: "Size: {size} chunks" all-good: "All Good" all-good-description: "Your town has no warnings." ruined: "Ruined" - ruined-hours: "Removed for good in: {hours} hours" + ruined-hours: "Removed for good in: {hours} hours" bankrupt: "Bankrupt" bankrupt-description: "Pay off the debt to claim land and recruit again." - debt-cap: "Debt limit: {cap}" + debt-cap: "Debt limit: {cap}" conquered: "Conquered" - conquered-days: "Days left as conquered: {days}" + conquered-days: "Days left as conquered: {days}" overclaimed: "Overclaimed" overclaimed-description: "Unclaim land or grow the town to stop the upkeep penalty." overclaimed-stealable: "Other towns may take your land while you are overclaimed." @@ -525,10 +609,12 @@ town-trust: trust-online-description: "Trusted residents may build anywhere in town." trust-town: "Trust a Town" trust-town-title: "Trust Town" - trust-town-description: "Every resident of a trusted town may build in your town." + trust-town-description: "Every resident of a trusted town may build in your town." sort: current: "Sort: {sort}" + selected: "▶ {sort}" + option: " {sort}" residents: "Residents" claims: "Claims" towns: "Towns" @@ -541,23 +627,23 @@ sort: nation: title: "Your Nation" not-in-nation: "Your town is not in a nation" - daily-tax: "Daily town tax: {tax}" + daily-tax: "Daily town tax: {tax}" towns: "Towns" - towns-count: "Towns: {count}" + towns-count: "Towns: {count}" towns-description: "View member towns, invite towns, and remove towns." - residents-description: "View every resident and manage nation ranks." + residents-description: "View every resident and manage nation ranks." bank: "Nation Bank" relations: "Allies & Enemies" - relations-description: "Manage alliances and declare enemies." + relations-description: "Manage alliances and declare enemies." settings: "Nation Settings" settings-title: "Nation Settings" - settings-description: "Peaceful, open, public, and percentage taxes." + settings-description: "Peaceful, open, public, and percentage taxes." details: "Nation Details" - details-description: "Name, board, tag, taxes, capital, leader, and spawn." + details-description: "Name, board, tag, taxes, capital, leader, and spawn." spawn: "Nation Spawn" - spawn-description: "Teleport to your nation's spawn." + spawn-description: "Teleport to your nation's spawn." delete: "Delete Nation" - delete-description: "Disband your nation permanently. You will be asked to confirm." + delete-description: "Disband your nation permanently. You will be asked to confirm." leave: "Leave Nation" leave-description: "Take your town out of the nation. You will be asked to confirm." propose-alliance: "Propose Alliance" @@ -565,13 +651,13 @@ nation: announce: "Announce to Nation" announce-title: "Nation Announcement" announce-description: "Send a message to every online resident of the nation." - click-status: "Click for level, bonuses, and upkeep" + click-status: "Click for level, bonuses, and upkeep!" no-nation: title: "Find a Nation" found: "Found a Nation" found-title: "Found a Nation" - found-description: "Found a nation with your town as the capital." + found-description: "Found a nation with your town as the capital." nation-name: "Nation name" browse: "Browse Nations" browse-description: "Find an open nation for your town to join." @@ -581,15 +667,15 @@ nation-info: gone: "This nation no longer exists" manage: "Manage Your Nation" manage-description: "Open your nation's management menu." - visit-description: "Teleport to this nation's spawn." + visit-description: "Teleport to this nation's spawn." join: "Join Nation" join-description: "This nation is open to every town." end-alliance: "End Alliance" - end-alliance-description: "Remove this nation from your allies." - propose-alliance-description: "Send an alliance request to this nation." + end-alliance-description: "Remove this nation from your allies." + propose-alliance-description: "Send an alliance request to this nation." make-peace: "Make Peace" - make-peace-description: "Remove this nation from your enemies." - declare-enemy-description: "Mark this nation as an enemy." + make-peace-description: "Remove this nation from your enemies." + declare-enemy-description: "Mark this nation as an enemy." nation-list: title: "Nations" @@ -598,88 +684,91 @@ nation-relations: title: "Allies & Enemies: {nation}" ally: "Ally" enemy: "Enemy" - right-remove: "Right-click to remove" + right-remove: "Right-click to remove!" propose-alliance-title: "Propose Alliance" - propose-alliance-description: "Send an alliance request to another nation." + propose-alliance-description: "Send an alliance request to another nation." declare-enemy-title: "Declare Enemy" - declare-enemy-description: "Mark another nation as an enemy." + declare-enemy-description: "Mark another nation as an enemy." sent-requests: "Sent Alliance Requests" nation-towns: title: "Towns: {nation}" capital: "Capital" - right-remove: "Right-click to remove from nation" + right-remove: "Right-click to remove from the nation!" invite: "Invite a Town" invite-title: "Invite Town" invite-description: "Invite a town that isn't in a nation." sanctions: "Sanctioned Towns" - sanctions-description: "Towns kept away from your nation spawn." - sanctions-count: "Sanctioned: {count}" + sanctions-description: "Towns kept away from your nation spawn." + sanctions-count: "Sanctioned: {count}" nation-sanctions: title: "Sanctions: {nation}" - right-lift: "Right-click to lift the sanction" + right-lift: "Right-click to lift the sanction!" add: "Sanction a Town" add-title: "Sanction Town" - add-description: "Keep a town outside your nation away from your nation spawn." + add-description: "Keep a town outside your nation away from your nation spawn." leaderboard: title: "Leaderboards" info: "Leaderboards" info-description: "The same rankings as Towny's top lists. Click any entry to view it." rank: "#{rank}" + rank-first: "#1" + rank-second: "<#c0c0c0>#2" + rank-third: "<#cd7f32>#3" town-residents: "Towns by Residents" town-residents-description: "The towns with the most residents." nation-residents: "Nations by Residents" nation-residents-description: "The nations with the most residents." town-land: "Towns by Land" - town-land-description: "The towns holding the most claims." + town-land-description: "The towns holding the most claims." resident-land: "Players by Plots" - resident-land-description: "The players who own the most plots." + resident-land-description: "The players who own the most plots." town-balance: "Towns by Bank" town-balance-description: "The richest town banks." nation-balance: "Nations by Bank" nation-balance-description: "The richest nation banks." town-baltop: "Richest in Your Town" - town-baltop-description: "The residents of {town} with the most money." + town-baltop-description: "The residents of {town} with the most money." nation-baltop: "Richest in Your Nation" - nation-baltop-description: "The residents of {nation} with the most money." + nation-baltop-description: "The residents of {nation} with the most money." prices: title: "Prices & New Day" new-day: "The Towny Day" - new-day-description: "Taxes and upkeep are collected once a day." + new-day-description: "Taxes and upkeep are collected once a day." no-economy: "This server has no economy, so nothing costs money." founding: "Founding" - new-town: "New town: {cost}" - new-nation: "New nation: {cost}" - reclaim: "Reclaiming ruins: {cost}" - merge: "Merging towns: {cost}" + new-town: "New town: {cost}" + new-nation: "New nation: {cost}" + reclaim: "Reclaiming ruins: {cost}" + merge: "Merging towns: {cost}" claims: "Land" - claim: "Per claim: {cost}" - claim-refund: "Refund per unclaim: {cost}" - bonus-claim: "Per bonus claim: {cost}" - outpost: "Per outpost: {cost}" - outpost-upkeep: "Daily upkeep per outpost: {cost}" + claim: "Per claim: {cost}" + claim-refund: "Refund per unclaim: {cost}" + bonus-claim: "Per bonus claim: {cost}" + outpost: "Per outpost: {cost}" + outpost-upkeep: "Daily upkeep per outpost: {cost}" upkeep: "Daily Upkeep" upkeep-description: "Paid from the town and nation banks each new day." - town-upkeep: "Town upkeep: {cost}" - nation-upkeep: "Nation upkeep: {cost}" - overclaimed-upkeep: "Overclaim penalty: {cost}" - town-peaceful: "Peaceful town: {cost}" - nation-peaceful: "Peaceful nation: {cost}" + town-upkeep: "Town upkeep: {cost}" + nation-upkeep: "Nation upkeep: {cost}" + overclaimed-upkeep: "Overclaim penalty: {cost}" + town-peaceful: "Peaceful town: {cost}" + nation-peaceful: "Peaceful nation: {cost}" plot-prices: "Plot Prices: {town}" - plot: "Plot: {cost}" - shop: "Shop: {cost}" - embassy: "Embassy: {cost}" + plot: "Plot: {cost}" + shop: "Shop: {cost}" + embassy: "Embassy: {cost}" taxes: "Taxes: {town}" - resident-tax: "Resident tax: {cost}" - plot-tax: "Plot tax: {cost}" - shop-tax: "Shop tax: {cost}" - embassy-tax: "Embassy tax: {cost}" + resident-tax: "Resident tax: {cost}" + plot-tax: "Plot tax: {cost}" + shop-tax: "Shop tax: {cost}" + embassy-tax: "Embassy tax: {cost}" plot-types: "Plot Types" - plot-types-description: "What a mayor pays to set a plot to each type." - plot-type: "{type}: {cost}" + plot-types-description: "What a mayor pays to set a plot to each type." + plot-type: "{type}: {cost}" nation-details: title: "Nation Details" @@ -694,95 +783,99 @@ nation-details: map-color-description: "The colour of your nation on web maps." capital: "Change Capital" capital-title: "Choose Capital" - capital-click: "Click to make capital" + capital-click: "Click to make capital!" leader: "Change Leader" leader-title: "Choose Leader" - leader-description: "The leader must live in the capital." - leader-click: "Click to make leader" - set-spawn-description: "Move the nation spawn to where you are standing." + leader-description: "The leader must live in the capital." + leader-click: "Click to make leader!" + set-spawn-description: "Move the nation spawn to where you are standing." taxes: "Daily Town Tax" conquered-tax: "Conquered Town Tax" nation-status: title: "Status: {nation}" level: "Nation Level" - level-description: "Your level sets the bonuses member towns receive and the nation's upkeep." - next-level-towns: "Next level at {needed} towns (now {current})" + level-description: "Your level sets the bonuses member towns receive and the nation's upkeep." + next-level-towns: "Next level at {needed} towns (now {current})" bonuses: "Town Bonuses" bonuses-description: "What every member town gains from this nation." - bonus-claims: "Bonus claims per town: {count}" - bonus-outposts: "Bonus outposts per town: {count}" - bonus-capital-outposts: "Bonus outposts for the capital: {count}" - upkeep-description: "What your nation bank pays on the next new day." + bonus-claims: "Bonus claims per town: {count}" + bonus-outposts: "Bonus outposts per town: {count}" + bonus-capital-outposts: "Bonus outposts for the capital: {count}" + upkeep-description: "What your nation bank pays on the next new day." upkeep-short: "The nation bank cannot cover this." plot: title: "Plot" unnamed: "Plot" - refresh-description: "Update this menu after moving to another chunk." - wilderness-description: "Nobody has claimed this land." + refresh-description: "Update this menu after moving to another chunk." + wilderness-description: "Nobody has claimed this land." claim: "Claim for {town}" - claim-description: "Claim this chunk for your town." + claim-description: "Claim this chunk for your town." claim-outpost: "Claim as Outpost" - claim-outpost-description: "Claim this chunk as an outpost." + claim-outpost-description: "Claim this chunk as an outpost." group: "Group: {group}" district: "District: {district}" - claimed: "Claimed: {date}" + claimed: "Claimed: {date}" buy: "Buy Plot" - buy-description: "Become the owner of this plot." + buy-description: "Become the owner of this plot." give-up: "Give Up Plot" - give-up-description: "Return this plot to the town." + give-up-description: "Return this plot to the town." not-for-sale: "Take off Sale" - not-for-sale-description: "Stop selling this plot." + not-for-sale-description: "Stop selling this plot." for-sale: "Put up for Sale" for-sale-title: "Sell Plot" - for-sale-description: "Let a resident buy this plot." + for-sale-description: "Let a resident buy this plot." for-sale-hint: "Use 0 to give it away for free." evict: "Evict Owner" - evict-description: "Remove {owner} as this plot's owner." + evict-description: "Remove {owner} as this plot's owner." type: "Plot Type" type-title: "Plot Type" - type-description: "Shops, embassies, arenas, farms, jails, and more." + type-description: "Shops, embassies, arenas, farms, jails, and more." rename: "Rename Plot" rename-title: "Rename Plot" - rename-description: "Shown to players as they walk in. Right-click to remove the name." + rename-description: "Shown to players as they walk in." plot-name: "Plot name" settings: "Plot Settings" settings-title: "Plot Settings" - settings-description: "PvP, fire, explosions, mobs, and taxes on this plot." + settings-description: "PvP, fire, explosions, mobs, and taxes on this plot." permissions-title: "Plot Permissions" - permissions-description: "Who can build, break, and interact on this plot." + permissions-description: "Who can build, break, and interact on this plot." trusted: "Trusted Players" - trusted-description: "Trusted players may build on this plot." - trusted-count: "Trusted: {count}" + trusted-description: "Trusted players may build on this plot." + trusted-count: "Trusted: {count}" groups: "Groups & Districts" - groups-description: "Bundle plots into groups sold together, or into districts." + groups-description: "Bundle plots into groups sold together, or into districts." clear: "Clear Plot" - clear-description: "Remove blocks placed on this plot that the server marks as clearable." - town-description: "View the town that owns this land." + clear-description: "Remove blocks placed on this plot that the server marks as clearable." + town-description: "View the town that owns this land." group-applies: "Applies to all {count} plots in {group}" - evict-resell: "Right-click to evict and put the plot back up for sale" + evict-resell: "Right-click to evict and sell it again!" join-days: "Join-Day Limits" - join-days-description: "Left-click to set the fewest days a buyer must have lived in town. Right-click to set the most days allowed." + join-days-description: "The fewest and the most days a buyer must have lived in the town." + left-min-days: "Left-click to set the fewest days!" + right-max-days: "Right-click to set the most days!" join-days-none: "No limits" join-days-hint: "Use 0 to remove the limit." - min-join-days: "Fewest days in town: {days}" - max-join-days: "Most days in town: {days}" + min-join-days: "Fewest days in town: {days}" + max-join-days: "Most days in town: {days}" min-join-days-title: "Fewest Days in Town" max-join-days-title: "Most Days in Town" days: "Days" jail-cells: "Jail Cells" - jail-cells-description: "Left-click to add a cell where you stand. Right-click to remove the cell where you stand." - jail-cells-count: "Cells: {count}" + jail-cells-description: "The cells of this jail plot, where prisoners are held." + left-add-cell: "Left-click to add a cell where you stand!" + right-remove-cell: "Right-click to remove the cell where you stand!" + jail-cells-count: "Cells: {count}" hud: "Plot HUD" - hud-description: "Show or hide a sidebar with the plot you are in: owner, type, price, and permissions." + hud-description: "Show or hide a sidebar with the plot you are in: owner, type, price, and permissions." area: "Many Plots at Once" - area-description: "Buy, sell, or give up every plot in an area around you." - click-info: "Click to show Towny's plot info in chat" + area-description: "Buy, sell, or give up every plot in an area around you." + click-info: "Click to show Towny's plot info in chat!" make-outpost: "Make Outpost" - make-outpost-description: "Turn this claim into an outpost with a spawn where you stand." + make-outpost-description: "Turn this claim into an outpost with a spawn where you stand." outpost-spawn: "Move Outpost Spawn" - outpost-spawn-description: "Move this outpost's spawn to where you stand." + outpost-spawn-description: "Move this outpost's spawn to where you stand." # Towny's built-in plot types. Custom types from Towny's config show their own name unless added here. plot-type: @@ -801,22 +894,22 @@ plot-group: not-in-town: "You are not standing in a town" add: "Add to Group" add-title: "Add to Plot Group" - add-description: "Add this plot to a group, creating the group if needed." + add-description: "Add this plot to a group, creating the group if needed." group-name: "Group name" remove: "Remove from Group" - remove-description: "Take this plot out of {group}." + remove-description: "Take this plot out of {group}." rename: "Rename Group" rename-title: "Rename Plot Group" sell: "Sell Group" sell-title: "Sell Plot Group" - sell-description: "Sell every plot in the group together." + sell-description: "Sell every plot in the group together." not-for-sale: "Not for sale" stop-selling: "Stop Selling Group" delete: "Delete Group" - delete-description: "Ungroup every plot in {group}." + delete-description: "Ungroup every plot in {group}." district-add: "Add to District" district-add-title: "Add to District" - district-add-description: "Add this plot to a district, creating the district if needed." + district-add-description: "Add this plot to a district, creating the district if needed." district-name: "District name" district-remove: "Remove from District" district-rename: "Rename District" @@ -826,36 +919,36 @@ plot-group: plot-trust: title: "Plot Trust" trust-title: "Trust on Plot" - trust-online-description: "Let an online player build on this plot." + trust-online-description: "Let an online player build on this plot." group: "Group: {group}" - group-description: "Trust on this plot applies to all {count} plots in its group." + group-description: "Trust on this plot applies to all {count} plots in its group." plot-area: title: "Many Plots at Once" info: "Area Around You" - info-description: "Choose a shape and radius, then act on every plot in that area. A radius of 1 covers the 3×3 chunks around you." + info-description: "Choose a shape and radius, then act on every plot in that area. A radius of 1 covers the 3×3 chunks around you." shape: "Shape" square: "Square" circle: "Circle" radius: "Radius" radius-title: "Area Radius" - radius-description: "How many chunks the area reaches from you." + radius-description: "How many chunks the area reaches from you." buy: "Buy Plots" - buy-description: "Buy every plot for sale in the area that you are allowed to buy." + buy-description: "Buy every plot for sale in the area that you are allowed to buy." sell: "Sell Plots" sell-title: "Sell Plots in Area" - sell-description: "Put every plot you may sell in the area up for sale at one price." + sell-description: "Put every plot you may sell in the area up for sale at one price." not-for-sale: "Stop Selling Plots" - not-for-sale-description: "Take every plot you may manage in the area off sale." + not-for-sale-description: "Take every plot you may manage in the area off sale." give-up: "Give Up Plots" - give-up-description: "Return the plots you own in the area to the town." + give-up-description: "Return the plots you own in the area to the town." give-up-all: "Give Up All My Plots" - give-up-all-description: "Return every plot you own, anywhere, to its town." + give-up-all-description: "Return every plot you own, anywhere, to its town." plot-overrides: title: "Player Overrides" changed-by: "Last changed by: {player}" - click-remove: "Click to remove override" + click-remove: "Click to remove the override!" add-online: "Add Online Player" add-name: "Add by Name" add-description: "Give a player their own permissions here, then edit them in Towny's editor." @@ -865,47 +958,49 @@ plot-overrides: profile: title: "Your Profile" - registered: "Registered: {date}" - friends-count: "Friends: {count}" - plots-owned: "Plots owned: {count}" - tax-owed: "Tax owed today: {tax}" + registered: "Registered: {date}" + friends-count: "Friends: {count}" + plots-owned: "Plots owned: {count}" + tax-owed: "Tax owed today: {tax}" about-line: "About: {about}" jailed: "Jailed in {town} ({hours}h left)" jailed-unknown: "a town" friends: "Friends" - friends-description: "Friends count as residents in your personal plot permissions." + friends-description: "Friends count as residents in your personal plot permissions." settings: "Personal Settings" settings-title: "Personal Settings" - settings-description: "PvP, fire, and mobs on your plots, plus map and border display modes." + settings-description: "PvP, fire, and mobs on your plots, plus map and border display modes." permissions: "Plot Permissions" permissions-title: "Your Plot Permissions" - permissions-description: "Who can build, break, and interact on plots you personally own." + permissions-description: "Who can build, break, and interact on plots you personally own." about: "About Me" about-title: "About Me" - about-description: "Left-click to write a short bio. Right-click to clear it." + about-description: "A short bio other players see on your profile." bio: "Bio" spawn: "Go to Spawn" - spawn-description: "Teleport to your bed or your town spawn." + spawn-description: "Teleport to your bed or your town spawn." bail: "Pay Bail" - bail-description: "Pay {cost} to leave jail." + bail-description: "Pay {cost} to leave jail." modes: "Display Modes" - modes-description: "Left-click to turn every mode off, such as auto map, borders, and auto claim. Right-click to restore the server's default modes." + modes-description: "Automatic modes such as the auto map, borders, and auto claim." + left-modes-off: "Left-click to turn every mode off!" + right-modes-reset: "Right-click to restore the server's defaults!" modes-active: "Active: {modes}" plots: "My Plots" - plots-description: "Every plot you own, where it is, and what it costs you daily." + plots-description: "Every plot you own, where it is, and what it costs you daily." tax: "Daily Tax" - tax-description: "What you pay your town and for your plots on the next new day." + tax-description: "What you pay your town and for your plots on the next new day." tax-exempt: "You are exempt from taxes." - tax-town: "Town tax: {tax}" - tax-plots: "Plot tax: {tax}" - tax-total: "Total: {tax}" + tax-town: "Town tax: {tax}" + tax-plots: "Plot tax: {tax}" + tax-total: "Total: {tax}" outlawed-in: "Outlawed In" - outlawed-in-description: "Towns that have declared you an outlaw." + outlawed-in-description: "Towns that have declared you an outlaw." outlawed-in-title: "Outlawed In" trusted-in: "Trusted In" - trusted-in-description: "Towns that trust you to build anywhere in them." + trusted-in-description: "Towns that trust you to build anywhere in them." trusted-in-title: "Trusted In" - towns-count: "Towns: {count}" + towns-count: "Towns: {count}" resident-plots: title: "My Plots" @@ -913,8 +1008,8 @@ resident-plots: friends: title: "Friends" - left-view: "Left-click to view" - right-remove: "Right-click to remove" + left-view: "Left-click to view!" + right-remove: "Right-click to remove!" add-online: "Add Online Player" add-online-description: "Pick a player who is online right now." add-name: "Add by Name" @@ -925,15 +1020,15 @@ resident-profile: add-friend: "Add Friend" remove-friend: "Remove Friend" town-ranks: "Town Ranks" - town-ranks-description: "Assign ranks such as assistant or sheriff." + town-ranks-description: "Assign ranks such as assistant or sheriff." title: "Set Title" title-prompt: "Set Title" title-label: "Title" - title-description: "Left-click to set the title shown before their name. Right-click to clear it." + title-description: "The title shown before their name." surname: "Set Surname" surname-prompt: "Set Surname" surname-label: "Surname" - surname-description: "Left-click to set the surname shown after their name. Right-click to clear it." + surname-description: "The surname shown after their name." make-mayor: "Make Mayor" make-mayor-description: "Hand over leadership of your town." kick: "Kick from Town" @@ -943,11 +1038,11 @@ resident-profile: trust-description: "Trusted residents may build everywhere in your town." outlaw: "Declare Outlaw" pardon: "Pardon Outlaw" - outlaw-description: "Outlaws can be kept out of or teleported away from your town." + outlaw-description: "Outlaws can be kept out of or teleported away from your town." invite: "Invite to Town" invite-description: "Send an invitation to join your town." nation-ranks: "Nation Ranks" - nation-ranks-description: "Assign nation ranks such as assistant." + nation-ranks-description: "Assign nation ranks such as assistant." make-leader: "Make Nation Leader" make-leader-description: "Hand over leadership of your nation." @@ -960,55 +1055,55 @@ toggle: public: "Public" peaceful: "Peaceful" tax-percent: "Percentage Taxes" - tax-percent-description: "Charge taxes as a percentage of balance instead of a flat amount." + tax-percent-description: "Charge taxes as a percentage of balance instead of a flat amount." taxed: "Taxed" - taxed-description: "Charge the plot owner the town's daily plot tax." + taxed-description: "Charge the plot owner the town's daily plot tax." town-pvp-description: "Allow players to fight inside the town." - town-mobs-description: "Allow hostile mobs to spawn in town." - town-fire-description: "Allow fire to spread in town." - town-explosions-description: "Allow explosions to damage the town." + town-mobs-description: "Allow hostile mobs to spawn in town." + town-fire-description: "Allow fire to spread in town." + town-explosions-description: "Allow explosions to damage the town." town-open-description: "Let anyone join without an invite." - town-public-description: "Let outsiders teleport to your spawn and see your home block." - town-peaceful-description: "Stay out of wars and PvP." - nation-peaceful-description: "Stay out of wars; PvP is disabled in member towns." + town-public-description: "Let outsiders teleport to your spawn and see your home block." + town-peaceful-description: "Stay out of wars and PvP." + nation-peaceful-description: "Stay out of wars; PvP is disabled in member towns." nation-open-description: "Let any town join without an invite." - nation-public-description: "Let outsiders teleport to your nation spawn." + nation-public-description: "Let outsiders teleport to your nation spawn." nation-tax-percent-description: "Charge towns a percentage of their balance instead of a flat amount." - plot-pvp-description: "Allow players to fight on this plot." - plot-fire-description: "Allow fire to spread on this plot." - plot-explosions-description: "Allow explosions on this plot." - plot-mobs-description: "Allow hostile mobs to spawn on this plot." - resident-pvp-description: "Allow PvP on plots you own." - resident-fire-description: "Allow fire to spread on plots you own." - resident-explosions-description: "Allow explosions on plots you own." - resident-mobs-description: "Allow hostile mobs to spawn on plots you own." + plot-pvp-description: "Allow players to fight on this plot." + plot-fire-description: "Allow fire to spread on this plot." + plot-explosions-description: "Allow explosions on this plot." + plot-mobs-description: "Allow hostile mobs to spawn on this plot." + resident-pvp-description: "Allow PvP on plots you own." + resident-fire-description: "Allow fire to spread on plots you own." + resident-explosions-description: "Allow explosions on plots you own." + resident-mobs-description: "Allow hostile mobs to spawn on plots you own." border-titles: "Border Titles" - border-titles-description: "Show a title when you cross into a town or the wilderness." + border-titles-description: "Show a title when you cross into a town or the wilderness." auto-map: "Auto Map" - auto-map-description: "Print the Towny map in chat whenever you enter a new chunk." - auto-claim-description: "Claim each chunk you walk into for your town." + auto-map-description: "Print the Towny map in chat whenever you enter a new chunk." + auto-claim-description: "Claim each chunk you walk into for your town." auto-unclaim: "Auto Unclaim" - auto-unclaim-description: "Unclaim each chunk you walk into." + auto-unclaim-description: "Unclaim each chunk you walk into." plot-borders: "Plot Borders" - plot-borders-description: "Show particle borders when you enter a plot." + plot-borders-description: "Show particle borders when you enter a plot." constant-plot-borders: "Constant Plot Borders" - constant-plot-borders-description: "Always show particle borders of the plot you are in." + constant-plot-borders-description: "Always show particle borders of the plot you are in." town-borders: "Town Borders" town-borders-description: "Show particle borders of the town you are in." info-tool: "Info Tool" info-tool-description: "Right-click blocks with a stick to see their Towny info." ignore-plots: "Ignore Plot Titles" - ignore-plots-description: "Hide plot name and owner messages while you walk." + ignore-plots-description: "Hide plot name and owner messages while you walk." ignore-invites: "Ignore Invites" ignore-invites-description: "Stop receiving town invites." bed-spawn: "Bed Spawn" - bed-spawn-description: "Use your bed as your Towny spawn." + bed-spawn-description: "Use your bed as your Towny spawn." plot-group: "Plot Group Mode" - plot-group-description: "Add each plot you walk into to your selected plot group." + plot-group-description: "Add each plot you walk into to your selected plot group." district: "District Mode" - district-description: "Add each plot you walk into to your selected district." + district-description: "Add each plot you walk into to your selected district." nation-zone: "Nation Zone" - nation-zone-description: "Protect the land around your town as part of your nation's zone." + nation-zone-description: "Protect the land around your town as part of your nation's zone." spy: "Chat Spy" spy-description: "See messages from every town and nation chat channel." admin-bypass: "Disable Admin Powers" @@ -1019,14 +1114,14 @@ admin: config: "Towny Config" config-description: "Browse and edit every setting in Towny's config.yml. Changes are saved and applied at once." worlds: "Worlds" - worlds-description: "Per-world Towny settings: PvP, explosions, fire, mobs, claiming, and wilderness rules." - worlds-count: "Worlds: {count}" + worlds-description: "Per-world Towny settings: PvP, explosions, fire, mobs, claiming, and wilderness rules." + worlds-count: "Worlds: {count}" server: "Server Actions" server-description: "Start a new day, back up or save data, reload Towny, and change global toggles." plugin: "TownyMenu Settings" plugin-description: "Menu language, message prefix, and the menu shortcut." towns: "Manage Towns" - towns-description: "Open any town to edit, rename, or delete it without being its mayor." + towns-description: "Open any town to edit, rename, or delete it without being its mayor." towns-title: "Manage Towns" nations: "Manage Nations" nations-description: "Open any nation to edit, rename, or delete it." @@ -1034,24 +1129,24 @@ admin: residents: "Manage Residents" residents-description: "Find any resident to change their town, title, or record." residents-title: "Manage Residents" - count: "Total: {count}" + count: "Total: {count}" gone: "This no longer exists" rename: "Rename" - deposit-description: "Add money to the bank. It does not come from your balance. Whole numbers only." - withdraw-description: "Remove money from the bank. It is not paid to you. Whole numbers only." + deposit-description: "Add money to the bank. It does not come from your balance. Whole numbers only." + withdraw-description: "Remove money from the bank. It is not paid to you. Whole numbers only." search: "Search" - search-description: "Left-click to filter by name. Right-click to clear the filter." + search-description: "Filter the list by player name." filter: "Filter: {filter}" admin-config: title: "Towny Config" section-title: "Towny Config: {section}" - settings-count: "Settings: {count}" + settings-count: "Settings: {count}" path: "{path}" default: "Default: {value}" empty: "(empty)" read-only: "Edit this setting in config.yml." - right-reset: "Right-click to restore the default" + right-reset: "Right-click to restore the default!" value-label: "Value" number-label: "Number" invalid-value: "\"{value}\" is not a valid value for this setting." @@ -1067,62 +1162,62 @@ admin-world: list-title: "Towny Worlds" title: "World: {world}" using-towny: "Using Towny: {value}" - towns: "Towns: {count}" + towns: "Towns: {count}" wild-name: "Wilderness name: {name}" toggles: "World Settings" - toggles-description: "PvP, explosions, fire, mobs, war, jailing, and land repair in this world." + toggles-description: "PvP, explosions, fire, mobs, war, jailing, and land repair in this world." toggles-title: "World Settings: {world}" rename-wild: "Wilderness Name" - rename-wild-description: "The name shown when players walk into unclaimed land." + rename-wild-description: "The name shown when players walk into unclaimed land." reset: "Reset to Defaults" reset-description: "Replace this world's settings with the new-world defaults from Towny's config." wild-build: "Wilderness Building" wild-destroy: "Wilderness Breaking" wild-switch: "Wilderness Switches" wild-item-use: "Wilderness Item Use" - wild-perm-description: "Whether players may do this in unclaimed land." + wild-perm-description: "Whether players may do this in unclaimed land." toggle-using-towny: "Use Towny" toggle-using-towny-description: "Turn Towny on or off in this world. While off, the other world settings cannot be changed." toggle-claimable: "Claimable" - toggle-claimable-description: "Let towns claim land in this world." - toggle-pvp-description: "Allow PvP in this world where towns and plots allow it." + toggle-claimable-description: "Let towns claim land in this world." + toggle-pvp-description: "Allow PvP in this world where towns and plots allow it." toggle-force-pvp: "Force PvP" - toggle-force-pvp-description: "Force PvP on everywhere in this world, ignoring town settings." + toggle-force-pvp-description: "Force PvP on everywhere in this world, ignoring town settings." toggle-friendly-fire: "Friendly Fire" toggle-friendly-fire-description: "Let members of the same town or nation hurt each other." - toggle-explosions-description: "Allow explosions in this world where towns and plots allow them." + toggle-explosions-description: "Allow explosions in this world where towns and plots allow them." toggle-force-explosions: "Force Explosions" - toggle-force-explosions-description: "Force explosions on everywhere in this world, ignoring town settings." - toggle-fire-description: "Allow fire to spread in this world where towns and plots allow it." + toggle-force-explosions-description: "Force explosions on everywhere in this world, ignoring town settings." + toggle-fire-description: "Allow fire to spread in this world where towns and plots allow it." toggle-force-fire: "Force Fire" - toggle-force-fire-description: "Force fire spread on everywhere in this world, ignoring town settings." + toggle-force-fire-description: "Force fire spread on everywhere in this world, ignoring town settings." toggle-town-mobs: "Force Town Mobs" - toggle-town-mobs-description: "Force hostile mobs to spawn in every town, ignoring town settings." + toggle-town-mobs-description: "Force hostile mobs to spawn in every town, ignoring town settings." toggle-world-mobs: "World Mobs" - toggle-world-mobs-description: "Allow hostile mobs to spawn in this world." + toggle-world-mobs-description: "Allow hostile mobs to spawn in this world." toggle-wilderness-mobs: "Wilderness Mobs" - toggle-wilderness-mobs-description: "Allow hostile mobs to spawn in unclaimed land." + toggle-wilderness-mobs-description: "Allow hostile mobs to spawn in unclaimed land." toggle-war: "War Allowed" - toggle-war-description: "Allow wars in this world." + toggle-war-description: "Allow wars in this world." toggle-jailing: "Jailing" - toggle-jailing-description: "Allow players to be jailed in this world." + toggle-jailing-description: "Allow players to be jailed in this world." toggle-revert-unclaim: "Repair on Unclaim" - toggle-revert-unclaim-description: "Slowly restore unclaimed land to how it looked before it was claimed." + toggle-revert-unclaim-description: "Slowly restore unclaimed land to how it looked before it was claimed." toggle-revert-entity-explosions: "Repair Mob Explosions" - toggle-revert-entity-explosions-description: "Repair wilderness blocks destroyed by creepers and other mobs." + toggle-revert-entity-explosions-description: "Repair wilderness blocks destroyed by creepers and other mobs." toggle-revert-block-explosions: "Repair Block Explosions" - toggle-revert-block-explosions-description: "Repair wilderness blocks destroyed by beds, respawn anchors, and other blocks." + toggle-revert-block-explosions-description: "Repair wilderness blocks destroyed by beds, respawn anchors, and other blocks." toggle-plot-clear-delete: "Plot Clear" - toggle-plot-clear-delete-description: "Let mayors remove the blocks listed in Towny's config from a plot with /plot clear." + toggle-plot-clear-delete-description: "Let mayors remove the blocks listed in Towny's config from a plot with /plot clear." toggle-unclaim-block-delete: "Delete Blocks on Unclaim" - toggle-unclaim-block-delete-description: "Remove the blocks listed in Towny's config when land is unclaimed." + toggle-unclaim-block-delete-description: "Remove the blocks listed in Towny's config when land is unclaimed." toggle-unclaim-entity-delete: "Delete Entities on Unclaim" - toggle-unclaim-entity-delete-description: "Remove the entities listed in Towny's config when land is unclaimed." + toggle-unclaim-entity-delete-description: "Remove the entities listed in Towny's config when land is unclaimed." admin-server: title: "Server Actions" new-day: "New Day" - new-day-description: "Run Towny's new day now: collect taxes and upkeep and remove bankrupt and ruined towns." + new-day-description: "Run Towny's new day now: collect taxes and upkeep and remove bankrupt and ruined towns." new-day-confirm: "Start a new Towny day now?" new-hour: "New Hour" new-hour-description: "Run Towny's hourly tasks now." @@ -1131,7 +1226,7 @@ admin-server: save-database: "Save Database" save-database-description: "Save every town, nation, and resident to the database now." check-outposts: "Check Outposts" - check-outposts-description: "Remove outpost spawns that are no longer on their town's land." + check-outposts-description: "Remove outpost spawns that are no longer on their town's land." reload-config: "Reload Config" reload-config-description: "Reload Towny's config.yml." reload-lang: "Reload Language" @@ -1143,19 +1238,19 @@ admin-server: reload-all: "Reload Everything" reload-all-description: "Reload permissions, the database, the config, and the language files." town-withdraw: "Town Bank Withdrawals" - town-withdraw-description: "Let towns withdraw money from their bank." + town-withdraw-description: "Let towns withdraw money from their bank." nation-withdraw: "Nation Bank Withdrawals" - nation-withdraw-description: "Let nations withdraw money from their bank." + nation-withdraw-description: "Let nations withdraw money from their bank." debug: "Debug Mode" debug-description: "Write Towny's debug messages to its log." dev-mode: "Developer Mode" dev-mode-description: "Towny's developer mode. Keep it off on a live server." wilderness-use: "Wilderness Use" - wilderness-use-description: "Allow or deny building, breaking, switches, and item use in the wilderness of every world." + wilderness-use-description: "Allow or deny building, breaking, switches, and item use in the wilderness of every world." regenerations: "Land Repair" - regenerations-description: "Turn repair on unclaim and wilderness explosion repair on or off in every world." - left-on: "Left-click to turn on in every world" - right-off: "Right-click to turn off in every world" + regenerations-description: "Turn repair on unclaim and wilderness explosion repair on or off in every world." + left-on: "Left-click to turn on in every world!" + right-off: "Right-click to turn off in every world!" purge: "Purge Inactive Residents" purge-description: "Delete residents who have not logged in for a number of days. Towny asks you to confirm." purge-label: "Days offline" @@ -1163,13 +1258,13 @@ admin-server: check-perm: "Check a Permission" check-perm-description: "See whether an online player has a permission node." deposit-all: "Deposit into Every Bank" - deposit-all-description: "Put the same amount into every town and nation bank." + deposit-all-description: "Put the same amount into every town and nation bank." deposit-all-hint: "Paid into every town and nation bank on the server." admin-tools: add: "Add by Name" add-description: "Add a player or town to this list." - click-remove: "Click to remove" + click-remove: "Click to remove!" admin-plugin: title: "TownyMenu Settings" @@ -1181,27 +1276,27 @@ admin-plugin: prefix-description: "The MiniMessage text shown before TownyMenu's chat messages." prefix-label: "Prefix" shortcut: "Sneak + Swap-Hand Shortcut" - shortcut-description: "Open the main menu by pressing swap-hand (F) while sneaking." + shortcut-description: "Open the main menu by pressing swap-hand (F) while sneaking." join-hint: "Tutorial Hint on Join" join-hint-description: "Suggest the tutorial to players without a town when they join, until they have read every lesson." live-refresh: "Live Menu Refresh" live-refresh-description: "Update open menus when Towny changes what they show, such as a resident joining or the new day." alerts: "Chat Alerts" - alerts-description: "Announce invitations, bankruptcy, and ruin in chat, with a link to the menu that answers them." + alerts-description: "Announce invitations, bankruptcy, and ruin in chat, with a link to the menu that answers them." bank-amounts: "Bank Amounts" bank-amounts-description: "The preset amounts the deposit and withdraw menus offer. Players always get an Everything button and a custom amount too." bank-amounts-label: "Amounts, separated by commas" admin-town: title: "Admin: {town}" - bonus-blocks: "Bonus claims: {count}" - bought-blocks: "Bought claims: {count}" + bonus-blocks: "Bonus claims: {count}" + bought-blocks: "Bought claims: {count}" spawn: "Teleport to Spawn" - spawn-description: "Teleport to the town's spawn." - toggles-description: "Town settings plus admin-only overrides: forced PvP and mobs, unlimited claims, upkeep, and war." + spawn-description: "Teleport to the town's spawn." + toggles-description: "Town settings plus admin-only overrides: forced PvP and mobs, unlimited claims, upkeep, and war." toggles-title: "Town Settings: {town}" mayor: "Set Mayor" - mayor-description: "Make another resident of this town the mayor." + mayor-description: "Make another resident of this town the mayor." mayor-title: "Choose the New Mayor" add: "Add Resident" add-description: "Add a player to this town without an invite." @@ -1209,34 +1304,34 @@ admin-town: kick-description: "Remove a resident from this town." kick-title: "Kick a Resident" give-bonus: "Give Bonus Claims" - give-bonus-description: "Raise the town's claim limit. Use a negative number to lower it." + give-bonus-description: "Raise the town's claim limit. Use a negative number to lower it." give-bought: "Give Bought Claims" - give-bought-description: "Change how many claims the town counts as bought. Use a negative number to take them away." + give-bought-description: "Change how many claims the town counts as bought. Use a negative number to take them away." leave-nation: "Remove from Nation" leave-nation-description: "Make this town leave its nation." unruin: "Restore Town" - unruin-description: "Bring this ruined town back." + unruin-description: "Bring this ruined town back." delete: "Delete Town" - delete-description: "Delete this town and unclaim all of its land." + delete-description: "Delete this town and unclaim all of its land." force-pvp: "Force PvP On" - force-pvp-description: "Keep PvP on in this town, whatever the mayor sets." + force-pvp-description: "Keep PvP on in this town, whatever the mayor sets." force-no-pvp: "Force PvP Off" - force-no-pvp-description: "Keep PvP off in this town, whatever the mayor sets." + force-no-pvp-description: "Keep PvP off in this town, whatever the mayor sets." force-mobs: "Force Mobs" - force-mobs-description: "Keep hostile mob spawning on in this town, whatever the mayor sets." + force-mobs-description: "Keep hostile mob spawning on in this town, whatever the mayor sets." unlimited-claims: "Unlimited Claims" - unlimited-claims-description: "Let this town claim land without a limit." + unlimited-claims-description: "Let this town claim land without a limit." upkeep: "Upkeep" - upkeep-description: "Charge this town daily upkeep." + upkeep-description: "Charge this town daily upkeep." war: "Allowed to War" - war-description: "Let this town take part in wars." + war-description: "Let this town take part in wars." top-lists: "Visible on Top Lists" top-lists-description: "Show this town in /towny top rankings." admin-town-tools: title: "Tools: {town}" open: "More Town Tools" - open-description: "Level, merging, sale, outlaws, trust, and ranks." + open-description: "Level, merging, sale, outlaws, trust, and ranks." level: "Town Level" level-description: "Fix this town at a level, instead of letting its size decide." level-title: "Set Town Level" @@ -1244,21 +1339,21 @@ admin-town-tools: level-hint: "Enter unset to let the town size decide again." merge: "Merge a Town into This One" merge-description: "The town you pick is merged into {town} and disappears." - merge-force: "Right-click to merge even when Towny would refuse." + merge-force: "Right-click to merge even when Towny would refuse!" merge-title: "Merge Which Town?" for-sale: "Put up for Sale" - for-sale-description: "Let a player buy this town and become its mayor." + for-sale-description: "Let a player buy this town and become its mayor." for-sale-title: "Sell Town" not-for-sale: "Take off Sale" not-for-sale-description: "Stop selling this town." unconquer: "Remove Conquered Status" unconquer-description: "Free this town from the nation that conquered it." - check-outposts-description: "Remove this town's outpost spawns that are no longer on its land." + check-outposts-description: "Remove this town's outpost spawns that are no longer on its land." ranks: "Resident Ranks" - ranks-description: "Give or take town ranks, ignoring who may normally assign them." + ranks-description: "Give or take town ranks, ignoring who may normally assign them." ranks-title: "Whose Ranks?" - outlaws-description: "Players this town has declared outlaws." - trust-description: "Players trusted to build anywhere in this town." + outlaws-description: "Players this town has declared outlaws." + trust-description: "Players trusted to build anywhere in this town." trusted-towns: "Trusted Towns" trusted-towns-description: "Towns whose residents may build anywhere in this town." trust-town-title: "Trust Town" @@ -1266,21 +1361,21 @@ admin-town-tools: admin-nation: title: "Admin: {nation}" toggles: "Nation Settings" - toggles-description: "Peaceful, open, public, and percentage taxes." + toggles-description: "Peaceful, open, public, and percentage taxes." toggles-title: "Nation Settings: {nation}" - leader-description: "Make a resident of the capital the nation leader." + leader-description: "Make a resident of the capital the nation leader." add: "Add Town" add-description: "Add a town without a nation to this nation, without an invite." kick: "Kick Town" kick-description: "Remove a town from this nation." - towns: "Towns: {count}" + towns: "Towns: {count}" delete: "Delete Nation" delete-description: "Delete this nation. Its towns remain, without a nation." admin-nation-tools: title: "Tools: {nation}" open: "More Nation Tools" - open-description: "Level, merging, transfers, sanctions, and ranks." + open-description: "Level, merging, transfers, sanctions, and ranks." level: "Nation Level" level-description: "Fix this nation at a level, instead of letting its size decide." level-title: "Set Nation Level" @@ -1291,46 +1386,48 @@ admin-nation-tools: transfer-description: "Take a town out of its nation and place it in {nation}." transfer-title: "Move Which Town?" recheck: "Recheck Town Distances" - recheck-description: "Remove member towns that are too far from the capital." - sanctions-description: "Towns kept away from this nation's spawn." + recheck-description: "Remove member towns that are too far from the capital." + sanctions-description: "Towns kept away from this nation's spawn." ranks: "Resident Ranks" - ranks-description: "Give or take nation ranks, ignoring who may normally assign them." + ranks-description: "Give or take nation ranks, ignoring who may normally assign them." admin-plot: title: "Admin: Plot" open: "Plot You Stand In" - open-description: "Claim it for a player, move it to another town, trust players, or unclaim it." - wilderness-description: "Nobody has claimed this chunk." + open-description: "Claim it for a player, move it to another town, trust players, or unclaim it." + wilderness-description: "Nobody has claimed this chunk." claim: "Claim for a Player" - claim-description: "Make an online player the owner of this plot." + claim-description: "Make an online player the owner of this plot." claim-title: "Claim for Whom?" - trust-description: "Players trusted to build on this plot." + trust-description: "Players trusted to build on this plot." move: "Move to Another Town" - move-description: "Give this plot to a different town." + move-description: "Give this plot to a different town." move-title: "Give to Which Town?" unclaim: "Unclaim" - unclaim-description: "Left-click to unclaim this chunk. Right-click to unclaim a square around you." + unclaim-description: "Return this land to the wilderness." + left-unclaim: "Left-click to unclaim this chunk!" + right-unclaim-area: "Right-click to unclaim a square around you!" unclaim-title: "Unclaim Area" admin-perms: title: "Towny Permissions" open: "Towny Permissions" - open-description: "Edit townyperms.yml: the permissions every resident has, and the ranks mayors can hand out." + open-description: "Edit townyperms.yml: the permissions every resident has, and the ranks mayors can hand out." info: "townyperms.yml" info-description: "Changes are saved and applied at once, like /townyadmin townyperms." groups: "Permission Groups" - groups-description: "What players get without a rank: nomads, residents, mayors, and nation leaders." - groups-count: "Groups: {count}" + groups-description: "What players get without a rank: nomads, residents, mayors, and nation leaders." + groups-count: "Groups: {count}" group-title: "Group: {group}" town-ranks: "Town Ranks" - town-ranks-description: "The ranks a mayor can give residents, and what each one allows." + town-ranks-description: "The ranks a mayor can give residents, and what each one allows." nation-ranks: "Nation Ranks" - nation-ranks-description: "The ranks a nation leader can give residents, and what each one allows." - ranks-count: "Ranks: {count}" - node-count: "Permissions: {count}" + nation-ranks-description: "The ranks a nation leader can give residents, and what each one allows." + ranks-count: "Ranks: {count}" + node-count: "Permissions: {count}" node-label: "Permission node" - click-remove: "Click to remove this permission" - right-remove: "Right-click to delete this rank" + click-remove: "Click to remove this permission!" + right-remove: "Right-click to delete this rank!" add-node: "Add a Permission" add-node-description: "Give this group another permission node." add-rank: "Add a Rank" @@ -1349,9 +1446,9 @@ admin-resident: add-to-town-description: "Put this resident in a town without an invite." rename-description: "Rename this resident's Towny record, for example after a Minecraft name change." npc: "NPC" - npc-description: "Mark this resident as an NPC, such as a placeholder mayor." + npc-description: "Mark this resident as an NPC, such as a placeholder mayor." unjail: "Release from Jail" - unjail-description: "Free this resident from jail." + unjail-description: "Free this resident from jail." delete: "Delete Resident" delete-description: "Delete this resident's Towny data. Towny creates a new record when they next join." @@ -1359,15 +1456,14 @@ tutorial: title: "Tutorial" hub: "TownyMenu Tutorial" hub-description: "Everything worth knowing about Towny, one chapter at a time. Each lesson can take you straight to the menu it explains." - progress: "Read: {read}/{total}" + progress: "Read: {read}/{total}" all-read: "You have read every lesson!" continue: "Continue Reading" continue-description: "Open the first chapter with lessons you haven't read." chapter-line: "Chapter: {chapter}" chapter-title: "Tutorial: {chapter}" chapter-complete: "✔ Chapter complete" - click-chapter: "Click to open" - click-open-menu: "Click to open this menu" + click-open-menu: "Click to open this menu!" previous-chapter: "Previous Chapter" next-chapter: "Next Chapter" mark-all-read: "Mark Chapter as Read" @@ -1379,11 +1475,11 @@ tutorial: lesson-unread: "{lesson}" status-read: "Read" status-unread: "Not read yet" - left-open: "Left-click to open this menu" - right-read: "Right-click to mark as read" - right-unread: "Right-click to mark as unread" - click-read: "Click to mark as read" - click-unread: "Click to mark as unread" + left-open: "Left-click to open this menu!" + right-read: "Right-click to mark as read!" + right-unread: "Right-click to mark as unread!" + click-read: "Click to mark as read!" + click-unread: "Click to mark as unread!" requires-town: "Join a town to open this menu." requires-no-town: "Only players without a town can open this menu." requires-nation: "Your town must be in a nation to open this menu." @@ -1398,217 +1494,217 @@ tutorial: world-no-towny: "Towny is turned off in this world." wild-build: "Building in this world's wilderness: {value}" wild-destroy: "Breaking in this world's wilderness: {value}" - town-cost: "Founding a town costs: {cost}" - town-distance: "Minimum distance from other towns: {distance} chunks" - max-residents: "Most residents a town can have: {count}" - claims-per-resident: "Claims added per resident: {count}" - visitor-spawn-cost: "Your town's spawn cost for visitors: {cost}" - peaceful-cost: "Daily cost of being peaceful: {cost}" + town-cost: "Founding a town costs: {cost}" + town-distance: "Minimum distance from other towns: {distance} chunks" + max-residents: "Most residents a town can have: {count}" + claims-per-resident: "Claims added per resident: {count}" + visitor-spawn-cost: "Your town's spawn cost for visitors: {cost}" + peaceful-cost: "Daily cost of being peaceful: {cost}" ruins: "Town ruins: {value}" - ruins-hours: "Ruins last up to: {hours} hours" + ruins-hours: "Ruins last up to: {hours} hours" ruins-reclaim: "Ruins can be reclaimed: {value}" - chunk-size: "Each claim is {size}×{size} blocks." - claim-cost: "Price per claim: {cost}" - claim-increase: "The price rises {percent}% with each claim." - claim-refund: "Refund per unclaimed chunk: {cost}" + chunk-size: "Each claim is {size}×{size} blocks." + claim-cost: "Price per claim: {cost}" + claim-increase: "The price rises {percent}% with each claim." + claim-refund: "Refund per unclaimed chunk: {cost}" outposts-disabled: "Outposts are turned off on this server." - outpost-cost: "Price per outpost: {cost}" - bonus-cost: "Price per bonus claim: {cost}" - jail-hours: "Longest jail sentence: {hours} hours" + outpost-cost: "Price per outpost: {cost}" + bonus-cost: "Price per bonus claim: {cost}" + jail-hours: "Longest jail sentence: {hours} hours" jailed: "You are jailed: {hours} hours left." - join-nation-residents: "Residents a town needs to join a nation: {count}" - nation-cost: "Founding a nation costs: {cost}" - create-nation-residents: "Residents a town needs to found a nation: {count}" + join-nation-residents: "Residents a town needs to join a nation: {count}" + nation-cost: "Founding a nation costs: {cost}" + create-nation-residents: "Residents a town needs to found a nation: {count}" nation-spawn: "Nation spawns: {value}" - new-day: "A new day starts at: {time} (server time)" + new-day: "A new day starts at: {time} (server time)" daily-taxes: "Daily taxes: {value}" - town-upkeep: "Town upkeep per day: {cost}" - nation-upkeep: "Your nation's upkeep per day: {cost}" + town-upkeep: "Town upkeep per day: {cost}" + nation-upkeep: "Your nation's upkeep per day: {cost}" bankruptcy: "Town bankruptcy: {value}" debt: "Your town is bankrupt and owes {debt}." - merge-cost: "Base cost of merging towns: {cost}" - merge-distance: "Furthest merge distance: {distance} chunks" - reclaim-cost: "Reclaiming ruins costs: {cost}" + merge-cost: "Base cost of merging towns: {cost}" + merge-distance: "Furthest merge distance: {distance} chunks" + reclaim-cost: "Reclaiming ruins costs: {cost}" reclaim-townless: "Players without a town can reclaim ruins: {value}" - bail: "Default bail: {cost}" - max-bail: "Highest bail: {cost}" + bail: "Default bail: {cost}" + max-bail: "Highest bail: {cost}" start: title: "Getting Started" - description: "What Towny is, how to open and read these menus, the wilderness, the map, invites, and leaderboards." + description: "What Towny is, how to open and read these menus, the wilderness, the map, invites, and leaderboards." towny: "What Is Towny?" - towny-body: "Towny lets players protect land by founding towns. A town claims chunks that outsiders can't grief, collects taxes, and can join other towns in a nation. Land nobody has claimed is the wilderness." + towny-body: "Towny lets players protect land by founding towns. A town claims chunks that outsiders can't grief, collects taxes, and can join other towns in a nation. Land nobody has claimed is the wilderness." menus: "Opening the Menus" - menus-body: "Type /tm, or press swap-hand (F) while sneaking, to open the main menu. Clicking the TownyMenu prefix in chat opens it too. Every button runs the matching Towny command for you, with Towny's own costs and rules." + menus-body: "Type /tm, or press swap-hand (F) while sneaking, to open the main menu. Clicking the TownyMenu prefix in chat opens it too. Every button runs the matching Towny command for you, with Towny's own costs and rules." buttons: "Reading the Buttons" - buttons-body: "Hover over a button to read what it does. A grey dye means you lack the permission for that action. Switches glow while they are on. Names and amounts are typed into a dialog, and anything that can't be undone asks you to confirm first." + buttons-body: "Hover over a button to read what it does. A grey dye means you lack the permission for that action. Switches glow while they are on. Names and amounts are typed into a dialog, and anything that can't be undone asks you to confirm first." wilderness: "The Wilderness" - wilderness-body: "Unclaimed land belongs to no one. Depending on the world, you may be able to build there, but nothing you build is protected. Settle in a town to keep your work safe." + wilderness-body: "Unclaimed land belongs to no one. Depending on the world, you may be able to build there, but nothing you build is protected. Settle in a town to keep your work safe." map: "The Map" - map-body: "The map shows the chunks around you, coloured by who owns them: your town, your plots, your nation, allies, enemies, and other towns. Glowing tiles are for sale. Click a claimed tile to view its town, or right-click a tile for sale to buy it." + map-body: "The map shows the chunks around you, coloured by who owns them: your town, your plots, your nation, allies, enemies, and other towns. Glowing tiles are for sale. Click a claimed tile to view its town, or right-click a tile for sale to buy it." invites: "Invites" - invites-body: "Towns invite players, nations invite towns, and nations send each other alliance requests. Every pending invitation waits in the Invites menu, where you can accept or decline it. TownyMenu also tells you in chat when one arrives, and that message opens the menu." + invites-body: "Towns invite players, nations invite towns, and nations send each other alliance requests. Every pending invitation waits in the Invites menu, where you can accept or decline it. TownyMenu also tells you in chat when one arrives, and that message opens the menu." leaderboards: "Leaderboards" - leaderboards-body: "The Leaderboards menu ranks towns and nations by residents, land, and bank balance, and players by the plots they own. Click any entry to open it." + leaderboards-body: "The Leaderboards menu ranks towns and nations by residents, land, and bank balance, and players by the plots they own. Click any entry to open it." join: title: "Finding a Town" description: "Why towns matter, joining one, founding your own, and leaving." why: "Why Join a Town?" - why-body: "Town residents share protected land, can own plots, can teleport to the town spawn, and take part in their town's nation. Builds in the wilderness have none of that protection." + why-body: "Town residents share protected land, can own plots, can teleport to the town spawn, and take part in their town's nation. Builds in the wilderness have none of that protection." browse: "Joining a Town" - browse-body: "Browse the town directory and sort it by residents, claims, openness, or distance from you. Open towns let anyone join with one click. Other towns need their mayor or an assistant to invite you." + browse-body: "Browse the town directory and sort it by residents, claims, openness, or distance from you. Open towns let anyone join with one click. Other towns need their mayor or an assistant to invite you." invites: "Accepting an Invite" - invites-body: "When a town invites you, accept it in the Invites menu. You can only live in one town at a time. Turn on Ignore Invites in your personal settings if you don't want any." + invites-body: "When a town invites you, accept it in the Invites menu. You can only live in one town at a time. Turn on Ignore Invites in your personal settings if you don't want any." found: "Founding a Town" - found-body: "Stand where you want your town and choose Found a Town. The chunk you stand in becomes the town's home block and spawn, and you become its mayor. Your town must be far enough from other towns." + found-body: "Stand where you want your town and choose Found a Town. The chunk you stand in becomes the town's home block and spawn, and you become its mayor. Your town must be far enough from other towns." leave: "Leaving a Town" - leave-body: "Residents can leave from the town menu. A mayor can't leave: hand the town to another resident first, or delete it. Plots you own go back to the town when you leave." + leave-body: "Residents can leave from the town menu. A mayor can't leave: hand the town to another resident first, or delete it. Plots you own go back to the town when you leave." town: title: "Running a Town" - description: "Levels, ranks, recruiting, spawn, settings, details, announcements, merging, selling, and ruins." + description: "Levels, ranks, recruiting, spawn, settings, details, announcements, merging, selling, and ruins." ranks: "Mayor and Ranks" - ranks-body: "The mayor can do everything. Ranks such as assistant, sheriff, or builder share part of that power, and the server decides exactly what each rank may do. Assign ranks from a resident's profile in the Residents menu." + ranks-body: "The mayor can do everything. Ranks such as assistant, sheriff, or builder share part of that power, and the server decides exactly what each rank may do. Assign ranks from a resident's profile in the Residents menu." grow: "Growing Your Town" - grow-body: "Invite players from the Residents menu, or make the town Open so anyone can join. More residents usually raise how much land your town can claim." + grow-body: "Invite players from the Residents menu, or make the town Open so anyone can join. More residents usually raise how much land your town can claim." spawn: "Spawn and Home Block" - spawn-body: "The home block is the heart of your town and holds the town spawn. Residents can teleport there from the town menu, and visitors can too while the town is Public. Mayors move the spawn and home block in Town Details." + spawn-body: "The home block is the heart of your town and holds the town spawn. Residents can teleport there from the town menu, and visitors can too while the town is Public. Mayors move the spawn and home block in Town Details." settings: "Town Settings" - settings-body: "PvP, hostile mobs, fire spread, and explosions are switched on or off for the whole town. Open lets anyone join without an invite, Public lets visitors use your spawn, and Peaceful keeps the town out of PvP and war. Towns in a nation can also switch off the nation zone that protects the land around them." + settings-body: "PvP, hostile mobs, fire spread, and explosions are switched on or off for the whole town. Open lets anyone join without an invite, Public lets visitors use your spawn, and Peaceful keeps the town out of PvP and war. Towns in a nation can also switch off the nation zone that protects the land around them." details: "Name, Board, and Tag" - details-body: "In Town Details, mayors rename the town, write the board message residents see when they log in, set a short chat tag, and choose the town's map colour." + details-body: "In Town Details, mayors rename the town, write the board message residents see when they log in, set a short chat tag, and choose the town's map colour." sell: "Selling a Town" - sell-body: "A mayor can put the town up for sale in Town Details. Whoever buys it pays the price and becomes the new mayor. Towns for sale are marked in the town directory." + sell-body: "A mayor can put the town up for sale in Town Details. Whoever buys it pays the price and becomes the new mayor. Towns for sale are marked in the town directory." ruins: "Ruins and Deleting" - ruins-body: "Deleting a town gives all its land back to the wilderness. When ruins are on, a deleted or bankrupt town first becomes ruins that open up to everyone over time. Its residents can reclaim it from the town menu before it disappears, and on some servers players without a town can too, from Find a Town while standing in the ruins." + ruins-body: "Deleting a town gives all its land back to the wilderness. When ruins are on, a deleted or bankrupt town first becomes ruins that open up to everyone over time. Its residents can reclaim it from the town menu before it disappears, and on some servers players without a town can too, from Find a Town while standing in the ruins." announce: "Announcements" - announce-body: "Send a message to every online resident with Announce to Town in the Residents menu. Nation leaders can do the same for the whole nation from the nation menu." + announce-body: "Send a message to every online resident with Announce to Town in the Residents menu. Nation leaders can do the same for the whole nation from the nation menu." merge: "Merging Towns" - merge-body: "A mayor can ask another town to merge into their own from that town's page in the town directory. The other mayor must be online and accept, and then their residents, land, and bank join your town." + merge-body: "A mayor can ask another town to merge into their own from that town's page in the town directory. The other mayor must be online and accept, and then their residents, land, and bank join your town." status: "Town Level and Warnings" - status-body: "Click your town at the top of the town menu to see its level, how many residents or claims the next level needs, its land and outpost limits, and the upkeep due on the next new day. Anything that needs attention, such as debt, overclaiming, or being conquered, is listed there and on the town icon." + status-body: "Click your town at the top of the town menu to see its level, how many residents or claims the next level needs, its land and outpost limits, and the upkeep due on the next new day. Anything that needs attention, such as debt, overclaiming, or being conquered, is listed there and on the town icon." claims: title: "Claiming Land" - description: "Chunks and claim limits, claiming and unclaiming, outposts, bonus claims, and ceding or taking over land." + description: "Chunks and claim limits, claiming and unclaiming, outposts, bonus claims, and ceding or taking over land." chunks: "Claims Are Chunks" - chunks-body: "Towns claim land one chunk at a time, called a town block. Every claimed chunk is protected by your town's permissions. How many chunks you can claim depends on your residents and any bonus claims." + chunks-body: "Towns claim land one chunk at a time, called a town block. Every claimed chunk is protected by your town's permissions. How many chunks you can claim depends on your residents and any bonus claims." claim: "Claiming Land" - claim-body: "Stand next to your town and claim the chunk you are in, a square area around you, or the gaps your town surrounds. New claims must touch land your town already owns." + claim-body: "Stand next to your town and claim the chunk you are in, a square area around you, or the gaps your town surrounds. New claims must touch land your town already owns." auto: "Auto Claim" - auto-body: "Turn on Auto Claim and walk around: each chunk you step into is claimed while your town can afford it and has claims left. Turn it off again when you are done." + auto-body: "Turn on Auto Claim and walk around: each chunk you step into is claimed while your town can afford it and has claims left. Turn it off again when you are done." unclaim: "Unclaiming Land" - unclaim-body: "Unclaim chunks you no longer need to free their claim slots. The home block can't be unclaimed. Some servers slowly restore unclaimed land to how it looked before." + unclaim-body: "Unclaim chunks you no longer need to free their claim slots. The home block can't be unclaimed. Some servers slowly restore unclaimed land to how it looked before." outposts: "Outposts" - outposts-body: "An outpost is a claim away from your town, such as a distant mine or farm. Each outpost has a spawn that residents can teleport to, and more land can be claimed around it. A mayor can also turn an existing claim into an outpost, or move an outpost's spawn, from the Plot menu." + outposts-body: "An outpost is a claim away from your town, such as a distant mine or farm. Each outpost has a spawn that residents can teleport to, and more land can be claimed around it. A mayor can also turn an existing claim into an outpost, or move an outpost's spawn, from the Plot menu." bonus: "Bonus Claims" - bonus-body: "Reached your claim limit? Buy bonus claims with money from the town bank. The price can rise with each one you buy." + bonus-body: "Reached your claim limit? Buy bonus claims with money from the town bank. The price can rise with each one you buy." cede: "Ceding Land" - cede-body: "Stand in one of your town's chunks and choose Cede This Plot to give it to another town, for example to settle a border. The other town's mayor must be online to accept. The home block can't be ceded." + cede-body: "Stand in one of your town's chunks and choose Cede This Plot to give it to another town, for example to settle a border. The other town's mayor must be online to accept. The home block can't be ceded." takeover: "Taking Over Claims" - takeover-body: "A town with more land than its claim limit is overclaimed. Your town can take over chunks at the edge of an overclaimed town that touch your own land with Take Over Claim. Depending on the server, your nations may have to be enemies." + takeover-body: "A town with more land than its claim limit is overclaimed. Your town can take over chunks at the edge of an overclaimed town that touch your own land with Take Over Claim. Depending on the server, your nations may have to be enemies." plots: title: "Plots" - description: "Owning, buying, and selling plots, many plots at once, plot types, settings, trust, join-day limits, and groups." + description: "Owning, buying, and selling plots, many plots at once, plot types, settings, trust, join-day limits, and groups." what: "What Is a Plot?" - what-body: "Every chunk a town claims is a plot. The town owns it until a resident buys it, and then the owner decides who may build there. Open the Plot menu while standing in a plot to see who owns it, click its icon for Towny's full plot info, or turn on the Plot HUD to see it while you walk." + what-body: "Every chunk a town claims is a plot. The town owns it until a resident buys it, and then the owner decides who may build there. Open the Plot menu while standing in a plot to see who owns it, click its icon for Towny's full plot info, or turn on the Plot HUD to see it while you walk." buy: "Buying a Plot" - buy-body: "Plots for sale glow on the map; right-click one there to buy it from afar. Or walk into it, open the Plot menu, and choose Buy Plot to pay the price and become its owner." + buy-body: "Plots for sale glow on the map; right-click one there to buy it from afar. Or walk into it, open the Plot menu, and choose Buy Plot to pay the price and become its owner." sell: "Selling and Giving Up" - sell-body: "Owners and mayors can put a plot up for sale; a price of 0 gives it away. Give Up returns your plot to the town. Mayors can evict an owner, and right-clicking Evict Owner puts the plot straight back up for sale." + sell-body: "Owners and mayors can put a plot up for sale; a price of 0 gives it away. Give Up returns your plot to the town. Mayors can evict an owner, and right-clicking Evict Owner puts the plot straight back up for sale." types: "Plot Types" - types-body: "Mayors choose each plot's type. Shops and embassies have their own prices and taxes, and embassies can be bought by players from other towns. Arenas always allow PvP, inns let anyone sleep, farms let residents farm, wilds let residents cut trees and mine, and jails hold prisoners." + types-body: "Mayors choose each plot's type. Shops and embassies have their own prices and taxes, and embassies can be bought by players from other towns. Arenas always allow PvP, inns let anyone sleep, farms let residents farm, wilds let residents cut trees and mine, and jails hold prisoners." settings: "Plot Settings" - settings-body: "Plot owners switch PvP, fire, explosions, and mobs on their own plot, and mayors choose whether a plot is taxed. The world's own rules still come first." + settings-body: "Plot owners switch PvP, fire, explosions, and mobs on their own plot, and mayors choose whether a plot is taxed. The world's own rules still come first." trust: "Plot Trust" - trust-body: "Trust a player on one plot to let them build there without changing the plot's permissions for everyone else." + trust-body: "Trust a player on one plot to let them build there without changing the plot's permissions for everyone else." groups: "Groups and Districts" - groups-body: "A plot group bundles several plots so they are sold and managed together, like one big house. While a plot is in a group, its sale, type, settings, permissions, trust, and join-day limits change the whole group. A district names a larger area of plots, such as a market quarter." + groups-body: "A plot group bundles several plots so they are sold and managed together, like one big house. While a plot is in a group, its sale, type, settings, permissions, trust, and join-day limits change the whole group. A district names a larger area of plots, such as a market quarter." join-days: "Join-Day Limits" - join-days-body: "Mayors can keep a plot for newcomers or for long-time residents by setting the fewest days, the most days, or both, that a buyer must have lived in the town." + join-days-body: "Mayors can keep a plot for newcomers or for long-time residents by setting the fewest days, the most days, or both, that a buyer must have lived in the town." area: "Many Plots at Once" - area-body: "From the Plot menu, pick a square or circle and a radius around you, then buy every plot for sale in it, put your plots up for sale or take them off sale, or give them up. You can also give up every plot you own at once." + area-body: "From the Plot menu, pick a square or circle and a radius around you, then buy every plot for sale in it, put your plots up for sale or take them off sale, or give them up. You can also give up every plot you own at once." protection: title: "Permissions & Protection" - description: "Who may build where, friends, trust, and player overrides, PvP and other switches, outlaws, and jail." + description: "Who may build where, friends, trust, and player overrides, PvP and other switches, outlaws, and jail." actions: "Four Kinds of Actions" actions-body: "Towny protects four actions separately: Build (placing blocks), Destroy (breaking blocks), Switch (doors, buttons, levers, and containers), and Item Use (items such as flint and steel or buckets)." groups: "Who Gets Permission" - groups-body: "Each action is allowed or denied for groups of players. On town-owned land the groups are residents, nation members, allies, and outsiders. On plots owned by a resident they are friends, town residents, allies, and outsiders." + groups-body: "Each action is allowed or denied for groups of players. On town-owned land the groups are residents, nation members, allies, and outsiders. On plots owned by a resident they are friends, town residents, allies, and outsiders." town: "Town Permissions" - town-body: "Mayors decide who may build, break, and interact on land the town still owns, and plots nobody has bought follow these settings." + town-body: "Mayors decide who may build, break, and interact on land the town still owns, and plots nobody has bought follow these settings." personal: "Your Plot Permissions" - personal-body: "Your personal permissions apply to every plot you own. Set them once in your profile: plots you buy take them on, and you can still fine-tune a single plot from the Plot menu." + personal-body: "Your personal permissions apply to every plot you own. Set them once in your profile: plots you buy take them on, and you can still fine-tune a single plot from the Plot menu." friends: "Friends" - friends-body: "Friends use the friend permissions on your plots, so people you trust can build there without opening your plots to the whole town." + friends-body: "Friends use the friend permissions on your plots, so people you trust can build there without opening your plots to the whole town." trust: "Trusted Players and Towns" - trust-body: "Mayors can trust residents, or every resident of another town, to build anywhere in the town regardless of its permissions. Plot owners can trust players on a single plot." + trust-body: "Mayors can trust residents, or every resident of another town, to build anywhere in the town regardless of its permissions. Plot owners can trust players on a single plot." flags: "PvP, Fire, Explosions, and Mobs" - flags-body: "These switches exist for each world, each town, each plot, and your own plots. A server can force them on in a world, ignoring town settings. Peaceful towns and nations keep PvP off." + flags-body: "These switches exist for each world, each town, each plot, and your own plots. A server can force them on in a world, ignoring town settings. Peaceful towns and nations keep PvP off." outlaws: "Outlaws" - outlaws-body: "Mayors and trusted ranks can declare troublemakers outlaws. Depending on the server, outlaws are warned or teleported away when they enter the town, and can be jailed." + outlaws-body: "Mayors and trusted ranks can declare troublemakers outlaws. Depending on the server, outlaws are warned or teleported away when they enter the town, and can be jailed." jail: "Jail" - jail-body: "Towns can send players to a jail plot, for example outlaws or enemies killed in town. Jailed players wait out their sentence, or pay bail from their profile to leave early." + jail-body: "Towns can send players to a jail plot, for example outlaws or enemies killed in town. Jailed players wait out their sentence, or pay bail from their profile to leave early." overrides: "Player Overrides" - overrides-body: "Plot owners can give single players their own build, break, switch, and item-use rights on a plot, whatever group they belong to. Add players under Player Overrides in the plot's permissions, then edit their rights in Towny's editor." + overrides-body: "Plot owners can give single players their own build, break, switch, and item-use rights on a plot, whatever group they belong to. Add players under Player Overrides in the plot's permissions, then edit their rights in Towny's editor." jailing: "Jailing Players" - jailing-body: "Mayors and sheriffs jail online residents from the town's Jail menu, choosing the sentence, bail, jail, and cell, and can release prisoners early. A jail is a plot with the Jail type; add cells to it from the Plot menu while standing inside." + jailing-body: "Mayors and sheriffs jail online residents from the town's Jail menu, choosing the sentence, bail, jail, and cell, and can release prisoners early. A jail is a plot with the Jail type; add cells to it from the Plot menu while standing inside." nations: title: "Nations" - description: "What nations are, joining and founding one, member towns, diplomacy, sanctions, levels, settings, and spawn." + description: "What nations are, joining and founding one, member towns, diplomacy, sanctions, levels, settings, and spawn." what: "What Is a Nation?" - what-body: "A nation is a group of towns. The mayor of its capital town is the nation leader. Nations share a bank, a spawn, allies, and enemies, and member towns can receive extra claims." + what-body: "A nation is a group of towns. The mayor of its capital town is the nation leader. Nations share a bank, a spawn, allies, and enemies, and member towns can receive extra claims." join: "Joining a Nation" - join-body: "Only a mayor can take a town into a nation. Open nations accept any town; other nations must invite your town, and the invitation appears in the Invites menu." + join-body: "Only a mayor can take a town into a nation. Open nations accept any town; other nations must invite your town, and the invitation appears in the Invites menu." found: "Founding a Nation" - found-body: "A mayor whose town has no nation can found one. Their town becomes the capital, and they become the nation leader." + found-body: "A mayor whose town has no nation can found one. Their town becomes the capital, and they become the nation leader." towns: "Towns and the Capital" - towns-body: "The nation leader and assistants invite and remove towns. The leader can move the capital to another member town, or hand leadership to a resident of the capital." + towns-body: "The nation leader and assistants invite and remove towns. The leader can move the capital to another member town, or hand leadership to a resident of the capital." relations: "Allies and Enemies" - relations-body: "Nations propose alliances, which the other nation must accept, and can declare other nations enemies. Allies can't hurt each other and can be given permissions on your land. Depending on the server, enemies killed in your towns can be jailed." + relations-body: "Nations propose alliances, which the other nation must accept, and can declare other nations enemies. Allies can't hurt each other and can be given permissions on your land. Depending on the server, enemies killed in your towns can be jailed." settings: "Nation Settings" - settings-body: "Open lets any town join without an invite, Public lets outsiders use the nation spawn, and Peaceful keeps member towns out of PvP and war." + settings-body: "Open lets any town join without an invite, Public lets outsiders use the nation spawn, and Peaceful keeps member towns out of PvP and war." spawn: "Nation Spawn" - spawn-body: "Members can teleport to the nation spawn, and so can allies and visitors when the nation's settings allow it. The leader moves the spawn in Nation Details." + spawn-body: "Members can teleport to the nation spawn, and so can allies and visitors when the nation's settings allow it. The leader moves the spawn in Nation Details." sanctions: "Sanctions" - sanctions-body: "A nation can sanction towns outside it, and residents of a sanctioned town can't teleport to the nation spawn. Manage sanctioned towns from the nation's Towns menu." + sanctions-body: "A nation can sanction towns outside it, and residents of a sanctioned town can't teleport to the nation spawn. Manage sanctioned towns from the nation's Towns menu." level: "Nation Level" - level-body: "Click your nation at the top of the nation menu to see its level, what the next level needs, the bonus claims, outposts, and nation zone every member town gains, and the nation's daily upkeep." + level-body: "Click your nation at the top of the nation menu to see its level, what the next level needs, the bonus claims, outposts, and nation zone every member town gains, and the nation's daily upkeep." economy: title: "Money & Taxes" - description: "The Towny day, prices, banks, taxes, upkeep, and bankruptcy." + description: "The Towny day, prices, banks, taxes, upkeep, and bankruptcy." day: "The Towny Day" - day-body: "Once a day Towny collects taxes and upkeep. Towns and residents that can't pay what they owe face the consequences explained in the lessons below." + day-body: "Once a day Towny collects taxes and upkeep. Towns and residents that can't pay what they owe face the consequences explained in the lessons below." bank: "Town and Nation Banks" - bank-body: "Towns and nations keep money in their own bank. Anyone can deposit; withdrawing needs the right rank. The bank pays for claims, upkeep, and other town costs." + bank-body: "Towns and nations keep money in their own bank. Anyone can deposit; withdrawing needs the right rank. The bank pays for claims, upkeep, and other town costs." resident-tax: "Resident Taxes" - resident-tax-body: "Mayors set a daily tax every resident pays into the town bank, either a flat amount or a percentage of their balance. A resident who can't pay may be removed from the town." + resident-tax-body: "Mayors set a daily tax every resident pays into the town bank, either a flat amount or a percentage of their balance. A resident who can't pay may be removed from the town." plot-tax: "Plot Taxes" - plot-tax-body: "Owners of taxed plots also pay a daily plot tax, with separate rates for shops and embassies. An owner who can't pay may lose the plot." + plot-tax-body: "Owners of taxed plots also pay a daily plot tax, with separate rates for shops and embassies. An owner who can't pay may lose the plot." upkeep: "Upkeep" - upkeep-body: "Every day the town bank pays the server upkeep, which usually grows with the town's size. Nations pay upkeep from their own bank too." + upkeep-body: "Every day the town bank pays the server upkeep, which usually grows with the town's size. Nations pay upkeep from their own bank too." nation-tax: "Nation Taxes" - nation-tax-body: "Nations charge each member town a daily tax from its bank. A town that can't pay may be removed from the nation." + nation-tax-body: "Nations charge each member town a daily tax from its bank. A town that can't pay may be removed from the nation." bankruptcy: "Debt and Bankruptcy" - bankruptcy-body: "When bankruptcy is on, a town that can't pay its upkeep goes into debt instead of being lost. A bankrupt town can't claim land or recruit until the debt is paid. Otherwise the town falls into ruin or is deleted. Either way TownyMenu warns the mayor in chat." + bankruptcy-body: "When bankruptcy is on, a town that can't pay its upkeep goes into debt instead of being lost. A bankrupt town can't claim land or recruit until the debt is paid. Otherwise the town falls into ruin or is deleted. Either way TownyMenu warns the mayor in chat." prices: "Prices and the Next Day" - prices-body: "Prices & New Day, on the main menu, counts down to the next Towny day and lists what this server charges for founding, claiming, upkeep, plots, and taxes. Buttons that cost money also show their own price, so you can see what a claim, a teleport, or a plot takes before you click it." + prices-body: "Prices & New Day, on the main menu, counts down to the next Towny day and lists what this server charges for founding, claiming, upkeep, plots, and taxes. Buttons that cost money also show their own price, so you can see what a claim, a teleport, or a plot takes before you click it." profile: title: "Your Profile" - description: "Your profile, other players, your plots and taxes, what you see while exploring, and spawning." + description: "Your profile, other players, your plots and taxes, what you see while exploring, and spawning." menu: "Your Profile" - menu-body: "Your profile shows your town, ranks, friends, plots, and balance. Write a short bio that other players see when they look at your profile." + menu-body: "Your profile shows your town, ranks, friends, plots, and balance. Write a short bio that other players see when they look at your profile." others: "Other Players" - others-body: "Click any resident in a town, nation, or friends list to view their profile. From there you can add them as a friend, and mayors can invite, trust, rank, or kick them." + others-body: "Click any resident in a town, nation, or friends list to view their profile. From there you can add them as a friend, and mayors can invite, trust, rank, or kick them." display: "Borders, Titles, and the Info Tool" - display-body: "Personal settings change what you see while exploring: a title when you cross into a town, particle borders around plots and towns, a chat map in every new chunk, and an info tool that shows who owns a block. Display Modes in your profile turns every mode off at once, or restores the server's defaults." + display-body: "Personal settings change what you see while exploring: a title when you cross into a town, particle borders around plots and towns, a chat map in every new chunk, and an info tool that shows who owns a block. Display Modes in your profile turns every mode off at once, or restores the server's defaults." spawn: "Spawning" - spawn-body: "Go to Spawn teleports you to your town spawn, or to your bed while Bed Spawn is on. Spawning may cost money and have a cooldown, depending on the server." + spawn-body: "Go to Spawn teleports you to your town spawn, or to your bed while Bed Spawn is on. Spawning may cost money and have a cooldown, depending on the server." standing: "Plots, Taxes, and Standing" - standing-body: "The bottom of your profile lists every plot you own, what you will pay in tax on the next new day, the towns that outlaw you, and the towns that trust you to build in them." + standing-body: "The bottom of your profile lists every plot you own, what you will pay in tax on the next new day, the towns that outlaw you, and the towns that trust you to build in them." diff --git a/src/main/resources/lang/zh_CN.yml b/src/main/resources/lang/zh_CN.yml index 4c311ac..38bdc83 100644 --- a/src/main/resources/lang/zh_CN.yml +++ b/src/main/resources/lang/zh_CN.yml @@ -3,6 +3,13 @@ # 文本使用 MiniMessage 格式 (https://docs.advntr.dev/minimessage/format.html)。请保留所有 {占位符},TownyMenu 会自动填入。 # 此文件中缺失的键会先使用插件内置的同语言文件,再使用英文。 # 修改后请执行 /townymenu reload。 +# +# 颜色遵循统一的配色,让同类文字在所有菜单中保持一致: +# 标签与说明 普通数值、玩家名称 +# 金钱、城镇、领导者 国家 +# 数量、土地、地块、盟友 日期与时间、菜单和按钮名称 +# 出生点与前哨 危险、PvP、敌人、通缉犯、监狱 +# 点击提示以“!”结尾:左键或点击用 ,右键用 ,删除或移除类操作用 。 command: usage: "用法: /{command} <子命令>" @@ -40,10 +47,10 @@ common: # 多个菜单共用(接上方 common 部分)。 current: "当前: {value}" - cost: "费用: {cost}" - price: "价格: {price}" - pending: "待处理: {count}" - founded: "建立于: {date}" + cost: "费用: {cost}" + price: "价格: {price}" + pending: "待处理: {count}" + founded: "建立于: {date}" amount: "金额" price-label: "价格" player-name: "玩家名称" @@ -52,33 +59,104 @@ common: tag: "标签" tag-description: "显示在聊天中的简短标签。" map-color: "地图颜色" - map-description: "查看你周围的土地。" + map-description: "查看你周围的土地。" set-spawn: "在此设置出生点" permissions: "权限" - click-change: "点击修改" - click-details: "点击查看详情" - click-view: "点击查看" - click-teleport: "点击传送" - click-untrust: "点击取消信任" - left-details: "左键查看详情" sent-invites: "已发送的邀请" - sent-invites-description: "右键撤回所有待处理的邀请。" + sent-invites-description: "你的城镇已发出、尚未得到回应的邀请。" trusted: "受信任" trusted-title: "受信任" trust-title: "信任玩家" trust-online: "信任在线玩家" trust-name: "按名称信任" - trust-name-description: "信任 Towny 记录中的任意玩家。" + trust-name-description: "信任 Towny 记录中的任意玩家。" duration: "{hours} 小时 {minutes} 分钟" + list-entry: "• {entry}" + progress-bar: "{filled}{empty} {percent}%" menu: close: "关闭" - back: "返回" + back: "返回" + back-to: "返回至 {menu}" no-permission: "你没有权限执行此操作。" empty: "这里还什么都没有" - previous-page: "上一页" - next-page: "下一页" - page: "第 {page}/{pages} 页" + previous-page: "上一页" + next-page: "下一页" + page: "第 {page}/{pages} 页" + +click: + open: "点击打开!" + view: "点击查看!" + browse: "点击浏览!" + details: "点击查看详情!" + left-details: "左键查看详情!" + change: "点击修改!" + next: "左键切换下一项!" + previous: "右键切换上一项!" + turn-page: "点击翻页!" + teleport: "点击传送!" + choose: "点击选择!" + choose-player: "点击选择玩家!" + choose-town: "点击选择城镇!" + choose-nation: "点击选择国家!" + choose-radius: "点击选择半径!" + choose-days: "点击输入天数!" + type-name: "点击输入名称!" + type-amount: "点击输入金额!" + type-node: "点击输入权限节点!" + write: "点击编写消息!" + set: "点击设置!" + set-here: "点击设在此处!" + set-price: "点击设置价格!" + stop-selling: "点击停止出售!" + edit: "左键编辑!" + left-rename: "左键重命名!" + clear: "右键清除!" + rename: "点击重命名!" + edit-permissions: "点击编辑权限!" + edit-ranks: "点击编辑职位!" + claim: "点击占领!" + unclaim: "点击放弃!" + take-over: "点击夺取!" + buy: "点击购买!" + pay: "点击支付!" + donate: "点击捐款!" + give-up: "点击放弃!" + evict: "点击驱逐!" + clear-plot: "点击清理!" + invite: "点击邀请!" + join: "点击加入!" + leave: "点击离开!" + delete: "点击删除!" + found: "点击创建!" + reclaim: "点击收复!" + merge: "点击合并!" + kick: "点击踢出!" + make-mayor: "点击设为镇长!" + make-leader: "点击设为国王!" + make-outpost: "点击设为前哨!" + add: "点击添加!" + remove: "点击移除!" + trust: "点击信任!" + untrust: "点击取消信任!" + outlaw: "点击宣布为通缉犯!" + pardon: "点击赦免!" + propose: "点击提议结盟!" + end-alliance: "点击解除同盟!" + declare-enemy: "点击宣布为敌人!" + make-peace: "点击讲和!" + revoke-all: "右键全部撤回!" + jail: "点击关押!" + release: "点击释放!" + free: "点击解除!" + restore: "点击恢复!" + reset: "点击重置!" + run: "点击执行!" + reload: "点击重新加载!" + refresh: "点击刷新!" + search: "点击搜索!" + show-hud: "点击显示信息面板!" + open-editor: "点击打开编辑器!" dialog: confirm: "确认" @@ -87,60 +165,63 @@ dialog: cannot-undo: "此操作无法撤销。" icon: - currently: "当前: {value}" - click-toggle: "点击切换" - bank: "银行: {balance}" + bank: "银行: {balance}" + status: "状态: {value}" + enabled: "已启用" + disabled: "已禁用" + click-enable: "点击启用!" + click-disable: "点击禁用!" open-public: "开放: {open} · 公开: {public}" resident: - town: "城镇: {town}" + town: "城镇: {town}" mayor: "镇长" ranks: "职位: {ranks}" online: "在线" - last-online: "最后在线: {date}" + last-online: "最后在线: {date}" town: mayor: "镇长: {mayor}" - residents: "居民: {count}" - claims: "领地: {claims}/{max}" - nation: "国家: {nation}" + residents: "居民: {count}" + claims: "领地: {claims}/{max}" + nation: "国家: {nation}" for-sale: "出售中: {price}" ruined: "已荒废" nation: leader: "国王: {leader}" - capital: "首都: {capital}" - size: "城镇: {towns} · 居民: {residents}" - relations: "盟友: {allies} · 敌人: {enemies}" + capital: "首都: {capital}" + size: "城镇: {towns} · 居民: {residents}" + relations: "盟友: {allies} · 敌人: {enemies}" flags: "开放: {open} · 公开: {public} · 和平: {peaceful}" main: title: "Towny" unregistered: "Towny 尚未登记你的信息" unregistered-hint: "请稍后再试。" - profile-click: "点击打开个人资料" + profile-click: "点击查看个人资料!" town: "城镇" - town-click: "点击管理你的城镇" + town-click: "点击管理你的城镇!" town-none: "你还没有加入城镇。可以创建城镇、加入城镇或查看邀请。" nation: "国家" nation-locked: "国家" - nation-click: "点击管理你的国家" + nation-click: "点击管理你的国家!" nation-none: "你的城镇还没有加入国家。可以建立国家或加入国家。" nation-no-town: "加入国家前请先加入一个城镇。" plot: "当前地块" - plot-description: "购买、出售和设置你所在的地块。" - plot-here: "所在位置: {town}" + plot-description: "购买、出售和设置你所在的地块。" + plot-here: "所在位置: {town}" wilderness: "荒野" map: "地图" - map-description: "查看你周围的土地归属。" + map-description: "查看你周围的土地归属。" towns: "城镇列表" towns-description: "浏览所有城镇并排序。" nations: "国家列表" nations-description: "浏览所有国家并排序。" invites: "邀请" - invites-count: "邀请 ({count})" - invites-description: "城镇邀请、国家邀请和结盟请求。" + invites-count: "邀请 ({count})" + invites-description: "城镇邀请、国家邀请和结盟请求。" admin: "服务器管理" admin-description: "配置 Towny,并管理所有城镇、国家和居民。" tutorial: "教程" - tutorial-description: "了解城镇、地块、国家以及这些菜单的用法。" + tutorial-description: "了解城镇、地块、国家以及这些菜单的用法。" prices: "价格与新的一天" prices-description: "本服务器各项费用,以及下一个 Towny 日何时开始。" leaderboards: "排行榜" @@ -167,9 +248,9 @@ map: legend-for-sale: "发光的格子正在出售。" legend-north: "上方为北。" claim: "占领所在区块" - claim-description: "占领你所在的区块。" + claim-description: "占领你所在的区块。" unclaim: "放弃所在区块" - unclaim-description: "放弃你所在区块的领地。" + unclaim-description: "放弃你所在区块的领地。" refresh: "刷新" refresh-description: "以你当前的位置重新绘制地图。" you-are-here: "你在这里" @@ -179,9 +260,9 @@ map: type: "类型: {type}" home-block: "主区块" outpost: "前哨" - for-sale: "出售中: {price}" - click-town: "点击查看城镇" - right-buy: "右键购买此地块" + for-sale: "出售中: {price}" + click-town: "点击查看城镇!" + right-buy: "右键购买此地块!" invites: title: "邀请" @@ -190,36 +271,36 @@ invites: nation: "邀请你的城镇加入 {nation}" alliance: "来自 {nation} 的结盟请求" sender: "发送者: {sender}" - left-accept: "左键接受" - right-decline: "右键拒绝" + left-accept: "左键接受!" + right-decline: "右键拒绝!" bank: title: "银行: {name}" info: "{name} 银行" - balance: "余额: {balance}" - daily-tax: "每日税款: {tax}" + balance: "余额: {balance}" + daily-tax: "每日税款: {tax}" deposit: "存款" deposit-title: "存款" - deposit-description: "把你的钱存入银行。" + deposit-description: "把你的钱存入银行。" withdraw: "取款" withdraw-title: "取款" - withdraw-description: "从银行中取出钱。" + withdraw-description: "从银行中取出钱。" prompt-balance: "银行余额: {balance}" history: "银行记录" history-description: "打开记录近期交易的书。" - click-choose: "点击选择金额" + click-choose: "点击选择金额!" deposit-menu-title: "存款: {name}" withdraw-menu-title: "取款: {name}" - your-balance: "你的余额: {balance}" - minimum: "最低: {amount}" - maximum: "最高: {amount}" + your-balance: "你的余额: {balance}" + minimum: "最低: {amount}" + maximum: "最高: {amount}" amount: "{amount}" - amount-line: "金额: {amount}" + amount-line: "金额: {amount}" all: "全部" custom: "自定义金额" custom-description: "自行输入任意金额。" - click-deposit: "点击存入" - click-withdraw: "点击取出" + click-deposit: "点击存入!" + click-withdraw: "点击取出!" not-enough: "金钱不足" nothing-to-move: "没有可转移的金额" below-minimum: "低于最低限额 {amount}" @@ -227,12 +308,14 @@ bank: perm: gone: "这片土地已不存在" - everyone-on: "点击为所有人开启" - everyone-off: "点击为所有人关闭" - every-action-on: "点击开启所有行为" - every-action-off: "点击关闭所有行为" + everyone-on: "点击为所有人开启!" + everyone-off: "点击为所有人关闭!" + every-action-on: "点击开启所有行为!" + every-action-off: "点击关闭所有行为!" allowed: "允许" denied: "禁止" + click-allow: "点击允许!" + click-deny: "点击禁止!" reset: "重置" reset-description: "恢复服务器的默认权限。" residents: "居民" @@ -250,10 +333,10 @@ perm: item-use: "物品使用" item-use-description: "使用打火石、桶等物品。" overrides: "玩家单独权限" - overrides-description: "为个别玩家单独设置在此土地上的建造、破坏和交互权限。" + overrides-description: "为个别玩家单独设置在此土地上的建造、破坏和交互权限。" picker: - select: "点击选择" + select: "点击选择!" current: "当前" rank: @@ -261,71 +344,71 @@ rank: nation-title: "国家职位: {name}" assigned: "已授予" not-assigned: "未授予" - click-assign: "点击授予" - click-remove: "点击撤销" + click-assign: "点击授予!" + click-remove: "点击撤销!" not-allowed: "你无法授予此职位。" town: title: "我的城镇" not-in-town: "你不在任何城镇中" - plot-tax: "地块税: {tax}" - outposts: "前哨: {count}" + plot-tax: "地块税: {tax}" + outposts: "前哨: {count}" pvp-mobs: "PvP: {pvp} · 怪物: {mobs}" fire-explosions: "火焰: {fire} · 爆炸: {explosions}" residents: "居民" - residents-description: "查看居民、管理职位和邀请玩家。" + residents-description: "查看居民、管理职位和邀请玩家。" bank: "城镇银行" - bank-description: "存款、取款和查看银行记录。" - claims-description: "占领和放弃土地、建立前哨以及购买额外领地。" + bank-description: "存款、取款和查看银行记录。" + claims-description: "占领和放弃土地、建立前哨以及购买额外领地。" settings: "城镇设置" settings-title: "城镇设置" - settings-description: "PvP、怪物、火焰、爆炸、开放、公开、和平与国家区域。" + settings-description: "PvP、怪物、火焰、爆炸、开放、公开、和平与国家区域。" details: "城镇详情" - details-description: "名称、公告、标签、税款、价格、出生点和出售。" + details-description: "名称、公告、标签、税款、价格、出生点和出售。" permissions-title: "城镇权限" - permissions-description: "谁可以在城镇土地上建造、破坏和交互。" - trusted-description: "可以在城镇任意位置建造的受信任居民和城镇。" + permissions-description: "谁可以在城镇土地上建造、破坏和交互。" + trusted-description: "可以在城镇任意位置建造的受信任居民和城镇。" outlaws: "通缉犯" - outlaws-description: "被你的城镇宣布为通缉犯的玩家。" - outlaws-count: "通缉犯: {count}" + outlaws-description: "被你的城镇宣布为通缉犯的玩家。" + outlaws-count: "通缉犯: {count}" spawn: "城镇出生点" - spawn-description: "传送到你的城镇出生点。" + spawn-description: "传送到你的城镇出生点。" outpost-teleport: "前哨" - outpost-teleport-description: "传送到你城镇的某个前哨。" + outpost-teleport-description: "传送到你城镇的某个前哨。" nation-open: "打开 {nation}。" nation-none: "建立或加入一个国家。" delete: "删除城镇" - delete-description: "永久解散你的城镇。执行前会要求确认。" + delete-description: "永久解散你的城镇。执行前会要求确认。" leave: "离开城镇" leave-description: "离开你的城镇。执行前会要求确认。" jail: "监狱" - jail-description: "关押居民、释放囚犯并查看城镇监狱。" - jail-count: "囚犯:{count}" + jail-description: "关押居民、释放囚犯并查看城镇监狱。" + jail-count: "囚犯:{count}" reclaim: "收复城镇" - reclaim-description: "付费恢复已成为废墟的城镇,并成为其镇长。" - reclaim-wait: "成为废墟 {hours} 小时后可收复" - click-status: "点击查看等级、上限与维护费" + reclaim-description: "付费恢复已成为废墟的城镇,并成为其镇长。" + reclaim-wait: "成为废墟 {hours} 小时后可收复" + click-status: "点击查看等级、上限与维护费!" no-town: title: "寻找城镇" found: "创建城镇" found-title: "创建城镇" - found-description: "在你所在的区块建立一个新城镇。" + found-description: "在你所在的区块建立一个新城镇。" town-name: "城镇名称" browse: "浏览城镇" browse-description: "寻找一个可以加入的开放城镇。" invites-description: "接受加入城镇的邀请。" reclaim: "收复废墟城镇" - reclaim-description: "站在废墟城镇中,付费成为其镇长。" + reclaim-description: "站在废墟城镇中,付费成为其镇长。" outlaws: title: "通缉犯" - click-pardon: "点击赦免" + click-pardon: "点击赦免!" outlaw: "通缉犯" add-online: "通缉在线玩家" - add-online-description: "将一名在线玩家宣布为通缉犯。" + add-online-description: "将一名在线玩家宣布为通缉犯。" add-name: "按名称通缉" - add-name-description: "将 Towny 记录中的任意玩家宣布为通缉犯。" + add-name-description: "将 Towny 记录中的任意玩家宣布为通缉犯。" declare: "宣布通缉" outposts: @@ -336,105 +419,105 @@ outposts: town-jail: title: "城镇监狱" - hours-left: "剩余时间:{hours} 小时" - bail: "保释金:{bail}" + hours-left: "剩余时间:{hours} 小时" + bail: "保释金:{bail}" held-in: "关押于:{jail},{cell} 号牢房" - click-unjail: "点击释放" + click-unjail: "点击释放!" jail-player: "关押玩家" jail-player-title: "关押玩家" - jail-player-description: "把一名在线居民送进城镇监狱。" + jail-player-description: "把一名在线居民送进城镇监狱。" no-jails: "没有监狱" - no-jails-description: "把一个地块的类型设为监狱,建立城镇的第一座监狱。" + no-jails-description: "把一个地块的类型设为监狱,建立城镇的第一座监狱。" jails: "监狱列表" jails-title: "城镇监狱列表" - jails-description: "城镇中的所有监狱地块。" - jails-count: "监狱:{count}" + jails-description: "城镇中的所有监狱地块。" + jails-count: "监狱:{count}" primary: "主监狱" - cells: "牢房:{count}" - prisoners: "囚犯:{count}" + cells: "牢房:{count}" + prisoners: "囚犯:{count}" jail-number: "{number} 号监狱" jail-sentence: title: "关押 {player}" hours: "刑期" - hours-description: "玩家在监狱中关押的小时数。" + hours-description: "玩家在监狱中关押的小时数。" hours-title: "刑期" hours-label: "小时" - max-hours: "最长刑期:{hours} 小时" + max-hours: "最长刑期:{hours} 小时" bail: "保释金" bail-description: "玩家提前出狱需支付的金额。" bail-title: "保释金" - max-bail: "最高保释金:{bail}" + max-bail: "最高保释金:{bail}" jail: "监狱" cell: "牢房" cell-number: "{number} 号牢房" confirm: "确认关押" - confirm-description: "按此刑期将玩家送进监狱。" + confirm-description: "按此刑期将玩家送进监狱。" claims: title: "城镇领地" info: "领地" - claimed: "已占领: {claims}/{max}" - available: "可用: {available}" + claimed: "已占领: {claims}/{max}" + available: "可用: {available}" unlimited: "无限" - bonus: "额外领地: {bonus} · 已购买: {purchased}" - outposts: "前哨: {outposts}/{limit}" - price: "占领价格: {price}" + bonus: "额外领地: {bonus} · 已购买: {purchased}" + outposts: "前哨: {outposts}/{limit}" + price: "占领价格: {price}" claim: "占领此区块" - claim-description: "占领你所在的区块,它必须与你的城镇相邻。" + claim-description: "占领你所在的区块,它必须与你的城镇相邻。" claim-area: "占领区域" claim-area-title: "占领区域" - claim-area-description: "占领你周围一片正方形的区块。" + claim-area-description: "占领你周围一片正方形的区块。" radius: "半径(区块)" radius-hint: "半径为 1 时占领 3×3 的区域。" fill: "填补空隙" - fill-description: "占领你周围被城镇完全包围的荒野。" + fill-description: "占领你周围被城镇完全包围的荒野。" outpost: "占领前哨" - outpost-description: "将此区块占领为远离城镇的前哨。" + outpost-description: "将此区块占领为远离城镇的前哨。" unclaim: "放弃此区块" - unclaim-description: "将你所在的区块归还荒野。" + unclaim-description: "将你所在的区块归还荒野。" unclaim-area: "放弃区域" unclaim-area-title: "放弃区域" - unclaim-area-description: "放弃你周围一片正方形的区块。" + unclaim-area-description: "放弃你周围一片正方形的区块。" unclaim-all: "放弃全部领地" - unclaim-all-description: "放弃除主区块外的所有城镇土地。" + unclaim-all-description: "放弃除主区块外的所有城镇土地。" buy-bonus: "购买额外领地" buy-bonus-title: "购买额外领地" - buy-bonus-description: "购买额外的领地名额。" - price-each: "单价: {price}" - refund-each: "每块返还: {refund}" + buy-bonus-description: "购买额外的领地名额。" + price-each: "单价: {price}" + refund-each: "每块返还: {refund}" bonus-amount: "领地数量" auto-claim: "自动占领" - auto-claim-description: "自动占领你走进的每个区块。" + auto-claim-description: "自动占领你走进的每个区块。" cede: "割让此地块" cede-title: "将地块割让给城镇" - cede-description: "把你所站的区块交给另一个城镇。对方镇长必须在线并接受。" + cede-description: "把你所站的区块交给另一个城镇。对方镇长必须在线并接受。" takeover: "夺取领地" - takeover-description: "从与你相邻、领地超额的城镇夺取你所站的区块。" + takeover-description: "从与你相邻、领地超额的城镇夺取你所站的区块。" town-info: gone: "该城镇已不存在" manage: "管理你的城镇" manage-description: "打开你城镇的管理菜单。" visit: "参观" - visit-description: "传送到该城镇的出生点。" + visit-description: "传送到该城镇的出生点。" nation: "国家: {nation}" nation-description: "查看该城镇所属的国家。" join: "加入城镇" join-description: "该城镇对所有人开放。" donate: "捐款" donate-title: "向 {town} 捐款" - donate-description: "向该城镇的银行存入资金。" + donate-description: "向该城镇的银行存入资金。" buy: "购买城镇" - buy-description: "成为该城镇的镇长。" + buy-description: "成为该城镇的镇长。" invite: "邀请加入国家" invite-description: "邀请该城镇加入 {nation}。" merge: "并入你的城镇" - merge-description: "请求 {town} 的镇长将其城镇并入 {own}。对方必须在线并接受。" + merge-description: "请求 {town} 的镇长将其城镇并入 {own}。对方必须在线并接受。" town-list: title: "城镇列表" - distance: "距离:{blocks} 格" + distance: "距离:{blocks} 格" town-members: title: "居民: {town}" @@ -453,18 +536,18 @@ town-details: rename-title: "重命名城镇" board: "城镇公告" board-title: "城镇公告" - board-description: "左键编辑居民登录时看到的消息,右键清除。" + board-description: "居民登录时看到的公告。" tag: "城镇标签" tag-title: "城镇标签" map-color-title: "城镇地图颜色" map-color-description: "你的城镇在网页地图上的颜色。" - set-spawn-description: "将城镇出生点移动到你所在的位置。" + set-spawn-description: "将城镇出生点移动到你所在的位置。" home-block: "设为主区块" - home-block-description: "将你所在的区块设为城镇的主区块。" + home-block-description: "将你所在的区块设为城镇的主区块。" outpost: "设为前哨出生点" - outpost-description: "设置你所在前哨的出生点。" + outpost-description: "设置你所在前哨的出生点。" jail: "设为主监狱" - jail-description: "将你所在的监狱地块设为城镇的主监狱。" + jail-description: "将你所在的监狱地块设为城镇的主监狱。" taxes: "每日居民税" tax-cap: "百分比税上限" plot-tax: "每日地块税" @@ -482,37 +565,37 @@ town-details: town-status: title: "状态:{town}" level: "城镇等级" - level-description: "等级决定你的城镇可拥有的土地、前哨数量以及维护费。" - level-number: "等级:{level}/{max}" + level-description: "等级决定你的城镇可拥有的土地、前哨数量以及维护费。" + level-number: "等级:{level}/{max}" level-name: "称号:{name}" level-manual: "管理员手动设置了该等级。" level-highest: "已达到最高等级。" - next-level-residents: "达到 {needed} 名居民可升级(当前 {current})" - next-level-claims: "达到 {needed} 块领地可升级(当前 {current})" - claims-description: "城镇已拥有的土地,以及还能占领多少。" - max-purchased: "可购买的额外领地:{count}" + next-level-residents: "达到 {needed} 名居民可升级(当前 {current})" + next-level-claims: "达到 {needed} 块领地可升级(当前 {current})" + claims-description: "城镇已拥有的土地,以及还能占领多少。" + max-purchased: "可购买的额外领地:{count}" outposts: "前哨" - outposts-description: "前哨让城镇可以在边界之外占领土地。" + outposts-description: "前哨让城镇可以在边界之外占领土地。" upkeep: "每日维护费" - upkeep-description: "下一个新的一天城镇银行需要支付的金额。" + upkeep-description: "下一个新的一天城镇银行需要支付的金额。" upkeep-exempt: "此城镇无需支付维护费。" - upkeep-daily: "维护费:{cost}" - upkeep-penalty: "领地超额罚金:{cost}" - upkeep-peaceful: "和平状态:{cost}" - upkeep-total: "合计:{cost}" - new-day: "距离新的一天:{time}" + upkeep-daily: "维护费:{cost}" + upkeep-penalty: "领地超额罚金:{cost}" + upkeep-peaceful: "和平状态:{cost}" + upkeep-total: "合计:{cost}" + new-day: "距离新的一天:{time}" nation-zone: "国家区域" - nation-zone-description: "由国家赋予的、城镇周围受保护的荒野。" - nation-zone-size: "范围:{size} 个区块" + nation-zone-description: "由国家赋予的、城镇周围受保护的荒野。" + nation-zone-size: "范围:{size} 个区块" all-good: "一切正常" all-good-description: "你的城镇没有任何警告。" ruined: "已成废墟" - ruined-hours: "将在 {hours} 小时后彻底消失" + ruined-hours: "将在 {hours} 小时后彻底消失" bankrupt: "已破产" bankrupt-description: "还清债务后才能重新占领土地和招募居民。" - debt-cap: "债务上限:{cap}" + debt-cap: "债务上限:{cap}" conquered: "已被征服" - conquered-days: "剩余被征服天数:{days}" + conquered-days: "剩余被征服天数:{days}" overclaimed: "领地超额" overclaimed-description: "放弃部分土地或扩大城镇,以免继续支付超额罚金。" overclaimed-stealable: "领地超额期间,其他城镇可以夺取你的土地。" @@ -522,13 +605,15 @@ town-status: town-trust: resident: "受信任的居民" town: "受信任的城镇" - trust-online-description: "受信任的居民可以在城镇任意位置建造。" + trust-online-description: "受信任的居民可以在城镇任意位置建造。" trust-town: "信任城镇" trust-town-title: "信任城镇" - trust-town-description: "受信任城镇的所有居民都可以在你的城镇建造。" + trust-town-description: "受信任城镇的所有居民都可以在你的城镇建造。" sort: current: "排序: {sort}" + selected: "▶ {sort}" + option: " {sort}" residents: "居民数" claims: "领地数" towns: "城镇数" @@ -541,23 +626,23 @@ sort: nation: title: "我的国家" not-in-nation: "你的城镇不在任何国家中" - daily-tax: "每日城镇税: {tax}" + daily-tax: "每日城镇税: {tax}" towns: "城镇" - towns-count: "城镇: {count}" + towns-count: "城镇: {count}" towns-description: "查看成员城镇、邀请城镇和移除城镇。" - residents-description: "查看所有居民并管理国家职位。" + residents-description: "查看所有居民并管理国家职位。" bank: "国家银行" relations: "盟友与敌人" - relations-description: "管理同盟关系和宣布敌国。" + relations-description: "管理同盟关系和宣布敌国。" settings: "国家设置" settings-title: "国家设置" - settings-description: "和平、开放、公开和百分比税。" + settings-description: "和平、开放、公开和百分比税。" details: "国家详情" - details-description: "名称、公告、标签、税款、首都、国王和出生点。" + details-description: "名称、公告、标签、税款、首都、国王和出生点。" spawn: "国家出生点" - spawn-description: "传送到你的国家出生点。" + spawn-description: "传送到你的国家出生点。" delete: "删除国家" - delete-description: "永久解散你的国家。执行前会要求确认。" + delete-description: "永久解散你的国家。执行前会要求确认。" leave: "离开国家" leave-description: "让你的城镇退出国家。执行前会要求确认。" propose-alliance: "提议结盟" @@ -565,13 +650,13 @@ nation: announce: "向国家公告" announce-title: "国家公告" announce-description: "向国家所有在线居民发送消息。" - click-status: "点击查看等级、加成与维护费" + click-status: "点击查看等级、加成与维护费!" no-nation: title: "寻找国家" found: "建立国家" found-title: "建立国家" - found-description: "以你的城镇为首都建立一个国家。" + found-description: "以你的城镇为首都建立一个国家。" nation-name: "国家名称" browse: "浏览国家" browse-description: "为你的城镇寻找一个可以加入的开放国家。" @@ -581,15 +666,15 @@ nation-info: gone: "该国家已不存在" manage: "管理你的国家" manage-description: "打开你国家的管理菜单。" - visit-description: "传送到该国家的出生点。" + visit-description: "传送到该国家的出生点。" join: "加入国家" join-description: "该国家对所有城镇开放。" end-alliance: "解除同盟" - end-alliance-description: "将该国家从你的盟友中移除。" - propose-alliance-description: "向该国家发送结盟请求。" + end-alliance-description: "将该国家从你的盟友中移除。" + propose-alliance-description: "向该国家发送结盟请求。" make-peace: "议和" - make-peace-description: "将该国家从你的敌国中移除。" - declare-enemy-description: "将该国家标记为敌国。" + make-peace-description: "将该国家从你的敌国中移除。" + declare-enemy-description: "将该国家标记为敌国。" nation-list: title: "国家列表" @@ -598,48 +683,51 @@ nation-relations: title: "盟友与敌人: {nation}" ally: "盟友" enemy: "敌国" - right-remove: "右键移除" + right-remove: "右键移除!" propose-alliance-title: "提议结盟" - propose-alliance-description: "向其他国家发送结盟请求。" + propose-alliance-description: "向其他国家发送结盟请求。" declare-enemy-title: "宣布为敌国" - declare-enemy-description: "将其他国家标记为敌国。" + declare-enemy-description: "将其他国家标记为敌国。" sent-requests: "已发送的结盟请求" nation-towns: title: "城镇: {nation}" capital: "首都" - right-remove: "右键将其移出国家" + right-remove: "右键移出国家!" invite: "邀请城镇" invite-title: "邀请城镇" invite-description: "邀请一个未加入国家的城镇。" sanctions: "受制裁城镇" - sanctions-description: "禁止使用你们国家传送点的城镇。" - sanctions-count: "受制裁:{count}" + sanctions-description: "禁止使用你们国家传送点的城镇。" + sanctions-count: "受制裁:{count}" nation-sanctions: title: "制裁:{nation}" - right-lift: "右键解除制裁" + right-lift: "右键解除制裁!" add: "制裁城镇" add-title: "制裁城镇" - add-description: "禁止国家外的某个城镇使用你们的国家传送点。" + add-description: "禁止国家外的某个城镇使用你们的国家传送点。" leaderboard: title: "排行榜" info: "排行榜" info-description: "与 Towny 排行榜相同的排名。点击任意条目可查看详情。" - rank: "第 {rank} 名" + rank: "#{rank}" + rank-first: "#1" + rank-second: "<#c0c0c0>#2" + rank-third: "<#cd7f32>#3" town-residents: "城镇居民数排行" town-residents-description: "居民最多的城镇。" nation-residents: "国家居民数排行" nation-residents-description: "居民最多的国家。" town-land: "城镇领地排行" - town-land-description: "占领土地最多的城镇。" + town-land-description: "占领土地最多的城镇。" resident-land: "玩家地块排行" - resident-land-description: "拥有地块最多的玩家。" + resident-land-description: "拥有地块最多的玩家。" town-balance: "城镇银行排行" - town-balance-description: "最富有的城镇银行。" + town-balance-description: "最富有的城镇银行。" nation-balance: "国家银行排行" - nation-balance-description: "最富有的国家银行。" + nation-balance-description: "最富有的国家银行。" town-baltop: "城镇最富居民" town-baltop-description: "{town} 中最富有的居民。" nation-baltop: "国家最富居民" @@ -648,38 +736,38 @@ leaderboard: prices: title: "价格与新的一天" new-day: "Towny 日" - new-day-description: "税款和维护费每天结算一次。" + new-day-description: "税款和维护费每天结算一次。" no-economy: "本服务器未启用经济系统,因此一切都不需要花钱。" founding: "建立" - new-town: "建立城镇:{cost}" - new-nation: "建立国家:{cost}" - reclaim: "收复废墟:{cost}" - merge: "合并城镇:{cost}" + new-town: "建立城镇:{cost}" + new-nation: "建立国家:{cost}" + reclaim: "收复废墟:{cost}" + merge: "合并城镇:{cost}" claims: "土地" - claim: "每块领地:{cost}" - claim-refund: "放弃每块领地退还:{cost}" - bonus-claim: "每块额外领地:{cost}" - outpost: "每个前哨:{cost}" - outpost-upkeep: "每个前哨每日维护费:{cost}" + claim: "每块领地:{cost}" + claim-refund: "放弃每块领地退还:{cost}" + bonus-claim: "每块额外领地:{cost}" + outpost: "每个前哨:{cost}" + outpost-upkeep: "每个前哨每日维护费:{cost}" upkeep: "每日维护费" - upkeep-description: "每个新的一天从城镇和国家银行中扣除。" - town-upkeep: "城镇维护费:{cost}" - nation-upkeep: "国家维护费:{cost}" - overclaimed-upkeep: "领地超额罚金:{cost}" - town-peaceful: "和平城镇:{cost}" - nation-peaceful: "和平国家:{cost}" + upkeep-description: "每个新的一天从城镇和国家银行中扣除。" + town-upkeep: "城镇维护费:{cost}" + nation-upkeep: "国家维护费:{cost}" + overclaimed-upkeep: "领地超额罚金:{cost}" + town-peaceful: "和平城镇:{cost}" + nation-peaceful: "和平国家:{cost}" plot-prices: "地块价格:{town}" - plot: "普通地块:{cost}" - shop: "商店地块:{cost}" - embassy: "使馆地块:{cost}" + plot: "普通地块:{cost}" + shop: "商店地块:{cost}" + embassy: "使馆地块:{cost}" taxes: "税款:{town}" - resident-tax: "居民税:{cost}" - plot-tax: "地块税:{cost}" - shop-tax: "商店税:{cost}" - embassy-tax: "使馆税:{cost}" + resident-tax: "居民税:{cost}" + plot-tax: "地块税:{cost}" + shop-tax: "商店税:{cost}" + embassy-tax: "使馆税:{cost}" plot-types: "地块类型" - plot-types-description: "镇长把地块设为各类型所需的费用。" - plot-type: "{type}:{cost}" + plot-types-description: "镇长把地块设为各类型所需的费用。" + plot-type: "{type}:{cost}" nation-details: title: "国家详情" @@ -694,95 +782,99 @@ nation-details: map-color-description: "你的国家在网页地图上的颜色。" capital: "更换首都" capital-title: "选择首都" - capital-click: "点击设为首都" + capital-click: "点击设为首都!" leader: "更换国王" leader-title: "选择国王" - leader-description: "国王必须居住在首都。" - leader-click: "点击设为国王" - set-spawn-description: "将国家出生点移动到你所在的位置。" + leader-description: "国王必须居住在首都。" + leader-click: "点击设为国王!" + set-spawn-description: "将国家出生点移动到你所在的位置。" taxes: "每日城镇税" conquered-tax: "被征服城镇税" nation-status: title: "状态:{nation}" level: "国家等级" - level-description: "等级决定成员城镇获得的加成以及国家的维护费。" - next-level-towns: "达到 {needed} 个城镇可升级(当前 {current})" + level-description: "等级决定成员城镇获得的加成以及国家的维护费。" + next-level-towns: "达到 {needed} 个城镇可升级(当前 {current})" bonuses: "城镇加成" bonuses-description: "每个成员城镇从国家获得的加成。" - bonus-claims: "每个城镇的额外领地:{count}" - bonus-outposts: "每个城镇的额外前哨:{count}" - bonus-capital-outposts: "首都的额外前哨:{count}" - upkeep-description: "下一个新的一天国家银行需要支付的金额。" + bonus-claims: "每个城镇的额外领地:{count}" + bonus-outposts: "每个城镇的额外前哨:{count}" + bonus-capital-outposts: "首都的额外前哨:{count}" + upkeep-description: "下一个新的一天国家银行需要支付的金额。" upkeep-short: "国家银行余额不足以支付。" plot: title: "地块" unnamed: "地块" - refresh-description: "移动到其他区块后更新此菜单。" - wilderness-description: "这片土地无人占领。" + refresh-description: "移动到其他区块后更新此菜单。" + wilderness-description: "这片土地无人占领。" claim: "为 {town} 占领" - claim-description: "为你的城镇占领此区块。" + claim-description: "为你的城镇占领此区块。" claim-outpost: "占领为前哨" - claim-outpost-description: "将此区块占领为前哨。" + claim-outpost-description: "将此区块占领为前哨。" group: "地块组: {group}" district: "街区: {district}" - claimed: "占领于: {date}" + claimed: "占领于: {date}" buy: "购买地块" - buy-description: "成为此地块的所有者。" + buy-description: "成为此地块的所有者。" give-up: "放弃地块" - give-up-description: "将此地块归还给城镇。" + give-up-description: "将此地块归还给城镇。" not-for-sale: "取消出售" - not-for-sale-description: "停止出售此地块。" + not-for-sale-description: "停止出售此地块。" for-sale: "出售地块" for-sale-title: "出售地块" - for-sale-description: "让居民可以购买此地块。" + for-sale-description: "让居民可以购买此地块。" for-sale-hint: "输入 0 可免费赠送。" evict: "驱逐所有者" - evict-description: "移除 {owner} 对此地块的所有权。" + evict-description: "移除 {owner} 对此地块的所有权。" type: "地块类型" type-title: "地块类型" - type-description: "商店、大使馆、竞技场、农场、监狱等。" + type-description: "商店、大使馆、竞技场、农场、监狱等。" rename: "重命名地块" rename-title: "重命名地块" - rename-description: "玩家走进地块时会显示此名称。右键移除名称。" + rename-description: "玩家走进地块时显示的名称。" plot-name: "地块名称" settings: "地块设置" settings-title: "地块设置" - settings-description: "此地块的 PvP、火焰、爆炸、怪物和税款。" + settings-description: "此地块的 PvP、火焰、爆炸、怪物和税款。" permissions-title: "地块权限" - permissions-description: "谁可以在此地块上建造、破坏和交互。" + permissions-description: "谁可以在此地块上建造、破坏和交互。" trusted: "受信任玩家" - trusted-description: "受信任的玩家可以在此地块上建造。" - trusted-count: "受信任: {count}" + trusted-description: "受信任的玩家可以在此地块上建造。" + trusted-count: "受信任: {count}" groups: "地块组与街区" - groups-description: "将地块打包成一起出售的地块组,或划分为街区。" + groups-description: "将地块打包成一起出售的地块组,或划分为街区。" clear: "清理地块" - clear-description: "移除此地块上被服务器标记为可清理的方块。" - town-description: "查看拥有这片土地的城镇。" + clear-description: "移除此地块上被服务器标记为可清理的方块。" + town-description: "查看拥有这片土地的城镇。" group-applies: "作用于 {group} 中的全部 {count} 个地块" - evict-resell: "右键驱逐并重新出售此地块" + evict-resell: "右键驱逐并重新出售!" join-days: "入镇天数限制" - join-days-description: "左键设置购买者至少需在城镇居住的天数,右键设置最多允许的天数。" + join-days-description: "购买者至少和至多需要在城镇居住的天数。" + left-min-days: "左键设置最少天数!" + right-max-days: "右键设置最多天数!" join-days-none: "无限制" join-days-hint: "输入 0 取消限制。" - min-join-days: "最少入镇天数:{days}" - max-join-days: "最多入镇天数:{days}" + min-join-days: "最少入镇天数:{days}" + max-join-days: "最多入镇天数:{days}" min-join-days-title: "最少入镇天数" max-join-days-title: "最多入镇天数" days: "天数" jail-cells: "牢房" - jail-cells-description: "左键在你所站位置添加牢房,右键移除你所站位置的牢房。" - jail-cells-count: "牢房:{count}" + jail-cells-description: "此监狱地块中关押囚犯的牢房。" + left-add-cell: "左键在所站位置添加牢房!" + right-remove-cell: "右键移除所站位置的牢房!" + jail-cells-count: "牢房:{count}" hud: "地块信息面板" - hud-description: "显示或隐藏侧边栏,展示你所在地块的主人、类型、价格和权限。" + hud-description: "显示或隐藏侧边栏,展示你所在地块的主人、类型、价格和权限。" area: "批量地块操作" - area-description: "购买、出售或放弃你周围一片区域内的所有地块。" - click-info: "点击在聊天栏显示 Towny 的地块信息" + area-description: "购买、出售或放弃你周围一片区域内的所有地块。" + click-info: "点击在聊天中显示 Towny 地块信息!" make-outpost: "设为前哨" - make-outpost-description: "把此领地设为前哨,并以你所站位置作为前哨出生点。" + make-outpost-description: "把此领地设为前哨,并以你所站位置作为前哨出生点。" outpost-spawn: "移动前哨出生点" - outpost-spawn-description: "把此前哨的出生点移到你所站的位置。" + outpost-spawn-description: "把此前哨的出生点移到你所站的位置。" # Towny 内置的地块类型。Towny 配置中的自定义类型会显示其原名,除非在此添加。 plot-type: @@ -801,22 +893,22 @@ plot-group: not-in-town: "你没有站在城镇中" add: "加入地块组" add-title: "加入地块组" - add-description: "将此地块加入一个地块组,如不存在则自动创建。" + add-description: "将此地块加入一个地块组,如不存在则自动创建。" group-name: "地块组名称" remove: "移出地块组" - remove-description: "将此地块移出 {group}。" + remove-description: "将此地块移出 {group}。" rename: "重命名地块组" rename-title: "重命名地块组" sell: "出售地块组" sell-title: "出售地块组" - sell-description: "将组内所有地块一起出售。" + sell-description: "将组内所有地块一起出售。" not-for-sale: "未出售" stop-selling: "停止出售地块组" delete: "删除地块组" - delete-description: "解散 {group} 中的所有地块。" + delete-description: "解散 {group} 中的所有地块。" district-add: "加入街区" district-add-title: "加入街区" - district-add-description: "将此地块加入一个街区,如不存在则自动创建。" + district-add-description: "将此地块加入一个街区,如不存在则自动创建。" district-name: "街区名称" district-remove: "移出街区" district-rename: "重命名街区" @@ -826,36 +918,36 @@ plot-group: plot-trust: title: "地块信任" trust-title: "信任玩家" - trust-online-description: "允许一名在线玩家在此地块上建造。" + trust-online-description: "允许一名在线玩家在此地块上建造。" group: "地块组:{group}" - group-description: "此地块的信任作用于其所在组的全部 {count} 个地块。" + group-description: "此地块的信任作用于其所在组的全部 {count} 个地块。" plot-area: title: "批量地块操作" info: "你周围的区域" - info-description: "选择形状和半径,然后对该区域内的所有地块执行操作。半径 1 覆盖你周围 3×3 个区块。" + info-description: "选择形状和半径,然后对该区域内的所有地块执行操作。半径 1 覆盖你周围 3×3 个区块。" shape: "形状" square: "方形" circle: "圆形" radius: "半径" radius-title: "区域半径" - radius-description: "区域从你所在位置向外延伸的区块数。" + radius-description: "区域从你所在位置向外延伸的区块数。" buy: "购买地块" - buy-description: "购买区域内所有你可以购买的出售中地块。" + buy-description: "购买区域内所有你可以购买的出售中地块。" sell: "出售地块" sell-title: "出售区域内地块" - sell-description: "以同一价格出售区域内所有你可以出售的地块。" + sell-description: "以同一价格出售区域内所有你可以出售的地块。" not-for-sale: "停止出售地块" - not-for-sale-description: "停止出售区域内所有你可以管理的地块。" + not-for-sale-description: "停止出售区域内所有你可以管理的地块。" give-up: "放弃地块" - give-up-description: "把你在区域内拥有的地块归还城镇。" + give-up-description: "把你在区域内拥有的地块归还城镇。" give-up-all: "放弃我的所有地块" - give-up-all-description: "把你在任何地方拥有的所有地块归还给所属城镇。" + give-up-all-description: "把你在任何地方拥有的所有地块归还给所属城镇。" plot-overrides: title: "玩家单独权限" changed-by: "最后修改者:{player}" - click-remove: "点击移除单独权限" + click-remove: "点击移除单独权限!" add-online: "添加在线玩家" add-name: "按名称添加" add-description: "为玩家单独设置此处的权限,然后在 Towny 的编辑器中修改。" @@ -865,47 +957,49 @@ plot-overrides: profile: title: "个人资料" - registered: "注册于: {date}" - friends-count: "好友: {count}" - plots-owned: "拥有地块: {count}" - tax-owed: "今日应缴税款: {tax}" + registered: "注册于: {date}" + friends-count: "好友: {count}" + plots-owned: "拥有地块: {count}" + tax-owed: "今日应缴税款: {tax}" about-line: "简介: {about}" jailed: "被关押在 {town}(剩余 {hours} 小时)" jailed-unknown: "某个城镇" friends: "好友" - friends-description: "在你的个人地块权限中,好友视为居民。" + friends-description: "在你的个人地块权限中,好友视为居民。" settings: "个人设置" settings-title: "个人设置" - settings-description: "你地块上的 PvP、火焰和怪物,以及地图和边界显示模式。" + settings-description: "你地块上的 PvP、火焰和怪物,以及地图和边界显示模式。" permissions: "地块权限" permissions-title: "我的地块权限" - permissions-description: "谁可以在你个人拥有的地块上建造、破坏和交互。" + permissions-description: "谁可以在你个人拥有的地块上建造、破坏和交互。" about: "关于我" about-title: "关于我" - about-description: "左键编写简短的个人简介,右键清除。" + about-description: "其他玩家在你的资料中看到的简短介绍。" bio: "简介" spawn: "前往出生点" - spawn-description: "传送到你的床或城镇出生点。" + spawn-description: "传送到你的床或城镇出生点。" bail: "支付保释金" bail-description: "支付 {cost} 出狱。" modes: "显示模式" - modes-description: "左键关闭所有模式,例如自动地图、边界和自动圈地。右键恢复服务器默认模式。" + modes-description: "自动地图、边界显示、自动占领等自动模式。" + left-modes-off: "左键关闭所有模式!" + right-modes-reset: "右键恢复服务器默认模式!" modes-active: "已开启:{modes}" plots: "我的地块" - plots-description: "你拥有的所有地块、位置以及每日花费。" + plots-description: "你拥有的所有地块、位置以及每日花费。" tax: "每日税款" - tax-description: "下一个新的一天你需要向城镇及为地块支付的金额。" + tax-description: "下一个新的一天你需要向城镇及为地块支付的金额。" tax-exempt: "你免缴税款。" - tax-town: "城镇税:{tax}" - tax-plots: "地块税:{tax}" - tax-total: "合计:{tax}" + tax-town: "城镇税:{tax}" + tax-plots: "地块税:{tax}" + tax-total: "合计:{tax}" outlawed-in: "被通缉的城镇" - outlawed-in-description: "已将你列为通缉犯的城镇。" + outlawed-in-description: "已将你列为通缉犯的城镇。" outlawed-in-title: "被通缉的城镇" trusted-in: "受信任的城镇" - trusted-in-description: "信任你、允许你在其中任意建造的城镇。" + trusted-in-description: "信任你、允许你在其中任意建造的城镇。" trusted-in-title: "受信任的城镇" - towns-count: "城镇数:{count}" + towns-count: "城镇数:{count}" resident-plots: title: "我的地块" @@ -913,8 +1007,8 @@ resident-plots: friends: title: "好友" - left-view: "左键查看" - right-remove: "右键移除" + left-view: "左键查看!" + right-remove: "右键移除!" add-online: "添加在线玩家" add-online-description: "选择一名当前在线的玩家。" add-name: "按名称添加" @@ -925,29 +1019,29 @@ resident-profile: add-friend: "添加好友" remove-friend: "移除好友" town-ranks: "城镇职位" - town-ranks-description: "授予助理、警长等职位。" + town-ranks-description: "授予助理、警长等职位。" title: "设置头衔" title-prompt: "设置头衔" title-label: "头衔" - title-description: "左键设置显示在其名字前的头衔,右键清除。" + title-description: "显示在其名字前的头衔。" surname: "设置称号" surname-prompt: "设置称号" surname-label: "称号" - surname-description: "左键设置显示在其名字后的称号,右键清除。" + surname-description: "显示在其名字后的称号。" make-mayor: "任命为镇长" make-mayor-description: "移交你城镇的领导权。" kick: "踢出城镇" kick-description: "将该居民移出你的城镇。" trust: "在城镇中信任" untrust: "取消信任" - trust-description: "受信任的居民可以在你城镇的任意位置建造。" + trust-description: "受信任的居民可以在你城镇的任意位置建造。" outlaw: "宣布通缉" pardon: "赦免通缉犯" - outlaw-description: "通缉犯可被禁止进入你的城镇或被传送出去。" + outlaw-description: "通缉犯可被禁止进入你的城镇或被传送出去。" invite: "邀请加入城镇" invite-description: "发送加入你城镇的邀请。" nation-ranks: "国家职位" - nation-ranks-description: "授予助理等国家职位。" + nation-ranks-description: "授予助理等国家职位。" make-leader: "任命为国王" make-leader-description: "移交你国家的领导权。" @@ -960,55 +1054,55 @@ toggle: public: "公开" peaceful: "和平" tax-percent: "百分比税" - tax-percent-description: "按余额的百分比收税,而非固定金额。" + tax-percent-description: "按余额的百分比收税,而非固定金额。" taxed: "收税" - taxed-description: "向地块所有者收取城镇的每日地块税。" + taxed-description: "向地块所有者收取城镇的每日地块税。" town-pvp-description: "允许玩家在城镇内战斗。" - town-mobs-description: "允许敌对生物在城镇内生成。" - town-fire-description: "允许火焰在城镇内蔓延。" - town-explosions-description: "允许爆炸破坏城镇。" + town-mobs-description: "允许敌对生物在城镇内生成。" + town-fire-description: "允许火焰在城镇内蔓延。" + town-explosions-description: "允许爆炸破坏城镇。" town-open-description: "任何人无需邀请即可加入。" - town-public-description: "允许外人传送到你的出生点并查看你的主区块。" - town-peaceful-description: "远离战争与 PvP。" - nation-peaceful-description: "远离战争;成员城镇中禁用 PvP。" + town-public-description: "允许外人传送到你的出生点并查看你的主区块。" + town-peaceful-description: "远离战争与 PvP。" + nation-peaceful-description: "远离战争;成员城镇中禁用 PvP。" nation-open-description: "任何城镇无需邀请即可加入。" - nation-public-description: "允许外人传送到你的国家出生点。" - nation-tax-percent-description: "按城镇余额的百分比收税,而非固定金额。" - plot-pvp-description: "允许玩家在此地块上战斗。" - plot-fire-description: "允许火焰在此地块上蔓延。" - plot-explosions-description: "允许在此地块上发生爆炸。" - plot-mobs-description: "允许敌对生物在此地块上生成。" - resident-pvp-description: "允许在你拥有的地块上 PvP。" - resident-fire-description: "允许火焰在你拥有的地块上蔓延。" - resident-explosions-description: "允许在你拥有的地块上发生爆炸。" - resident-mobs-description: "允许敌对生物在你拥有的地块上生成。" + nation-public-description: "允许外人传送到你的国家出生点。" + nation-tax-percent-description: "按城镇余额的百分比收税,而非固定金额。" + plot-pvp-description: "允许玩家在此地块上战斗。" + plot-fire-description: "允许火焰在此地块上蔓延。" + plot-explosions-description: "允许在此地块上发生爆炸。" + plot-mobs-description: "允许敌对生物在此地块上生成。" + resident-pvp-description: "允许在你拥有的地块上 PvP。" + resident-fire-description: "允许火焰在你拥有的地块上蔓延。" + resident-explosions-description: "允许在你拥有的地块上发生爆炸。" + resident-mobs-description: "允许敌对生物在你拥有的地块上生成。" border-titles: "边界标题" - border-titles-description: "进入城镇或荒野时显示标题。" + border-titles-description: "进入城镇或荒野时显示标题。" auto-map: "自动地图" - auto-map-description: "每次进入新区块时在聊天中显示 Towny 地图。" - auto-claim-description: "为你的城镇自动占领你走进的每个区块。" + auto-map-description: "每次进入新区块时在聊天中显示 Towny 地图。" + auto-claim-description: "为你的城镇自动占领你走进的每个区块。" auto-unclaim: "自动放弃" - auto-unclaim-description: "自动放弃你走进的每个区块。" + auto-unclaim-description: "自动放弃你走进的每个区块。" plot-borders: "地块边界" - plot-borders-description: "进入地块时显示粒子边界。" + plot-borders-description: "进入地块时显示粒子边界。" constant-plot-borders: "常驻地块边界" - constant-plot-borders-description: "始终显示你所在地块的粒子边界。" + constant-plot-borders-description: "始终显示你所在地块的粒子边界。" town-borders: "城镇边界" town-borders-description: "显示你所在城镇的粒子边界。" info-tool: "信息工具" info-tool-description: "用木棍右键方块查看其 Towny 信息。" ignore-plots: "忽略地块标题" - ignore-plots-description: "行走时隐藏地块名称和所有者消息。" + ignore-plots-description: "行走时隐藏地块名称和所有者消息。" ignore-invites: "忽略邀请" ignore-invites-description: "不再接收城镇邀请。" bed-spawn: "床出生点" - bed-spawn-description: "将你的床作为 Towny 出生点。" + bed-spawn-description: "将你的床作为 Towny 出生点。" plot-group: "地块组模式" - plot-group-description: "将你走进的每个地块加入所选的地块组。" + plot-group-description: "将你走进的每个地块加入所选的地块组。" district: "街区模式" - district-description: "将你走进的每个地块加入所选的街区。" + district-description: "将你走进的每个地块加入所选的街区。" nation-zone: "国家区域" - nation-zone-description: "将城镇周围的土地作为国家区域加以保护。" + nation-zone-description: "将城镇周围的土地作为国家区域加以保护。" spy: "聊天监听" spy-description: "查看所有城镇和国家聊天频道的消息。" admin-bypass: "停用管理员权限" @@ -1019,14 +1113,14 @@ admin: config: "Towny 配置" config-description: "浏览并修改 Towny config.yml 中的所有设置。修改会立即保存并生效。" worlds: "世界" - worlds-description: "每个世界的 Towny 设置:PvP、爆炸、火焰、生物、领地声明和荒野规则。" - worlds-count: "世界数: {count}" + worlds-description: "每个世界的 Towny 设置:PvP、爆炸、火焰、生物、领地声明和荒野规则。" + worlds-count: "世界数: {count}" server: "服务器操作" server-description: "开始新的一天、备份或保存数据、重载 Towny,以及切换全局开关。" plugin: "TownyMenu 设置" plugin-description: "菜单语言、消息前缀和菜单快捷键。" towns: "管理城镇" - towns-description: "打开任意城镇,无需身为镇长即可编辑、重命名或删除它。" + towns-description: "打开任意城镇,无需身为镇长即可编辑、重命名或删除它。" towns-title: "管理城镇" nations: "管理国家" nations-description: "打开任意国家,编辑、重命名或删除它。" @@ -1034,24 +1128,24 @@ admin: residents: "管理居民" residents-description: "查找任意居民,修改其城镇、称号或记录。" residents-title: "管理居民" - count: "总数: {count}" + count: "总数: {count}" gone: "该对象已不存在" rename: "重命名" - deposit-description: "向银行存入资金,不会从你的余额中扣除。仅限整数。" - withdraw-description: "从银行移除资金,不会转给你。仅限整数。" + deposit-description: "向银行存入资金,不会从你的余额中扣除。仅限整数。" + withdraw-description: "从银行移除资金,不会转给你。仅限整数。" search: "搜索" - search-description: "左键按名称筛选,右键清除筛选。" + search-description: "按玩家名称筛选列表。" filter: "筛选: {filter}" admin-config: title: "Towny 配置" section-title: "Towny 配置: {section}" - settings-count: "设置项: {count}" + settings-count: "设置项: {count}" path: "{path}" default: "默认值: {value}" empty: "(空)" read-only: "请在 config.yml 中修改此设置。" - right-reset: "右键恢复默认值" + right-reset: "右键恢复默认值!" value-label: "值" number-label: "数字" invalid-value: "“{value}”不是此设置的有效值。" @@ -1067,62 +1161,62 @@ admin-world: list-title: "Towny 世界" title: "世界: {world}" using-towny: "启用 Towny: {value}" - towns: "城镇数: {count}" + towns: "城镇数: {count}" wild-name: "荒野名称: {name}" toggles: "世界设置" - toggles-description: "此世界的 PvP、爆炸、火焰、生物、战争、监禁和地形修复。" + toggles-description: "此世界的 PvP、爆炸、火焰、生物、战争、监禁和地形修复。" toggles-title: "世界设置: {world}" rename-wild: "荒野名称" - rename-wild-description: "玩家进入未声明土地时显示的名称。" + rename-wild-description: "玩家进入未声明土地时显示的名称。" reset: "恢复默认" reset-description: "用 Towny 配置中的新世界默认值替换此世界的设置。" wild-build: "荒野建造" wild-destroy: "荒野破坏" wild-switch: "荒野开关" wild-item-use: "荒野物品使用" - wild-perm-description: "玩家能否在未声明的土地上进行此操作。" + wild-perm-description: "玩家能否在未声明的土地上进行此操作。" toggle-using-towny: "启用 Towny" toggle-using-towny-description: "在此世界开启或关闭 Towny。关闭时无法修改其他世界设置。" toggle-claimable: "可声明" - toggle-claimable-description: "允许城镇在此世界声明领地。" - toggle-pvp-description: "在城镇和地块允许的地方启用此世界的 PvP。" + toggle-claimable-description: "允许城镇在此世界声明领地。" + toggle-pvp-description: "在城镇和地块允许的地方启用此世界的 PvP。" toggle-force-pvp: "强制 PvP" - toggle-force-pvp-description: "在此世界各处强制开启 PvP,无视城镇设置。" + toggle-force-pvp-description: "在此世界各处强制开启 PvP,无视城镇设置。" toggle-friendly-fire: "友军伤害" toggle-friendly-fire-description: "允许同一城镇或国家的成员互相伤害。" - toggle-explosions-description: "在城镇和地块允许的地方启用此世界的爆炸。" + toggle-explosions-description: "在城镇和地块允许的地方启用此世界的爆炸。" toggle-force-explosions: "强制爆炸" - toggle-force-explosions-description: "在此世界各处强制开启爆炸,无视城镇设置。" - toggle-fire-description: "在城镇和地块允许的地方启用此世界的火焰蔓延。" + toggle-force-explosions-description: "在此世界各处强制开启爆炸,无视城镇设置。" + toggle-fire-description: "在城镇和地块允许的地方启用此世界的火焰蔓延。" toggle-force-fire: "强制火焰" - toggle-force-fire-description: "在此世界各处强制开启火焰蔓延,无视城镇设置。" + toggle-force-fire-description: "在此世界各处强制开启火焰蔓延,无视城镇设置。" toggle-town-mobs: "强制城镇生物" - toggle-town-mobs-description: "强制所有城镇生成敌对生物,无视城镇设置。" + toggle-town-mobs-description: "强制所有城镇生成敌对生物,无视城镇设置。" toggle-world-mobs: "世界生物" - toggle-world-mobs-description: "允许敌对生物在此世界生成。" + toggle-world-mobs-description: "允许敌对生物在此世界生成。" toggle-wilderness-mobs: "荒野生物" - toggle-wilderness-mobs-description: "允许敌对生物在未声明的土地上生成。" + toggle-wilderness-mobs-description: "允许敌对生物在未声明的土地上生成。" toggle-war: "允许战争" - toggle-war-description: "允许在此世界发生战争。" + toggle-war-description: "允许在此世界发生战争。" toggle-jailing: "监禁" toggle-jailing-description: "允许在此世界监禁玩家。" toggle-revert-unclaim: "放弃领地时修复" - toggle-revert-unclaim-description: "将放弃的领地逐渐恢复为声明前的样子。" + toggle-revert-unclaim-description: "将放弃的领地逐渐恢复为声明前的样子。" toggle-revert-entity-explosions: "修复生物爆炸" - toggle-revert-entity-explosions-description: "修复被苦力怕等生物炸毁的荒野方块。" + toggle-revert-entity-explosions-description: "修复被苦力怕等生物炸毁的荒野方块。" toggle-revert-block-explosions: "修复方块爆炸" - toggle-revert-block-explosions-description: "修复被床、重生锚等方块炸毁的荒野方块。" + toggle-revert-block-explosions-description: "修复被床、重生锚等方块炸毁的荒野方块。" toggle-plot-clear-delete: "地块清理" - toggle-plot-clear-delete-description: "允许镇长用 /plot clear 移除 Towny 配置中列出的方块。" + toggle-plot-clear-delete-description: "允许镇长用 /plot clear 移除 Towny 配置中列出的方块。" toggle-unclaim-block-delete: "放弃领地时删除方块" - toggle-unclaim-block-delete-description: "放弃领地时移除 Towny 配置中列出的方块。" + toggle-unclaim-block-delete-description: "放弃领地时移除 Towny 配置中列出的方块。" toggle-unclaim-entity-delete: "放弃领地时删除实体" - toggle-unclaim-entity-delete-description: "放弃领地时移除 Towny 配置中列出的实体。" + toggle-unclaim-entity-delete-description: "放弃领地时移除 Towny 配置中列出的实体。" admin-server: title: "服务器操作" new-day: "新的一天" - new-day-description: "立即执行 Towny 的新一天:收取税款和维护费,并移除破产和废墟城镇。" + new-day-description: "立即执行 Towny 的新一天:收取税款和维护费,并移除破产和废墟城镇。" new-day-confirm: "现在开始新的 Towny 一天吗?" new-hour: "新的一小时" new-hour-description: "立即执行 Towny 的每小时任务。" @@ -1131,7 +1225,7 @@ admin-server: save-database: "保存数据库" save-database-description: "立即将所有城镇、国家和居民保存到数据库。" check-outposts: "检查前哨" - check-outposts-description: "移除已不在所属城镇领地内的前哨传送点。" + check-outposts-description: "移除已不在所属城镇领地内的前哨传送点。" reload-config: "重载配置" reload-config-description: "重新加载 Towny 的 config.yml。" reload-lang: "重载语言" @@ -1143,19 +1237,19 @@ admin-server: reload-all: "全部重载" reload-all-description: "重新加载权限、数据库、配置和语言文件。" town-withdraw: "城镇银行取款" - town-withdraw-description: "允许城镇从银行取款。" + town-withdraw-description: "允许城镇从银行取款。" nation-withdraw: "国家银行取款" - nation-withdraw-description: "允许国家从银行取款。" + nation-withdraw-description: "允许国家从银行取款。" debug: "调试模式" debug-description: "将 Towny 的调试信息写入日志。" dev-mode: "开发者模式" dev-mode-description: "Towny 的开发者模式。正式服务器上请保持关闭。" wilderness-use: "荒野使用" - wilderness-use-description: "允许或禁止在所有世界的荒野中建造、破坏、使用开关和物品。" + wilderness-use-description: "允许或禁止在所有世界的荒野中建造、破坏、使用开关和物品。" regenerations: "地形修复" - regenerations-description: "在所有世界开启或关闭放弃领地修复和荒野爆炸修复。" - left-on: "左键在所有世界开启" - right-off: "右键在所有世界关闭" + regenerations-description: "在所有世界开启或关闭放弃领地修复和荒野爆炸修复。" + left-on: "左键在所有世界开启!" + right-off: "右键在所有世界关闭!" purge: "清理不活跃居民" purge-description: "删除超过指定天数未登录的居民。Towny 会要求你确认。" purge-label: "离线天数" @@ -1163,13 +1257,13 @@ admin-server: check-perm: "检查权限" check-perm-description: "查看某位在线玩家是否拥有某个权限节点。" deposit-all: "为所有银行存款" - deposit-all-description: "向每个城镇和国家的银行存入相同金额。" + deposit-all-description: "向每个城镇和国家的银行存入相同金额。" deposit-all-hint: "该金额会存入服务器上每个城镇和国家的银行。" admin-tools: add: "按名称添加" add-description: "将玩家或城镇加入此列表。" - click-remove: "点击移除" + click-remove: "点击移除!" admin-plugin: title: "TownyMenu 设置" @@ -1181,27 +1275,27 @@ admin-plugin: prefix-description: "显示在 TownyMenu 聊天消息前的 MiniMessage 文本。" prefix-label: "前缀" shortcut: "潜行 + 副手切换快捷键" - shortcut-description: "潜行时按副手切换键(默认 F)打开主菜单。" + shortcut-description: "潜行时按副手切换键(默认 F)打开主菜单。" join-hint: "加入时提示教程" join-hint-description: "没有城镇的玩家加入时向其推荐教程,直到对方读完所有课程。" live-refresh: "菜单实时刷新" live-refresh-description: "当 Towny 改变菜单显示的内容时(例如居民加入或新的一天)刷新已打开的菜单。" alerts: "聊天提醒" - alerts-description: "在聊天中提醒邀请、破产和废墟,并附上可打开对应菜单的链接。" + alerts-description: "在聊天中提醒邀请、破产和废墟,并附上可打开对应菜单的链接。" bank-amounts: "银行预设金额" - bank-amounts-description: "存款和取款菜单提供的预设金额。玩家始终还能使用“全部”按钮和自定义金额。" + bank-amounts-description: "存款和取款菜单提供的预设金额。玩家始终还能使用“全部”按钮和自定义金额。" bank-amounts-label: "金额,用逗号分隔" admin-town: title: "管理: {town}" - bonus-blocks: "奖励领地: {count}" - bought-blocks: "已购领地: {count}" + bonus-blocks: "奖励领地: {count}" + bought-blocks: "已购领地: {count}" spawn: "传送到出生点" - spawn-description: "传送到该城镇的出生点。" - toggles-description: "城镇设置,以及仅限管理员的选项:强制 PvP 与生物、无限领地、维护费和战争。" + spawn-description: "传送到该城镇的出生点。" + toggles-description: "城镇设置,以及仅限管理员的选项:强制 PvP 与生物、无限领地、维护费和战争。" toggles-title: "城镇设置: {town}" mayor: "设置镇长" - mayor-description: "让该城镇的另一位居民成为镇长。" + mayor-description: "让该城镇的另一位居民成为镇长。" mayor-title: "选择新镇长" add: "添加居民" add-description: "无需邀请,直接将玩家加入该城镇。" @@ -1209,34 +1303,34 @@ admin-town: kick-description: "将居民移出该城镇。" kick-title: "踢出居民" give-bonus: "给予奖励领地" - give-bonus-description: "提高城镇的领地上限。输入负数可降低上限。" + give-bonus-description: "提高城镇的领地上限。输入负数可降低上限。" give-bought: "给予已购领地" - give-bought-description: "修改城镇已购买的领地数量。输入负数可收回。" + give-bought-description: "修改城镇已购买的领地数量。输入负数可收回。" leave-nation: "移出国家" leave-nation-description: "让该城镇离开其国家。" unruin: "恢复城镇" - unruin-description: "让这个废墟城镇恢复原状。" + unruin-description: "让这个废墟城镇恢复原状。" delete: "删除城镇" - delete-description: "删除该城镇并放弃其全部领地。" + delete-description: "删除该城镇并放弃其全部领地。" force-pvp: "强制开启 PvP" - force-pvp-description: "无论镇长如何设置,保持该城镇的 PvP 开启。" + force-pvp-description: "无论镇长如何设置,保持该城镇的 PvP 开启。" force-no-pvp: "强制关闭 PvP" - force-no-pvp-description: "无论镇长如何设置,保持该城镇的 PvP 关闭。" + force-no-pvp-description: "无论镇长如何设置,保持该城镇的 PvP 关闭。" force-mobs: "强制生物" - force-mobs-description: "无论镇长如何设置,保持该城镇的敌对生物生成开启。" + force-mobs-description: "无论镇长如何设置,保持该城镇的敌对生物生成开启。" unlimited-claims: "无限领地" - unlimited-claims-description: "允许该城镇无上限地声明领地。" + unlimited-claims-description: "允许该城镇无上限地声明领地。" upkeep: "维护费" - upkeep-description: "向该城镇收取每日维护费。" + upkeep-description: "向该城镇收取每日维护费。" war: "允许参战" - war-description: "允许该城镇参与战争。" + war-description: "允许该城镇参与战争。" top-lists: "显示在排行榜" top-lists-description: "在 /towny top 排行中显示该城镇。" admin-town-tools: title: "工具:{town}" open: "更多城镇工具" - open-description: "等级、合并、出售、通缉犯、信任与职位。" + open-description: "等级、合并、出售、通缉犯、信任与职位。" level: "城镇等级" level-description: "将城镇固定在某个等级,而不由其规模决定。" level-title: "设置城镇等级" @@ -1244,21 +1338,21 @@ admin-town-tools: level-hint: "输入 unset 可恢复由城镇规模决定。" merge: "合并其他城镇" merge-description: "你选择的城镇将并入 {town} 并消失。" - merge-force: "右键即使 Towny 拒绝也强制合并。" + merge-force: "右键强制合并,即使 Towny 会拒绝!" merge-title: "合并哪个城镇?" for-sale: "挂牌出售" - for-sale-description: "允许玩家购买此城镇并成为镇长。" + for-sale-description: "允许玩家购买此城镇并成为镇长。" for-sale-title: "出售城镇" not-for-sale: "取消出售" not-for-sale-description: "停止出售此城镇。" unconquer: "解除被征服状态" unconquer-description: "解除此城镇被征服的状态。" - check-outposts-description: "移除此城镇已不在其领地上的前哨出生点。" + check-outposts-description: "移除此城镇已不在其领地上的前哨出生点。" ranks: "居民职位" - ranks-description: "授予或收回城镇职位,忽略通常的授予限制。" + ranks-description: "授予或收回城镇职位,忽略通常的授予限制。" ranks-title: "修改谁的职位?" - outlaws-description: "此城镇宣布为通缉犯的玩家。" - trust-description: "受信任、可在此城镇任意建造的玩家。" + outlaws-description: "此城镇宣布为通缉犯的玩家。" + trust-description: "受信任、可在此城镇任意建造的玩家。" trusted-towns: "受信任城镇" trusted-towns-description: "其居民可在此城镇任意建造的城镇。" trust-town-title: "信任城镇" @@ -1266,21 +1360,21 @@ admin-town-tools: admin-nation: title: "管理: {nation}" toggles: "国家设置" - toggles-description: "和平、开放、公开和百分比税。" + toggles-description: "和平、开放、公开和百分比税。" toggles-title: "国家设置: {nation}" - leader-description: "让首都的一位居民成为国王。" + leader-description: "让首都的一位居民成为国王。" add: "添加城镇" add-description: "无需邀请,将没有国家的城镇加入该国家。" kick: "踢出城镇" kick-description: "将城镇移出该国家。" - towns: "城镇数: {count}" + towns: "城镇数: {count}" delete: "删除国家" delete-description: "删除该国家。其城镇会保留,但不再属于任何国家。" admin-nation-tools: title: "工具:{nation}" open: "更多国家工具" - open-description: "等级、合并、转入城镇、制裁与职位。" + open-description: "等级、合并、转入城镇、制裁与职位。" level: "国家等级" level-description: "将国家固定在某个等级,而不由其规模决定。" level-title: "设置国家等级" @@ -1291,53 +1385,55 @@ admin-nation-tools: transfer-description: "将某个城镇从原国家移出,并加入 {nation}。" transfer-title: "转入哪个城镇?" recheck: "重新检查城镇距离" - recheck-description: "移除距离首都过远的成员城镇。" - sanctions-description: "禁止使用该国家传送点的城镇。" + recheck-description: "移除距离首都过远的成员城镇。" + sanctions-description: "禁止使用该国家传送点的城镇。" ranks: "居民职位" - ranks-description: "授予或收回国家职位,忽略通常的授予限制。" + ranks-description: "授予或收回国家职位,忽略通常的授予限制。" admin-plot: title: "管理:地块" open: "你所站的地块" - open-description: "为玩家占领、转给其他城镇、添加信任玩家,或放弃该地块。" - wilderness-description: "此区块尚未被占领。" + open-description: "为玩家占领、转给其他城镇、添加信任玩家,或放弃该地块。" + wilderness-description: "此区块尚未被占领。" claim: "为玩家占领" - claim-description: "让一名在线玩家成为此地块的主人。" + claim-description: "让一名在线玩家成为此地块的主人。" claim-title: "为谁占领?" - trust-description: "受信任、可在此地块建造的玩家。" + trust-description: "受信任、可在此地块建造的玩家。" move: "转给其他城镇" - move-description: "把此地块交给另一个城镇。" + move-description: "把此地块交给另一个城镇。" move-title: "交给哪个城镇?" unclaim: "放弃领地" - unclaim-description: "左键放弃此区块,右键放弃你周围的方形区域。" + unclaim-description: "将这片土地归还荒野。" + left-unclaim: "左键放弃此区块!" + right-unclaim-area: "右键放弃你周围的正方形区域!" unclaim-title: "放弃区域" admin-perms: title: "Towny 权限" open: "Towny 权限" - open-description: "编辑 townyperms.yml:所有居民拥有的权限,以及镇长可授予的职位。" + open-description: "编辑 townyperms.yml:所有居民拥有的权限,以及镇长可授予的职位。" info: "townyperms.yml" info-description: "更改会立即保存并生效,等同于 /townyadmin townyperms。" groups: "权限组" - groups-description: "没有职位的玩家所拥有的权限:流浪者、居民、镇长与国王。" - groups-count: "权限组:{count}" + groups-description: "没有职位的玩家所拥有的权限:流浪者、居民、镇长与国王。" + groups-count: "权限组:{count}" group-title: "权限组:{group}" town-ranks: "城镇职位" - town-ranks-description: "镇长可授予居民的职位,以及每个职位允许的操作。" + town-ranks-description: "镇长可授予居民的职位,以及每个职位允许的操作。" nation-ranks: "国家职位" - nation-ranks-description: "国王可授予居民的职位,以及每个职位允许的操作。" - ranks-count: "职位:{count}" - node-count: "权限数:{count}" + nation-ranks-description: "国王可授予居民的职位,以及每个职位允许的操作。" + ranks-count: "职位:{count}" + node-count: "权限数:{count}" node-label: "权限节点" - click-remove: "点击移除此权限" - right-remove: "右键删除此职位" + click-remove: "点击移除此权限!" + right-remove: "右键删除此职位!" add-node: "添加权限" add-node-description: "为此权限组添加一个权限节点。" add-rank: "添加职位" - add-rank-description: "创建一个职位,随后可为其添加权限。" + add-rank-description: "创建一个职位,随后可为其添加权限。" rank-label: "职位名称" rename-rank: "重命名职位" - rename-rank-description: "重命名职位,并保留已持有该职位的居民。" + rename-rank-description: "重命名职位,并保留已持有该职位的居民。" admin-resident: title: "管理: {name}" @@ -1349,9 +1445,9 @@ admin-resident: add-to-town-description: "无需邀请,将该居民加入某个城镇。" rename-description: "重命名该居民的 Towny 记录,例如在其更改 Minecraft 名称之后。" npc: "NPC" - npc-description: "将该居民标记为 NPC,例如占位的镇长。" + npc-description: "将该居民标记为 NPC,例如占位的镇长。" unjail: "释放出狱" - unjail-description: "将该居民从监狱中释放。" + unjail-description: "将该居民从监狱中释放。" delete: "删除居民" delete-description: "删除该居民的 Towny 数据。其下次加入时 Towny 会创建新记录。" @@ -1359,15 +1455,14 @@ tutorial: title: "教程" hub: "TownyMenu 教程" hub-description: "逐章了解 Towny 中值得掌握的一切。每节课都能直接带你打开它所讲解的菜单。" - progress: "已读: {read}/{total}" + progress: "已读: {read}/{total}" all-read: "你已读完所有课程!" continue: "继续阅读" continue-description: "打开第一个还有未读课程的章节。" chapter-line: "章节: {chapter}" chapter-title: "教程: {chapter}" chapter-complete: "✔ 本章已完成" - click-chapter: "点击打开" - click-open-menu: "点击打开此菜单" + click-open-menu: "点击打开此菜单!" previous-chapter: "上一章" next-chapter: "下一章" mark-all-read: "将本章标为已读" @@ -1379,11 +1474,11 @@ tutorial: lesson-unread: "{lesson}" status-read: "已读" status-unread: "尚未阅读" - left-open: "左键打开此菜单" - right-read: "右键标为已读" - right-unread: "右键标为未读" - click-read: "点击标为已读" - click-unread: "点击标为未读" + left-open: "左键打开此菜单!" + right-read: "右键标记为已读!" + right-unread: "右键标记为未读!" + click-read: "点击标记为已读!" + click-unread: "点击标记为未读!" requires-town: "加入城镇后才能打开此菜单。" requires-no-town: "只有不在城镇中的玩家才能打开此菜单。" requires-nation: "你的城镇需要加入国家才能打开此菜单。" @@ -1398,217 +1493,217 @@ tutorial: world-no-towny: "此世界未启用 Towny。" wild-build: "可在此世界的荒野建造: {value}" wild-destroy: "可在此世界的荒野破坏: {value}" - town-cost: "建立城镇费用: {cost}" - town-distance: "与其他城镇的最小距离: {distance} 个区块" - max-residents: "城镇居民上限: {count}" - claims-per-resident: "每位居民增加的领地: {count}" - visitor-spawn-cost: "访客传送到你城镇出生点的费用: {cost}" - peaceful-cost: "保持和平的每日费用: {cost}" + town-cost: "建立城镇费用: {cost}" + town-distance: "与其他城镇的最小距离: {distance} 个区块" + max-residents: "城镇居民上限: {count}" + claims-per-resident: "每位居民增加的领地: {count}" + visitor-spawn-cost: "访客传送到你城镇出生点的费用: {cost}" + peaceful-cost: "保持和平的每日费用: {cost}" ruins: "城镇废墟: {value}" - ruins-hours: "废墟最长保留: {hours} 小时" + ruins-hours: "废墟最长保留: {hours} 小时" ruins-reclaim: "废墟可被收复: {value}" - chunk-size: "每块领地为 {size}×{size} 格。" - claim-cost: "每块领地价格: {cost}" - claim-increase: "每占领一块,价格上涨 {percent}%。" - claim-refund: "每放弃一个区块退款: {cost}" + chunk-size: "每块领地为 {size}×{size} 格。" + claim-cost: "每块领地价格: {cost}" + claim-increase: "每占领一块,价格上涨 {percent}%。" + claim-refund: "每放弃一个区块退款: {cost}" outposts-disabled: "本服务器未启用前哨。" - outpost-cost: "每个前哨价格: {cost}" - bonus-cost: "每块额外领地价格: {cost}" - jail-hours: "最长刑期: {hours} 小时" + outpost-cost: "每个前哨价格: {cost}" + bonus-cost: "每块额外领地价格: {cost}" + jail-hours: "最长刑期: {hours} 小时" jailed: "你正在服刑,剩余 {hours} 小时。" - join-nation-residents: "城镇加入国家所需居民数: {count}" - nation-cost: "建立国家费用: {cost}" - create-nation-residents: "城镇建立国家所需居民数: {count}" + join-nation-residents: "城镇加入国家所需居民数: {count}" + nation-cost: "建立国家费用: {cost}" + create-nation-residents: "城镇建立国家所需居民数: {count}" nation-spawn: "国家出生点: {value}" - new-day: "新的一天开始于: {time}(服务器时间)" + new-day: "新的一天开始于: {time}(服务器时间)" daily-taxes: "每日税收: {value}" - town-upkeep: "城镇每日维护费: {cost}" - nation-upkeep: "你国家的每日维护费: {cost}" + town-upkeep: "城镇每日维护费: {cost}" + nation-upkeep: "你国家的每日维护费: {cost}" bankruptcy: "城镇破产: {value}" debt: "你的城镇已破产,欠款 {debt}。" - merge-cost: "合并城镇的基础费用:{cost}" - merge-distance: "合并的最远距离:{distance} 个区块" - reclaim-cost: "收复废墟的费用:{cost}" + merge-cost: "合并城镇的基础费用:{cost}" + merge-distance: "合并的最远距离:{distance} 个区块" + reclaim-cost: "收复废墟的费用:{cost}" reclaim-townless: "无城镇玩家可收复废墟:{value}" - bail: "默认保释金:{cost}" - max-bail: "最高保释金:{cost}" + bail: "默认保释金:{cost}" + max-bail: "最高保释金:{cost}" start: title: "入门" - description: "Towny 是什么、如何打开和看懂这些菜单、荒野、地图、邀请以及排行榜。" + description: "Towny 是什么、如何打开和看懂这些菜单、荒野、地图、邀请以及排行榜。" towny: "Towny 是什么?" - towny-body: "Towny 让玩家通过建立城镇来保护土地。城镇占领的区块不会被外人破坏,城镇可以收税,还能与其他城镇组成国家。无人占领的土地就是荒野。" + towny-body: "Towny 让玩家通过建立城镇来保护土地。城镇占领的区块不会被外人破坏,城镇可以收税,还能与其他城镇组成国家。无人占领的土地就是荒野。" menus: "打开菜单" - menus-body: "输入 /tm,或潜行时按副手切换键(F)即可打开主菜单。点击聊天中的 TownyMenu 前缀也能打开。每个按钮都会替你执行对应的 Towny 命令,费用和规则与 Towny 本身一致。" + menus-body: "输入 /tm,或潜行时按副手切换键(F)即可打开主菜单。点击聊天中的 TownyMenu 前缀也能打开。每个按钮都会替你执行对应的 Towny 命令,费用和规则与 Towny 本身一致。" buttons: "看懂按钮" - buttons-body: "将鼠标悬停在按钮上即可查看其作用。灰色染料表示你没有执行该操作的权限。开关开启时会发光。名称和数额在对话框中输入,无法撤销的操作会先请你确认。" + buttons-body: "将鼠标悬停在按钮上即可查看其作用。灰色染料表示你没有执行该操作的权限。开关开启时会发光。名称和数额在对话框中输入,无法撤销的操作会先请你确认。" wilderness: "荒野" - wilderness-body: "未被占领的土地不属于任何人。视世界设置而定,你也许可以在那里建造,但建筑不受任何保护。加入城镇才能保护你的成果。" + wilderness-body: "未被占领的土地不属于任何人。视世界设置而定,你也许可以在那里建造,但建筑不受任何保护。加入城镇才能保护你的成果。" map: "地图" - map-body: "地图显示你周围的区块,并按归属着色:你的城镇、你的地块、你的国家、盟友、敌人以及其他城镇。发光的格子正在出售。点击已占领的格子可查看所属城镇,右键出售中的格子即可购买。" + map-body: "地图显示你周围的区块,并按归属着色:你的城镇、你的地块、你的国家、盟友、敌人以及其他城镇。发光的格子正在出售。点击已占领的格子可查看所属城镇,右键出售中的格子即可购买。" invites: "邀请" - invites-body: "城镇邀请玩家,国家邀请城镇,国家之间还会发送结盟请求。所有待处理的邀请都在邀请菜单中,你可以在那里接受或拒绝。收到邀请时 TownyMenu 还会在聊天中提醒你,点击消息即可打开该菜单。" + invites-body: "城镇邀请玩家,国家邀请城镇,国家之间还会发送结盟请求。所有待处理的邀请都在邀请菜单中,你可以在那里接受或拒绝。收到邀请时 TownyMenu 还会在聊天中提醒你,点击消息即可打开该菜单。" leaderboards: "排行榜" - leaderboards-body: "排行榜菜单按居民数、领地和银行余额为城镇与国家排名,也按拥有的地块数为玩家排名。点击任意条目即可打开。" + leaderboards-body: "排行榜菜单按居民数、领地和银行余额为城镇与国家排名,也按拥有的地块数为玩家排名。点击任意条目即可打开。" join: title: "寻找城镇" description: "城镇的意义、加入城镇、建立自己的城镇以及离开城镇。" why: "为什么要加入城镇?" - why-body: "城镇居民共享受保护的土地,可以拥有地块、传送到城镇出生点,并参与所在城镇的国家。荒野中的建筑没有这些保护。" + why-body: "城镇居民共享受保护的土地,可以拥有地块、传送到城镇出生点,并参与所在城镇的国家。荒野中的建筑没有这些保护。" browse: "加入城镇" - browse-body: "浏览城镇目录,可按居民数、领地、是否开放或与你的距离排序。开放的城镇一键即可加入,其他城镇需要镇长或助理邀请你。" + browse-body: "浏览城镇目录,可按居民数、领地、是否开放或与你的距离排序。开放的城镇一键即可加入,其他城镇需要镇长或助理邀请你。" invites: "接受邀请" - invites-body: "城镇邀请你后,在邀请菜单中接受即可。你同一时间只能属于一个城镇。如果不想收到邀请,可以在个人设置中开启忽略邀请。" + invites-body: "城镇邀请你后,在邀请菜单中接受即可。你同一时间只能属于一个城镇。如果不想收到邀请,可以在个人设置中开启忽略邀请。" found: "建立城镇" - found-body: "站在你想建立城镇的地方,选择建立城镇。你所在的区块会成为城镇的主区块和出生点,你将成为镇长。新城镇必须与其他城镇保持足够距离。" + found-body: "站在你想建立城镇的地方,选择建立城镇。你所在的区块会成为城镇的主区块和出生点,你将成为镇长。新城镇必须与其他城镇保持足够距离。" leave: "离开城镇" - leave-body: "居民可以在城镇菜单中离开城镇。镇长不能直接离开:需要先把城镇交给其他居民,或者删除城镇。离开时,你拥有的地块会归还城镇。" + leave-body: "居民可以在城镇菜单中离开城镇。镇长不能直接离开:需要先把城镇交给其他居民,或者删除城镇。离开时,你拥有的地块会归还城镇。" town: title: "经营城镇" - description: "等级、职位、招募、出生点、设置、详情、公告、合并、出售以及废墟。" + description: "等级、职位、招募、出生点、设置、详情、公告、合并、出售以及废墟。" ranks: "镇长与职位" - ranks-body: "镇长拥有全部权力。助理、警长、建筑师等职位分担其中一部分,每个职位的具体权限由服务器决定。在居民菜单中打开居民资料即可授予职位。" + ranks-body: "镇长拥有全部权力。助理、警长、建筑师等职位分担其中一部分,每个职位的具体权限由服务器决定。在居民菜单中打开居民资料即可授予职位。" grow: "壮大城镇" - grow-body: "在居民菜单中邀请玩家,或将城镇设为开放,让任何人都能加入。居民越多,城镇通常能占领的土地也越多。" + grow-body: "在居民菜单中邀请玩家,或将城镇设为开放,让任何人都能加入。居民越多,城镇通常能占领的土地也越多。" spawn: "出生点与主区块" - spawn-body: "主区块是城镇的核心,城镇出生点就在其中。居民可以从城镇菜单传送到出生点;城镇公开时访客也可以。镇长可以在城镇详情中移动出生点和主区块。" + spawn-body: "主区块是城镇的核心,城镇出生点就在其中。居民可以从城镇菜单传送到出生点;城镇公开时访客也可以。镇长可以在城镇详情中移动出生点和主区块。" settings: "城镇设置" - settings-body: "PvP、敌对生物、火焰蔓延和爆炸对整个城镇统一开关。开放让任何人无需邀请即可加入,公开让访客可以使用你的出生点,和平则让城镇远离 PvP 与战争。国家中的城镇还可以关闭保护其周边土地的国家区域。" + settings-body: "PvP、敌对生物、火焰蔓延和爆炸对整个城镇统一开关。开放让任何人无需邀请即可加入,公开让访客可以使用你的出生点,和平则让城镇远离 PvP 与战争。国家中的城镇还可以关闭保护其周边土地的国家区域。" details: "名称、公告与标签" - details-body: "在城镇详情中,镇长可以重命名城镇、编写居民登录时看到的公告、设置简短的聊天标签,并选择城镇的地图颜色。" + details-body: "在城镇详情中,镇长可以重命名城镇、编写居民登录时看到的公告、设置简短的聊天标签,并选择城镇的地图颜色。" sell: "出售城镇" - sell-body: "镇长可以在城镇详情中出售城镇。购买者支付价格后成为新镇长。出售中的城镇会在城镇目录中标出。" + sell-body: "镇长可以在城镇详情中出售城镇。购买者支付价格后成为新镇长。出售中的城镇会在城镇目录中标出。" ruins: "废墟与删除" - ruins-body: "删除城镇会把它的全部土地归还荒野。启用废墟时,被删除或破产的城镇会先变成废墟,随时间逐渐对所有人开放。在废墟消失前,其居民可以在城镇菜单中收复它;在部分服务器上,无城镇的玩家也可以站在废墟中,通过“寻找城镇”菜单收复。" + ruins-body: "删除城镇会把它的全部土地归还荒野。启用废墟时,被删除或破产的城镇会先变成废墟,随时间逐渐对所有人开放。在废墟消失前,其居民可以在城镇菜单中收复它;在部分服务器上,无城镇的玩家也可以站在废墟中,通过“寻找城镇”菜单收复。" announce: "公告" - announce-body: "在居民菜单中使用“向城镇公告”,向所有在线居民发送消息。国家领袖也可以在国家菜单中向整个国家发布公告。" + announce-body: "在居民菜单中使用“向城镇公告”,向所有在线居民发送消息。国家领袖也可以在国家菜单中向整个国家发布公告。" merge: "合并城镇" - merge-body: "镇长可以在城镇目录中打开另一个城镇的页面,请求它并入自己的城镇。对方镇长必须在线并接受,之后对方的居民、土地和银行都会并入你的城镇。" + merge-body: "镇长可以在城镇目录中打开另一个城镇的页面,请求它并入自己的城镇。对方镇长必须在线并接受,之后对方的居民、土地和银行都会并入你的城镇。" status: "城镇等级与警告" - status-body: "在城镇菜单中点击顶部的城镇图标,即可查看等级、升级所需的居民或领地数量、土地与前哨上限,以及下一个新的一天需要支付的维护费。负债、领地超额、被征服等需要注意的情况会显示在这里和城镇图标上。" + status-body: "在城镇菜单中点击顶部的城镇图标,即可查看等级、升级所需的居民或领地数量、土地与前哨上限,以及下一个新的一天需要支付的维护费。负债、领地超额、被征服等需要注意的情况会显示在这里和城镇图标上。" claims: title: "占领土地" - description: "区块与领地上限、占领与放弃、前哨、额外领地以及割让与夺取土地。" + description: "区块与领地上限、占领与放弃、前哨、额外领地以及割让与夺取土地。" chunks: "领地以区块为单位" - chunks-body: "城镇以区块为单位占领土地,每个区块称为一块领地。每块已占领的区块都受城镇权限保护。可占领的数量取决于居民人数和额外领地。" + chunks-body: "城镇以区块为单位占领土地,每个区块称为一块领地。每块已占领的区块都受城镇权限保护。可占领的数量取决于居民人数和额外领地。" claim: "占领土地" - claim-body: "站在城镇旁边,可以占领你所在的区块、你周围的一片正方形区域,或被城镇包围的空隙。新领地必须与城镇已有的土地相邻。" + claim-body: "站在城镇旁边,可以占领你所在的区块、你周围的一片正方形区域,或被城镇包围的空隙。新领地必须与城镇已有的土地相邻。" auto: "自动占领" - auto-body: "开启自动占领后四处走动:只要城镇负担得起且还有领地名额,你走进的每个区块都会被占领。完成后记得关闭。" + auto-body: "开启自动占领后四处走动:只要城镇负担得起且还有领地名额,你走进的每个区块都会被占领。完成后记得关闭。" unclaim: "放弃土地" - unclaim-body: "放弃不再需要的区块可以腾出领地名额。主区块不能被放弃。有些服务器会慢慢把被放弃的土地恢复原貌。" + unclaim-body: "放弃不再需要的区块可以腾出领地名额。主区块不能被放弃。有些服务器会慢慢把被放弃的土地恢复原貌。" outposts: "前哨" - outposts-body: "前哨是远离城镇的领地,例如远处的矿场或农场。每个前哨都有居民可以传送过去的出生点,还可以在其周围继续占领土地。镇长也可以在地块菜单中把现有领地设为前哨,或移动前哨的出生点。" + outposts-body: "前哨是远离城镇的领地,例如远处的矿场或农场。每个前哨都有居民可以传送过去的出生点,还可以在其周围继续占领土地。镇长也可以在地块菜单中把现有领地设为前哨,或移动前哨的出生点。" bonus: "额外领地" - bonus-body: "领地达到上限了?用城镇银行的钱购买额外领地。每次购买后价格可能上涨。" + bonus-body: "领地达到上限了?用城镇银行的钱购买额外领地。每次购买后价格可能上涨。" cede: "割让土地" - cede-body: "站在城镇的某个区块中,选择“割让此地块”即可把它交给另一个城镇,例如用于调整边界。对方镇长必须在线并接受。主区块无法割让。" + cede-body: "站在城镇的某个区块中,选择“割让此地块”即可把它交给另一个城镇,例如用于调整边界。对方镇长必须在线并接受。主区块无法割让。" takeover: "夺取领地" - takeover-body: "领地超过上限的城镇处于超额状态。你的城镇可以用“夺取领地”占领超额城镇边缘、与你的领地相邻的区块。视服务器设置而定,双方国家可能需要互为敌对。" + takeover-body: "领地超过上限的城镇处于超额状态。你的城镇可以用“夺取领地”占领超额城镇边缘、与你的领地相邻的区块。视服务器设置而定,双方国家可能需要互为敌对。" plots: title: "地块" - description: "拥有、购买与出售地块,批量地块操作,地块类型、设置、信任、入镇天数限制以及地块组。" + description: "拥有、购买与出售地块,批量地块操作,地块类型、设置、信任、入镇天数限制以及地块组。" what: "什么是地块?" - what-body: "城镇占领的每个区块都是一个地块。在居民购买之前,地块归城镇所有;购买后由地块主决定谁可以在上面建造。站在地块中打开地块菜单即可查看其主人,点击地块图标可查看 Towny 的完整地块信息,或开启地块信息面板在行走时查看。" + what-body: "城镇占领的每个区块都是一个地块。在居民购买之前,地块归城镇所有;购买后由地块主决定谁可以在上面建造。站在地块中打开地块菜单即可查看其主人,点击地块图标可查看 Towny 的完整地块信息,或开启地块信息面板在行走时查看。" buy: "购买地块" - buy-body: "出售中的地块在地图上会发光,在地图上右键即可远程购买。也可以走进地块,打开地块菜单并选择购买地块,支付价格后即可成为地块主。" + buy-body: "出售中的地块在地图上会发光,在地图上右键即可远程购买。也可以走进地块,打开地块菜单并选择购买地块,支付价格后即可成为地块主。" sell: "出售与放弃" - sell-body: "地块主和镇长可以出售地块,价格设为 0 即免费赠送。放弃地块会把它归还城镇。镇长可以驱逐地块主,右键“驱逐所有者”还会立即重新出售该地块。" + sell-body: "地块主和镇长可以出售地块,价格设为 0 即免费赠送。放弃地块会把它归还城镇。镇长可以驱逐地块主,右键“驱逐所有者”还会立即重新出售该地块。" types: "地块类型" - types-body: "镇长可以设置每个地块的类型。商店和大使馆有各自的价格与税率,大使馆还能被其他城镇的玩家购买。竞技场始终允许 PvP,旅馆允许任何人睡觉,农场允许居民耕种,野外允许居民砍树和挖矿,监狱则用来关押犯人。" + types-body: "镇长可以设置每个地块的类型。商店和大使馆有各自的价格与税率,大使馆还能被其他城镇的玩家购买。竞技场始终允许 PvP,旅馆允许任何人睡觉,农场允许居民耕种,野外允许居民砍树和挖矿,监狱则用来关押犯人。" settings: "地块设置" - settings-body: "地块主可以开关自己地块上的 PvP、火焰、爆炸和生物,镇长可以决定地块是否收税。世界本身的规则始终优先。" + settings-body: "地块主可以开关自己地块上的 PvP、火焰、爆炸和生物,镇长可以决定地块是否收税。世界本身的规则始终优先。" trust: "地块信任" - trust-body: "在单个地块上信任某位玩家,即可让其在此建造,而不必为所有人修改地块权限。" + trust-body: "在单个地块上信任某位玩家,即可让其在此建造,而不必为所有人修改地块权限。" groups: "地块组与街区" - groups-body: "地块组把多个地块捆绑在一起,统一出售和管理,就像一座大房子。地块属于某个组时,它的出售、类型、设置、权限、信任和入镇天数限制都会作用于整个组。街区则为一片更大的地块区域命名,例如商业区。" + groups-body: "地块组把多个地块捆绑在一起,统一出售和管理,就像一座大房子。地块属于某个组时,它的出售、类型、设置、权限、信任和入镇天数限制都会作用于整个组。街区则为一片更大的地块区域命名,例如商业区。" join-days: "入镇天数限制" - join-days-body: "镇长可以把地块留给新居民或老居民:设置购买者至少或最多需要在城镇居住的天数,也可以两者都设。" + join-days-body: "镇长可以把地块留给新居民或老居民:设置购买者至少或最多需要在城镇居住的天数,也可以两者都设。" area: "批量地块操作" - area-body: "在地块菜单中选择你周围的方形或圆形区域及半径,即可购买其中所有出售中的地块、出售或停止出售你的地块,或放弃这些地块。你也可以一次放弃自己拥有的所有地块。" + area-body: "在地块菜单中选择你周围的方形或圆形区域及半径,即可购买其中所有出售中的地块、出售或停止出售你的地块,或放弃这些地块。你也可以一次放弃自己拥有的所有地块。" protection: title: "权限与保护" - description: "谁能在哪里建造、好友、信任与玩家单独权限、PvP 等开关、通缉犯以及监狱。" + description: "谁能在哪里建造、好友、信任与玩家单独权限、PvP 等开关、通缉犯以及监狱。" actions: "四种操作" actions-body: "Towny 分别保护四种操作:建造(放置方块)、破坏(破坏方块)、开关(门、按钮、拉杆和容器)以及物品使用(打火石、桶等物品)。" groups: "谁能获得权限" - groups-body: "每种操作可以对不同玩家群体允许或禁止。在城镇所有的土地上,群体为居民、国家成员、盟友和外人;在居民拥有的地块上,群体为好友、城镇居民、盟友和外人。" + groups-body: "每种操作可以对不同玩家群体允许或禁止。在城镇所有的土地上,群体为居民、国家成员、盟友和外人;在居民拥有的地块上,群体为好友、城镇居民、盟友和外人。" town: "城镇权限" - town-body: "镇长决定谁能在城镇仍拥有的土地上建造、破坏和交互,无人购买的地块都遵循这些设置。" + town-body: "镇长决定谁能在城镇仍拥有的土地上建造、破坏和交互,无人购买的地块都遵循这些设置。" personal: "你的地块权限" - personal-body: "你的个人权限适用于你拥有的每个地块。在个人资料中设置一次即可:你购买的地块会沿用它们,你仍可以在地块菜单中单独调整某个地块。" + personal-body: "你的个人权限适用于你拥有的每个地块。在个人资料中设置一次即可:你购买的地块会沿用它们,你仍可以在地块菜单中单独调整某个地块。" friends: "好友" - friends-body: "好友适用你地块上的好友权限,这样你信任的人可以在你的地块建造,而无需向整个城镇开放。" + friends-body: "好友适用你地块上的好友权限,这样你信任的人可以在你的地块建造,而无需向整个城镇开放。" trust: "受信任的玩家与城镇" - trust-body: "镇长可以信任居民,或信任另一个城镇的全部居民,让他们无视权限在城镇任意位置建造。地块主可以在单个地块上信任玩家。" + trust-body: "镇长可以信任居民,或信任另一个城镇的全部居民,让他们无视权限在城镇任意位置建造。地块主可以在单个地块上信任玩家。" flags: "PvP、火焰、爆炸与生物" - flags-body: "这些开关分别存在于每个世界、每个城镇、每个地块以及你自己的地块上。服务器可以在某个世界强制开启它们,无视城镇设置。和平的城镇和国家会保持 PvP 关闭。" + flags-body: "这些开关分别存在于每个世界、每个城镇、每个地块以及你自己的地块上。服务器可以在某个世界强制开启它们,无视城镇设置。和平的城镇和国家会保持 PvP 关闭。" outlaws: "通缉犯" - outlaws-body: "镇长和受信任的职位可以将捣乱者宣布为通缉犯。视服务器设置而定,通缉犯进入城镇时会收到警告或被传送走,还可能被关进监狱。" + outlaws-body: "镇长和受信任的职位可以将捣乱者宣布为通缉犯。视服务器设置而定,通缉犯进入城镇时会收到警告或被传送走,还可能被关进监狱。" jail: "监狱" - jail-body: "城镇可以把玩家关进监狱地块,例如在城镇中被击杀的通缉犯或敌人。被关押的玩家需要服满刑期,或在个人资料中支付保释金提前出狱。" + jail-body: "城镇可以把玩家关进监狱地块,例如在城镇中被击杀的通缉犯或敌人。被关押的玩家需要服满刑期,或在个人资料中支付保释金提前出狱。" overrides: "玩家单独权限" - overrides-body: "地块主可以为个别玩家单独设置在地块上的建造、破坏、开关和物品使用权限,不论其属于哪个群体。在地块权限的“玩家单独权限”中添加玩家,然后在 Towny 的编辑器中修改其权限。" + overrides-body: "地块主可以为个别玩家单独设置在地块上的建造、破坏、开关和物品使用权限,不论其属于哪个群体。在地块权限的“玩家单独权限”中添加玩家,然后在 Towny 的编辑器中修改其权限。" jailing: "关押玩家" - jailing-body: "镇长和治安官可以在城镇监狱菜单中关押在线居民,选择刑期、保释金、监狱和牢房,也可以提前释放囚犯。监狱是类型为“监狱”的地块,站在其中时可在地块菜单中添加牢房。" + jailing-body: "镇长和治安官可以在城镇监狱菜单中关押在线居民,选择刑期、保释金、监狱和牢房,也可以提前释放囚犯。监狱是类型为“监狱”的地块,站在其中时可在地块菜单中添加牢房。" nations: title: "国家" - description: "国家是什么、加入与建立国家、成员城镇、外交、制裁、等级、设置以及出生点。" + description: "国家是什么、加入与建立国家、成员城镇、外交、制裁、等级、设置以及出生点。" what: "什么是国家?" - what-body: "国家由多个城镇组成,首都城镇的镇长就是国王。国家共享银行、出生点、盟友和敌人,成员城镇还可能获得额外领地。" + what-body: "国家由多个城镇组成,首都城镇的镇长就是国王。国家共享银行、出生点、盟友和敌人,成员城镇还可能获得额外领地。" join: "加入国家" - join-body: "只有镇长可以带领城镇加入国家。开放的国家接受任何城镇;其他国家必须邀请你的城镇,邀请会出现在邀请菜单中。" + join-body: "只有镇长可以带领城镇加入国家。开放的国家接受任何城镇;其他国家必须邀请你的城镇,邀请会出现在邀请菜单中。" found: "建立国家" - found-body: "城镇未加入国家的镇长可以建立国家。其城镇成为首都,镇长成为国王。" + found-body: "城镇未加入国家的镇长可以建立国家。其城镇成为首都,镇长成为国王。" towns: "城镇与首都" - towns-body: "国王和助理可以邀请或移除城镇。国王可以把首都迁到其他成员城镇,或把领导权交给首都的居民。" + towns-body: "国王和助理可以邀请或移除城镇。国王可以把首都迁到其他成员城镇,或把领导权交给首都的居民。" relations: "盟友与敌人" - relations-body: "国家可以提议结盟(需对方国家接受),也可以将其他国家宣布为敌人。盟友之间不能互相伤害,还可以在你的土地上获得权限。视服务器设置而定,在你城镇中被击杀的敌人可能被关进监狱。" + relations-body: "国家可以提议结盟(需对方国家接受),也可以将其他国家宣布为敌人。盟友之间不能互相伤害,还可以在你的土地上获得权限。视服务器设置而定,在你城镇中被击杀的敌人可能被关进监狱。" settings: "国家设置" - settings-body: "开放让任何城镇无需邀请即可加入,公开让外人可以使用国家出生点,和平则让成员城镇远离 PvP 与战争。" + settings-body: "开放让任何城镇无需邀请即可加入,公开让外人可以使用国家出生点,和平则让成员城镇远离 PvP 与战争。" spawn: "国家出生点" - spawn-body: "成员可以传送到国家出生点,国家设置允许时盟友和访客也可以。国王可以在国家详情中移动出生点。" + spawn-body: "成员可以传送到国家出生点,国家设置允许时盟友和访客也可以。国王可以在国家详情中移动出生点。" sanctions: "制裁" - sanctions-body: "国家可以制裁国家外的城镇,受制裁城镇的居民无法传送到国家传送点。可在国家的城镇菜单中管理受制裁城镇。" + sanctions-body: "国家可以制裁国家外的城镇,受制裁城镇的居民无法传送到国家传送点。可在国家的城镇菜单中管理受制裁城镇。" level: "国家等级" - level-body: "在国家菜单中点击顶部的国家图标,即可查看等级、升级条件、每个成员城镇获得的额外领地、前哨和国家区域,以及国家的每日维护费。" + level-body: "在国家菜单中点击顶部的国家图标,即可查看等级、升级条件、每个成员城镇获得的额外领地、前哨和国家区域,以及国家的每日维护费。" economy: title: "金钱与税收" - description: "Towny 日、价格、银行、税收、维护费以及破产。" + description: "Towny 日、价格、银行、税收、维护费以及破产。" day: "Towny 日" - day-body: "Towny 每天收取一次税款和维护费。无法支付欠款的城镇和居民将承担下面几节课中说明的后果。" + day-body: "Towny 每天收取一次税款和维护费。无法支付欠款的城镇和居民将承担下面几节课中说明的后果。" bank: "城镇与国家银行" - bank-body: "城镇和国家各自在银行中存钱。任何人都可以存款,取款则需要相应的职位。银行用于支付领地、维护费及其他城镇开支。" + bank-body: "城镇和国家各自在银行中存钱。任何人都可以存款,取款则需要相应的职位。银行用于支付领地、维护费及其他城镇开支。" resident-tax: "居民税" - resident-tax-body: "镇长设定每位居民每天向城镇银行缴纳的税款,可以是固定金额,也可以是余额的百分比。无法缴税的居民可能会被移出城镇。" + resident-tax-body: "镇长设定每位居民每天向城镇银行缴纳的税款,可以是固定金额,也可以是余额的百分比。无法缴税的居民可能会被移出城镇。" plot-tax: "地块税" - plot-tax-body: "收税地块的主人还要每天缴纳地块税,商店和大使馆有各自的税率。无法缴税的地块主可能会失去地块。" + plot-tax-body: "收税地块的主人还要每天缴纳地块税,商店和大使馆有各自的税率。无法缴税的地块主可能会失去地块。" upkeep: "维护费" - upkeep-body: "城镇银行每天向服务器支付维护费,通常随城镇规模增长。国家也会从自己的银行支付维护费。" + upkeep-body: "城镇银行每天向服务器支付维护费,通常随城镇规模增长。国家也会从自己的银行支付维护费。" nation-tax: "国家税" - nation-tax-body: "国家每天从每个成员城镇的银行收取税款。无法缴税的城镇可能会被移出国家。" + nation-tax-body: "国家每天从每个成员城镇的银行收取税款。无法缴税的城镇可能会被移出国家。" bankruptcy: "债务与破产" - bankruptcy-body: "启用破产时,无法支付维护费的城镇会负债,而不会直接失去。破产的城镇在还清债务前无法占领土地或招募居民。未启用时,城镇会沦为废墟或被删除。无论哪种情况,TownyMenu 都会在聊天中提醒镇长。" + bankruptcy-body: "启用破产时,无法支付维护费的城镇会负债,而不会直接失去。破产的城镇在还清债务前无法占领土地或招募居民。未启用时,城镇会沦为废墟或被删除。无论哪种情况,TownyMenu 都会在聊天中提醒镇长。" prices: "价格与下一天" - prices-body: "主菜单中的“价格与新的一天”会倒计时下一个 Towny 日,并列出本服务器在建立、占领、维护、地块和税款方面的收费。需要花钱的按钮也会显示各自的价格,因此你在点击前就能看到占领、传送或购买地块要花多少。" + prices-body: "主菜单中的“价格与新的一天”会倒计时下一个 Towny 日,并列出本服务器在建立、占领、维护、地块和税款方面的收费。需要花钱的按钮也会显示各自的价格,因此你在点击前就能看到占领、传送或购买地块要花多少。" profile: title: "个人资料" - description: "你的资料、其他玩家、你的地块与税款、探索时能看到的信息以及出生点。" + description: "你的资料、其他玩家、你的地块与税款、探索时能看到的信息以及出生点。" menu: "你的资料" - menu-body: "个人资料显示你的城镇、职位、好友、地块和余额。写一段简短的介绍,其他玩家查看你的资料时就能看到。" + menu-body: "个人资料显示你的城镇、职位、好友、地块和余额。写一段简短的介绍,其他玩家查看你的资料时就能看到。" others: "其他玩家" - others-body: "在城镇、国家或好友列表中点击任意居民即可查看其资料。你可以在那里添加好友,镇长还可以邀请、信任、授予职位或踢出对方。" + others-body: "在城镇、国家或好友列表中点击任意居民即可查看其资料。你可以在那里添加好友,镇长还可以邀请、信任、授予职位或踢出对方。" display: "边界、标题与信息工具" - display-body: "个人设置会改变你探索时看到的内容:进入城镇时的标题、地块和城镇周围的粒子边界、进入新区块时的聊天地图,以及显示方块归属的信息工具。个人资料中的“显示模式”可以一次关闭所有模式,或恢复服务器默认设置。" + display-body: "个人设置会改变你探索时看到的内容:进入城镇时的标题、地块和城镇周围的粒子边界、进入新区块时的聊天地图,以及显示方块归属的信息工具。个人资料中的“显示模式”可以一次关闭所有模式,或恢复服务器默认设置。" spawn: "出生点" - spawn-body: "前往出生点会把你传送到城镇出生点;开启床出生点时则传送到你的床。视服务器设置而定,传送可能需要费用并有冷却时间。" + spawn-body: "前往出生点会把你传送到城镇出生点;开启床出生点时则传送到你的床。视服务器设置而定,传送可能需要费用并有冷却时间。" standing: "地块、税款与处境" - standing-body: "个人资料底部列出你拥有的所有地块、下一个新的一天需缴纳的税款、将你列为通缉犯的城镇,以及信任你在其中建造的城镇。" + standing-body: "个人资料底部列出你拥有的所有地块、下一个新的一天需缴纳的税款、将你列为通缉犯的城镇,以及信任你在其中建造的城镇。" From 3881197b579b738a89c619697dc9f4bfe2103edb Mon Sep 17 00:00:00 2001 From: Trilleo Date: Mon, 21 Sep 2026 19:24:58 +0800 Subject: [PATCH 5/6] Improvement: Reformat source code --- .../mc/plugins/townymenu/guis/MainMenu.kt | 80 +++++++++++-------- .../mc/plugins/townymenu/guis/MapMenu.kt | 10 ++- .../plugins/townymenu/guis/admin/AdminMenu.kt | 40 ++++++---- .../townymenu/guis/admin/AdminPlotMenu.kt | 10 ++- .../townymenu/guis/admin/TownyConfigMenu.kt | 10 ++- .../townymenu/guis/common/PermissionMenu.kt | 20 +++-- .../townymenu/guis/nation/NationMenu.kt | 30 ++++--- .../townymenu/guis/nation/NoNationMenu.kt | 10 ++- .../plugins/townymenu/guis/plot/PlotMenu.kt | 70 +++++++++------- .../townymenu/guis/resident/FriendsMenu.kt | 20 +++-- .../townymenu/guis/resident/ResidentMenu.kt | 10 ++- .../plugins/townymenu/guis/town/NoTownMenu.kt | 10 ++- .../townymenu/guis/town/TownClaimsMenu.kt | 10 ++- .../townymenu/guis/town/TownInfoMenu.kt | 10 ++- .../plugins/townymenu/guis/town/TownMenu.kt | 40 ++++++---- .../townymenu/guis/tutorial/TutorialMenu.kt | 10 ++- 16 files changed, 234 insertions(+), 156 deletions(-) diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/MainMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/MainMenu.kt index 5213510..024cb15 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/MainMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/MainMenu.kt @@ -39,10 +39,12 @@ class MainMenu(player: Player) : Menu(player, player.tr("main.title"), 6) { TownMenu(player, this).open() } } else { - button(20, Icons.icon( - Material.BELL, tr("main.town"), tr("main.town-none"), - actions = hints("click.open") - )) { + button( + 20, Icons.icon( + Material.BELL, tr("main.town"), tr("main.town-none"), + actions = hints("click.open") + ) + ) { NoTownMenu(player, this).open() } } @@ -55,10 +57,12 @@ class MainMenu(player: Player) : Menu(player, player.tr("main.title"), 6) { ).open() } - town != null -> button(22, Icons.icon( - Material.BEACON, tr("main.nation"), tr("main.nation-none"), - actions = hints("click.open") - )) { + town != null -> button( + 22, Icons.icon( + Material.BEACON, tr("main.nation"), tr("main.nation-none"), + actions = hints("click.open") + ) + ) { NoNationMenu(player, this).open() } @@ -87,44 +91,54 @@ class MainMenu(player: Player) : Menu(player, player.tr("main.title"), 6) { ) { PricesMenu(player, this).open() } - button(29, Icons.icon( - Material.FILLED_MAP, tr("main.map"), tr("main.map-description"), - actions = hints("click.open") - )) { + button( + 29, Icons.icon( + Material.FILLED_MAP, tr("main.map"), tr("main.map-description"), + actions = hints("click.open") + ) + ) { MapMenu( player, this ).open() } - button(30, Icons.icon( - Material.BELL, tr("main.towns"), tr("main.towns-description"), - actions = hints("click.browse") - )) { + button( + 30, Icons.icon( + Material.BELL, tr("main.towns"), tr("main.towns-description"), + actions = hints("click.browse") + ) + ) { TownListMenu( player, this ).open() } - button(31, Icons.icon( - Material.KNOWLEDGE_BOOK, tr("main.tutorial"), tr("main.tutorial-description"), - actions = hints("click.open") - )) { + button( + 31, Icons.icon( + Material.KNOWLEDGE_BOOK, tr("main.tutorial"), tr("main.tutorial-description"), + actions = hints("click.open") + ) + ) { TutorialMenu(player, this).open() } - button(32, Icons.icon( - Material.BEACON, tr("main.nations"), tr("main.nations-description"), - actions = hints("click.browse") - )) { + button( + 32, Icons.icon( + Material.BEACON, tr("main.nations"), tr("main.nations-description"), + actions = hints("click.browse") + ) + ) { NationListMenu( player, this ).open() } - button(34, Icons.icon( - Material.LECTERN, tr("main.leaderboards"), tr("main.leaderboards-description"), - actions = hints("click.view") - )) { + button( + 34, Icons.icon( + Material.LECTERN, tr("main.leaderboards"), tr("main.leaderboards-description"), + actions = hints("click.view") + ) + ) { LeaderboardMenu(player, this).open() } @@ -141,10 +155,12 @@ class MainMenu(player: Player) : Menu(player, player.tr("main.title"), 6) { } if (player.hasPermission(AdminMenu.PERMISSION)) { - button(53, Icons.icon( - Material.COMMAND_BLOCK, tr("main.admin"), tr("main.admin-description"), - actions = hints("click.open") - )) { + button( + 53, Icons.icon( + Material.COMMAND_BLOCK, tr("main.admin"), tr("main.admin-description"), + actions = hints("click.open") + ) + ) { AdminMenu( player, this diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/MapMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/MapMenu.kt index 9650267..9a0ff5b 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/MapMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/MapMenu.kt @@ -76,10 +76,12 @@ class MapMenu(player: Player, back: Menu?) : Menu(player, player.tr("map.title") } } backButton(49) - button(50, Icons.icon( - Material.CLOCK, tr("map.refresh"), tr("map.refresh-description"), - actions = hints("click.refresh") - )) { render() } + button( + 50, Icons.icon( + Material.CLOCK, tr("map.refresh"), tr("map.refresh-description"), + actions = hints("click.refresh") + ) + ) { render() } tutorialButton(53, Tutorial.GETTING_STARTED) } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminMenu.kt index 71fc9af..119105e 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminMenu.kt @@ -26,10 +26,12 @@ class AdminMenu(player: Player, back: Menu?) : Menu(player, player.tr("admin.tit return backButton(40) } - button(10, Icons.icon( - Material.COMPARATOR, tr("admin.config"), tr("admin.config-description"), - actions = hints("click.open") - )) { + button( + 10, Icons.icon( + Material.COMPARATOR, tr("admin.config"), tr("admin.config-description"), + actions = hints("click.open") + ) + ) { TownyConfigMenu(player, "", this).open() } button( @@ -41,16 +43,20 @@ class AdminMenu(player: Player, back: Menu?) : Menu(player, player.tr("admin.tit ) { worlds().open() } - button(14, Icons.icon( - Material.COMMAND_BLOCK, tr("admin.server"), tr("admin.server-description"), - actions = hints("click.open") - )) { + button( + 14, Icons.icon( + Material.COMMAND_BLOCK, tr("admin.server"), tr("admin.server-description"), + actions = hints("click.open") + ) + ) { AdminServerMenu(player, this).open() } - button(16, Icons.icon( - Material.WRITABLE_BOOK, tr("admin.plugin"), tr("admin.plugin-description"), - actions = hints("click.open") - )) { + button( + 16, Icons.icon( + Material.WRITABLE_BOOK, tr("admin.plugin"), tr("admin.plugin-description"), + actions = hints("click.open") + ) + ) { PluginSettingsMenu(player, this).open() } @@ -107,10 +113,12 @@ class AdminMenu(player: Player, back: Menu?) : Menu(player, player.tr("admin.tit AdminResidentListMenu(player, this).open() } - button(26, Icons.icon( - Material.IRON_DOOR, tr("admin-perms.open"), tr("admin-perms.open-description"), - actions = hints("click.open") - )) { + button( + 26, Icons.icon( + Material.IRON_DOOR, tr("admin-perms.open"), tr("admin-perms.open-description"), + actions = hints("click.open") + ) + ) { AdminPermsMenu(player, this).open() } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminPlotMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminPlotMenu.kt index 43e8ca6..b83694f 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminPlotMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/AdminPlotMenu.kt @@ -98,10 +98,12 @@ class AdminPlotMenu(player: Player, back: Menu) : Menu(player, player.tr("admin- run("towny:townyadmin unclaim", { this.plot?.townOrNull }) } } - button(50, Icons.icon( - Material.CLOCK, tr("map.refresh"), tr("plot.refresh-description"), - actions = hints("click.refresh") - )) { render() } + button( + 50, Icons.icon( + Material.CLOCK, tr("map.refresh"), tr("plot.refresh-description"), + actions = hints("click.refresh") + ) + ) { render() } backButton(49) } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/TownyConfigMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/TownyConfigMenu.kt index ece48d1..3e205bb 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/TownyConfigMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/admin/TownyConfigMenu.kt @@ -35,10 +35,12 @@ class TownyConfigMenu(player: Player, private val section: String, back: Menu) : } + TownyConfig.settings(section).map { settingEntry(this, it) } override fun controls() { - button(47, Icons.icon( - Material.COMPASS, tr("admin-config.search"), tr("admin-config.search-description"), - actions = hints("click.search") - )) { + button( + 47, Icons.icon( + Material.COMPASS, tr("admin-config.search"), tr("admin-config.search-description"), + actions = hints("click.search") + ) + ) { prompt(tr("admin-config.search-title"), tr("admin-config.search-label")) { query -> ListMenu(player, tr("admin-config.results-title", "query" to TownyUtil.text(query)), this) { list -> TownyConfig.search(query).map { settingEntry(list, it) } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/PermissionMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/PermissionMenu.kt index a0ad520..ecee179 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/PermissionMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/common/PermissionMenu.kt @@ -68,17 +68,21 @@ class PermissionMenu( } } - guarded(25, node, Icons.icon( - Material.WATER_BUCKET, tr("perm.reset"), tr("perm.reset-description"), - actions = hints("click.reset") - )) { + guarded( + 25, node, Icons.icon( + Material.WATER_BUCKET, tr("perm.reset"), tr("perm.reset-description"), + actions = hints("click.reset") + ) + ) { run("$command reset", ::snapshot) } overrides?.let { open -> - button(34, Icons.icon( - Material.PLAYER_HEAD, tr("perm.overrides"), tr("perm.overrides-description"), - actions = hints("click.open") - )) { + button( + 34, Icons.icon( + Material.PLAYER_HEAD, tr("perm.overrides"), tr("perm.overrides-description"), + actions = hints("click.open") + ) + ) { open(this).open() } } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationMenu.kt index 43e3007..e3b320a 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NationMenu.kt @@ -82,22 +82,28 @@ class NationMenu(player: Player, back: Menu?) : Menu(player, player.tr("nation.t BankMenu(player, nation, this).open() } } - grid.add(Icons.icon( - Material.SHIELD, tr("nation.relations"), tr("nation.relations-description"), - actions = hints("click.view") - )) { + grid.add( + Icons.icon( + Material.SHIELD, tr("nation.relations"), tr("nation.relations-description"), + actions = hints("click.view") + ) + ) { NationRelationsMenu(player, nation, this).open() } - grid.add(Icons.icon( - Material.LEVER, tr("nation.settings"), tr("nation.settings-description"), - actions = hints("click.open") - )) { + grid.add( + Icons.icon( + Material.LEVER, tr("nation.settings"), tr("nation.settings-description"), + actions = hints("click.open") + ) + ) { toggles().open() } - grid.add(Icons.icon( - Material.WRITABLE_BOOK, tr("nation.details"), tr("nation.details-description"), - actions = hints("click.open") - )) { + grid.add( + Icons.icon( + Material.WRITABLE_BOOK, tr("nation.details"), tr("nation.details-description"), + actions = hints("click.open") + ) + ) { NationSettingsMenu(player, this).open() } grid.add( diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NoNationMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NoNationMenu.kt index 2eb8af2..653958d 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NoNationMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/nation/NoNationMenu.kt @@ -35,10 +35,12 @@ class NoNationMenu(player: Player, back: Menu) : Menu(player, player.tr("no-nati ) } } - button(13, Icons.icon( - Material.OAK_DOOR, tr("no-nation.browse"), tr("no-nation.browse-description"), - actions = hints("click.browse") - )) { + button( + 13, Icons.icon( + Material.OAK_DOOR, tr("no-nation.browse"), tr("no-nation.browse-description"), + actions = hints("click.browse") + ) + ) { NationListMenu(player, this).open() } val invites = resident?.townOrNull?.receivedInvites?.size ?: 0 diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotMenu.kt index 5f1aa76..6d5d511 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/plot/PlotMenu.kt @@ -44,16 +44,20 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title ) { runAndClose("towny:plot perm hud") } - button(47, Icons.icon( - Material.FILLED_MAP, tr("main.map"), tr("common.map-description"), - actions = hints("click.open") - )) { + button( + 47, Icons.icon( + Material.FILLED_MAP, tr("main.map"), tr("common.map-description"), + actions = hints("click.open") + ) + ) { MapMenu(player, this).open() } - button(50, Icons.icon( - Material.CLOCK, tr("map.refresh"), tr("plot.refresh-description"), - actions = hints("click.refresh") - )) { render() } + button( + 50, Icons.icon( + Material.CLOCK, tr("map.refresh"), tr("plot.refresh-description"), + actions = hints("click.refresh") + ) + ) { render() } tutorialButton(53, Tutorial.PLOTS) backButton(49) } @@ -92,10 +96,12 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title run("towny:town claim outpost", { town.numTownBlocks }, delayTicks = 20) } } - grid.add(Icons.icon( - Material.MAP, tr("plot.area"), tr("plot.area-description"), - actions = hints("click.open") - )) { + grid.add( + Icons.icon( + Material.MAP, tr("plot.area"), tr("plot.area-description"), + actions = hints("click.open") + ) + ) { PlotAreaMenu(player, this).open() } } @@ -265,10 +271,12 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title } } } - grid.add(Icons.icon( - Material.LEVER, tr("plot.settings"), tr("plot.settings-description"), *groupLines, - actions = hints("click.open") - )) { + grid.add( + Icons.icon( + Material.LEVER, tr("plot.settings"), tr("plot.settings-description"), *groupLines, + actions = hints("click.open") + ) + ) { toggles(plot, group != null).open() } val permNode = @@ -356,10 +364,12 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title } } } - grid.add(Icons.icon( - Material.CHEST, tr("plot.groups"), tr("plot.groups-description"), - actions = hints("click.open") - )) { + grid.add( + Icons.icon( + Material.CHEST, tr("plot.groups"), tr("plot.groups-description"), + actions = hints("click.open") + ) + ) { PlotGroupMenu(player, this).open() } grid.add( @@ -371,17 +381,21 @@ class PlotMenu(player: Player, back: Menu?) : Menu(player, player.tr("plot.title ) { runAndClose("towny:plot clear") } - grid.add(Icons.icon( - Material.MAP, tr("plot.area"), tr("plot.area-description"), - actions = hints("click.open") - )) { + grid.add( + Icons.icon( + Material.MAP, tr("plot.area"), tr("plot.area-description"), + actions = hints("click.open") + ) + ) { PlotAreaMenu(player, this).open() } if (town != null) { - button(46, Icons.icon( - Material.BELL, "${TownyUtil.name(town.name)}", tr("plot.town-description"), - actions = hints("click.view") - )) { + button( + 46, Icons.icon( + Material.BELL, "${TownyUtil.name(town.name)}", tr("plot.town-description"), + actions = hints("click.view") + ) + ) { TownInfoMenu(player, town, this).open() } } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/FriendsMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/FriendsMenu.kt index a6519b7..84c07cc 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/FriendsMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/FriendsMenu.kt @@ -34,10 +34,12 @@ class FriendsMenu(player: Player, back: Menu) : PagedMenu(player, player.tr("fri override fun controls() { tutorialButton(52, Tutorial.PROTECTION) - button(47, Icons.icon( - Material.PLAYER_HEAD, tr("friends.add-online"), tr("friends.add-online-description"), - actions = hints("click.choose-player") - )) { + button( + 47, Icons.icon( + Material.PLAYER_HEAD, tr("friends.add-online"), tr("friends.add-online-description"), + actions = hints("click.choose-player") + ) + ) { Pickers.resident( this, tr("friends.add-title"), @@ -45,10 +47,12 @@ class FriendsMenu(player: Player, back: Menu) : PagedMenu(player, player.tr("fri run("towny:resident friend add ${picked.name}", ::friendNames) }.open() } - button(51, Icons.icon( - Material.NAME_TAG, tr("friends.add-name"), tr("friends.add-name-description"), - actions = hints("click.type-name") - )) { + button( + 51, Icons.icon( + Material.NAME_TAG, tr("friends.add-name"), tr("friends.add-name-description"), + actions = hints("click.type-name") + ) + ) { prompt(tr("friends.add-title"), tr("common.player-name")) { name -> run("towny:resident friend add ${TownyUtil.argument(name)}", ::friendNames) } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/ResidentMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/ResidentMenu.kt index 354089b..2e04fd9 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/ResidentMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/resident/ResidentMenu.kt @@ -59,10 +59,12 @@ class ResidentMenu(player: Player, back: Menu?) : Menu(player, player.tr("profil ) { FriendsMenu(player, this).open() } - row.add(Icons.icon( - Material.LEVER, tr("profile.settings"), tr("profile.settings-description"), - actions = hints("click.open") - )) { + row.add( + Icons.icon( + Material.LEVER, tr("profile.settings"), tr("profile.settings-description"), + actions = hints("click.open") + ) + ) { toggles().open() } row.add( diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/NoTownMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/NoTownMenu.kt index 20e7b21..9fd6f85 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/NoTownMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/NoTownMenu.kt @@ -38,10 +38,12 @@ class NoTownMenu(player: Player, back: Menu) : Menu(player, player.tr("no-town.t ) } } - row.add(Icons.icon( - Material.OAK_DOOR, tr("no-town.browse"), tr("no-town.browse-description"), - actions = hints("click.browse") - )) { + row.add( + Icons.icon( + Material.OAK_DOOR, tr("no-town.browse"), tr("no-town.browse-description"), + actions = hints("click.browse") + ) + ) { TownListMenu(player, this).open() } val invites = resident?.receivedInvites?.size ?: 0 diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownClaimsMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownClaimsMenu.kt index 7ab5b47..7e156df 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownClaimsMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownClaimsMenu.kt @@ -173,10 +173,12 @@ class TownClaimsMenu(player: Player, back: Menu) : Menu(player, player.tr("claim ) { run("towny:resident toggle townclaim", { resident?.hasMode("townclaim") }) } - grid.add(Icons.icon( - Material.FILLED_MAP, tr("main.map"), tr("common.map-description"), - actions = hints("click.open") - )) { + grid.add( + Icons.icon( + Material.FILLED_MAP, tr("main.map"), tr("common.map-description"), + actions = hints("click.open") + ) + ) { MapMenu(player, this).open() } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownInfoMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownInfoMenu.kt index f6ef78e..c723202 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownInfoMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownInfoMenu.kt @@ -26,10 +26,12 @@ class TownInfoMenu(player: Player, private val town: Town, back: Menu) : val grid = layout(19, 20, 21, 22, 23, 24, 25) if (viewer?.townOrNull == town) { - grid.add(Icons.icon( - Material.WRITABLE_BOOK, tr("town-info.manage"), tr("town-info.manage-description"), - actions = hints("click.open") - )) { + grid.add( + Icons.icon( + Material.WRITABLE_BOOK, tr("town-info.manage"), tr("town-info.manage-description"), + actions = hints("click.open") + ) + ) { TownMenu(player, this).open() } } diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownMenu.kt index a877c11..feab40c 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/town/TownMenu.kt @@ -105,22 +105,28 @@ class TownMenu(player: Player, back: Menu?) : Menu(player, player.tr("town.title ) { TownClaimsMenu(player, this).open() } - grid.add(Icons.icon( - Material.FILLED_MAP, tr("main.map"), tr("common.map-description"), - actions = hints("click.open") - )) { + grid.add( + Icons.icon( + Material.FILLED_MAP, tr("main.map"), tr("common.map-description"), + actions = hints("click.open") + ) + ) { MapMenu(player, this).open() } - grid.add(Icons.icon( - Material.LEVER, tr("town.settings"), tr("town.settings-description"), - actions = hints("click.open") - )) { + grid.add( + Icons.icon( + Material.LEVER, tr("town.settings"), tr("town.settings-description"), + actions = hints("click.open") + ) + ) { toggles().open() } - grid.add(Icons.icon( - Material.WRITABLE_BOOK, tr("town.details"), tr("town.details-description"), - actions = hints("click.open") - )) { + grid.add( + Icons.icon( + Material.WRITABLE_BOOK, tr("town.details"), tr("town.details-description"), + actions = hints("click.open") + ) + ) { TownSettingsMenu(player, this).open() } grid.add( @@ -132,10 +138,12 @@ class TownMenu(player: Player, back: Menu?) : Menu(player, player.tr("town.title ) { permissions().open() } - grid.add(Icons.icon( - Material.TRIPWIRE_HOOK, tr("common.trusted"), tr("town.trusted-description"), - actions = hints("click.view") - )) { + grid.add( + Icons.icon( + Material.TRIPWIRE_HOOK, tr("common.trusted"), tr("town.trusted-description"), + actions = hints("click.view") + ) + ) { TownTrustMenu(player, town, this).open() } grid.add( diff --git a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/tutorial/TutorialMenu.kt b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/tutorial/TutorialMenu.kt index 9fb272f..c19cf39 100644 --- a/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/tutorial/TutorialMenu.kt +++ b/src/main/kotlin/net/trilleo/mc/plugins/townymenu/guis/tutorial/TutorialMenu.kt @@ -45,10 +45,12 @@ class TutorialMenu(player: Player, back: Menu?) : Menu(player, player.tr("tutori } backButton(49) if (read > 0) { - button(51, Icons.icon( - Material.WATER_BUCKET, tr("tutorial.reset"), tr("tutorial.reset-description"), - actions = hints("click.reset") - )) { + button( + 51, Icons.icon( + Material.WATER_BUCKET, tr("tutorial.reset"), tr("tutorial.reset-description"), + actions = hints("click.reset") + ) + ) { DialogUtil.confirm( player, MiniMessage.miniMessage().deserialize(tr("tutorial.reset-confirm")), null, onYes = { From 3ac2b78e91b66fdf05b108edb10871b6c1583deb Mon Sep 17 00:00:00 2001 From: Trilleo Date: Mon, 21 Sep 2026 19:26:02 +0800 Subject: [PATCH 6/6] Update: Plugin version 1.1.0 release --- CHANGELOG.md | 2 ++ gradle.properties | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index bb39be5..b2c05e9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,8 @@ ## Unreleased +## Version 1.1.0 + ### Improvements #### Menus diff --git a/gradle.properties b/gradle.properties index 0ef051f..476e1bc 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,7 +1,7 @@ kotlin.code.style=official # Plugin Properties -plugin_version=1.0.2 +plugin_version=1.1.0 # Dependency Versions towny_version=0.103.2.7