9
0
mirror of https://github.com/Auxilor/Reforges.git synced 2025-12-23 08:59:24 +00:00

Added %time% placeholder to reload message

This commit is contained in:
Auxilor
2021-11-09 13:38:53 +00:00
parent 57519b6d9e
commit df72cd0e57
2 changed files with 4 additions and 3 deletions

View File

@@ -3,12 +3,13 @@ package com.willfp.reforges.commands
import com.willfp.eco.core.EcoPlugin
import com.willfp.eco.core.command.CommandHandler
import com.willfp.eco.core.command.impl.Subcommand
import com.willfp.eco.util.StringUtils
class CommandReload(plugin: EcoPlugin) : Subcommand(plugin, "reload", "reforges.command.reload", false) {
override fun getHandler(): CommandHandler {
return CommandHandler { sender, _ ->
plugin.reload()
sender.sendMessage(plugin.langYml.getMessage("reloaded"))
sender.sendMessage(plugin.langYml.getMessage("reloaded", StringUtils.FormatOption.WITHOUT_PLACEHOLDERS)
.replace("%time%", plugin.reloadWithTime().toString()))
}
}
}

View File

@@ -3,7 +3,7 @@ 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!)"
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!"