Refactor commands

This commit is contained in:
nea
2023-06-11 00:30:51 +02:00
parent 2df2ee1f18
commit cd4c6e2102

View File

@@ -72,7 +72,7 @@ fun firmamentCommand() = literal("firmament") {
thenArgument("item", string()) { item -> thenArgument("item", string()) { item ->
suggestsList { RepoManager.neuRepo.items.items.keys } suggestsList { RepoManager.neuRepo.items.items.keys }
thenExecute { thenExecute {
val itemName = SkyblockId(getString(context, "item")) val itemName = SkyblockId(get(item))
source.sendFeedback(Text.translatable("firmament.price", itemName.neuItem)) source.sendFeedback(Text.translatable("firmament.price", itemName.neuItem))
val bazaarData = ItemCostData.bazaarData[itemName] val bazaarData = ItemCostData.bazaarData[itemName]
if (bazaarData != null) { if (bazaarData != null) {