From 4c1ee554b4fe0aaec6c054fab9a337b2edfc9f59 Mon Sep 17 00:00:00 2001 From: Auxilor Date: Mon, 24 Oct 2022 17:05:03 +0100 Subject: [PATCH] libreforge-updater --- build.gradle | 4 +- config/checkstyle/checkstyle.xml | 184 ------------------ config/checkstyle/suppression.xml | 14 -- .../com/willfp/reforges/gui/ReforgeGUI.kt | 6 +- .../com/willfp/reforges/reforges/Reforge.kt | 14 +- .../core-plugin/src/main/resources/config.yml | 7 + .../core-plugin/src/main/resources/lang.yml | 26 +-- gradle.properties | 4 +- 8 files changed, 36 insertions(+), 223 deletions(-) delete mode 100644 config/checkstyle/checkstyle.xml delete mode 100644 config/checkstyle/suppression.xml diff --git a/build.gradle b/build.gradle index 033d452..0f6e4c5 100644 --- a/build.gradle +++ b/build.gradle @@ -44,8 +44,8 @@ allprojects { } dependencies { - compileOnly 'com.willfp:eco:6.43.0' - implementation 'com.willfp:libreforge:3.114.1' + compileOnly 'com.willfp:eco:6.44.0' + implementation 'com.willfp:libreforge:3.115.0' implementation 'org.joml:joml:1.10.4' compileOnly 'org.jetbrains:annotations:23.0.0' diff --git a/config/checkstyle/checkstyle.xml b/config/checkstyle/checkstyle.xml deleted file mode 100644 index 1e777ee..0000000 --- a/config/checkstyle/checkstyle.xml +++ /dev/null @@ -1,184 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/config/checkstyle/suppression.xml b/config/checkstyle/suppression.xml deleted file mode 100644 index ca32641..0000000 --- a/config/checkstyle/suppression.xml +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - - - - - - - \ No newline at end of file diff --git a/eco-core/core-plugin/src/main/kotlin/com/willfp/reforges/gui/ReforgeGUI.kt b/eco-core/core-plugin/src/main/kotlin/com/willfp/reforges/gui/ReforgeGUI.kt index 68a243f..b935314 100644 --- a/eco-core/core-plugin/src/main/kotlin/com/willfp/reforges/gui/ReforgeGUI.kt +++ b/eco-core/core-plugin/src/main/kotlin/com/willfp/reforges/gui/ReforgeGUI.kt @@ -277,7 +277,7 @@ object ReforgeGUI { ) onRender { player, menu -> - menu.addState( + menu.setState( player, "item_to_reforge", menu.getCaptiveItem( player, plugin.configYml.getInt("gui.item-slot.row"), @@ -285,7 +285,7 @@ object ReforgeGUI { ) ) - menu.addState( + menu.setState( player, "reforge_stone", menu.getCaptiveItem( player, plugin.configYml.getInt("gui.stone-slot.row"), @@ -321,7 +321,7 @@ object ReforgeGUI { } } - menu.addState(player, "reforge_status", PricedReforgeStatus(status, cost)) + menu.setState(player, "reforge_status", PricedReforgeStatus(status, cost)) } onClose { event, menu -> diff --git a/eco-core/core-plugin/src/main/kotlin/com/willfp/reforges/reforges/Reforge.kt b/eco-core/core-plugin/src/main/kotlin/com/willfp/reforges/reforges/Reforge.kt index 222c0ab..1eb1565 100644 --- a/eco-core/core-plugin/src/main/kotlin/com/willfp/reforges/reforges/Reforge.kt +++ b/eco-core/core-plugin/src/main/kotlin/com/willfp/reforges/reforges/Reforge.kt @@ -30,13 +30,15 @@ class Reforge( val targets = config.getStrings("targets").mapNotNull { ReforgeTargets.getByName(it) }.toSet() - override val effects = config.getSubsections("effects").mapNotNull { - Effects.compile(it, "Reforge ID $id") - }.toSet() + override val effects = Effects.compile( + config.getSubsections("effects"), + "Reforge $id" + ) - override val conditions = config.getSubsections("conditions").mapNotNull { - Conditions.compile(it, "Reforge ID $id") - }.toSet() + override val conditions = Conditions.compile( + config.getSubsections("conditions"), + "Reforge $id" + ) val requiresStone = config.getBool("stone.enabled") diff --git a/eco-core/core-plugin/src/main/resources/config.yml b/eco-core/core-plugin/src/main/resources/config.yml index 0ba9ad8..961265e 100644 --- a/eco-core/core-plugin/src/main/resources/config.yml +++ b/eco-core/core-plugin/src/main/resources/config.yml @@ -179,6 +179,13 @@ cannot-afford-type: sound: "BLOCK_NOTE_BLOCK_PLING" pitch: 0.5 +cannot-afford-price: + in-actionbar: true + sound: + enabled: true + sound: "BLOCK_NOTE_BLOCK_PLING" + pitch: 0.5 + point-names: # If you have point names that look ugly (eg g_souls) then you can map them to nice names to be shown to players. example_point: "Nicely Formatted Point" diff --git a/eco-core/core-plugin/src/main/resources/lang.yml b/eco-core/core-plugin/src/main/resources/lang.yml index b44c96c..a0de1c3 100644 --- a/eco-core/core-plugin/src/main/resources/lang.yml +++ b/eco-core/core-plugin/src/main/resources/lang.yml @@ -3,20 +3,11 @@ messages: no-permission: "&cYou don't have permission to do this!" not-player: "&cThis command must be run by a player" invalid-command: "&cUnknown subcommand!" - reloaded: "Reloaded! (Restart if you're removed reforges!) Took %time%ms" - insufficient-money: "&cYou don't have enough money for this!" - insufficient-xp: "&cYou don't have enough xp levels for this!" - applied-reforge: "Applied %reforge%&r reforge!" - needs-player: "&cYou must specify a player" - invalid-player: "&cInvalid player!" - needs-stone: "&cYou must specify a reforge stone" - invalid-stone: "&cInvalid reforge!" - give-success: "Gave &a%reforge%&r reforge stone to &a%recipient%" - on-cooldown: "&cThis reforge is on cooldown! &fTime left: &a%seconds% seconds" + reloaded: "Reloaded!" cannot-afford: "&cYou can't afford to do this! &fCost: &a$$%cost%" cannot-afford-type: "&cYou can't afford to do this! &fCost: &a%cost% %type%" - invalid-reforge: "&cInvalid reforge!" - needs-reforge: "&cYou must specify a reforge" + cannot-afford-price: "&cYou can't afford to do this! &fPrice: %price%" + on-cooldown: "&cThis effect is on cooldown! &fTime left: &a%seconds% seconds" cannot-transmit: "&cYou can't transmit here!" must-specify-lrcdb-id: "&cYou must specify the ID of the config to download! Not sure what this means? Go to &alrcdb.auxilor.io" lrcdb-import-error: "&cError importing config: &f%message%" @@ -26,6 +17,17 @@ messages: lrcdb-export-error: "&cError exporting config: &f%message%" lrcdb-export-success: "&fExported &a%name%&f! View it on &alrcdb.auxilor.io&f, or share your config ID: &f%id%" + insufficient-money: "&cYou don't have enough money for this!" + insufficient-xp: "&cYou don't have enough xp levels for this!" + applied-reforge: "Applied %reforge%&r reforge!" + needs-player: "&cYou must specify a player" + invalid-player: "&cInvalid player!" + needs-stone: "&cYou must specify a reforge stone" + invalid-stone: "&cInvalid reforge!" + give-success: "Gave &a%reforge%&r reforge stone to &a%recipient%" + invalid-reforge: "&cInvalid reforge!" + needs-reforge: "&cYou must specify a reforge" + menu: title: "Reforge Item" close: "&cClose" \ No newline at end of file diff --git a/gradle.properties b/gradle.properties index b6f33f8..c8fab5e 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,4 +1,4 @@ #libreforge-updater -#Fri Oct 21 19:25:56 BST 2022 -version=5.65.1 +#Mon Oct 24 17:05:03 BST 2022 +version=5.66.0 plugin-name=Reforges