Skip to content

Commit

Permalink
Change click event to suggest command
Browse files Browse the repository at this point in the history
  • Loading branch information
Emirlol committed Nov 1, 2024
1 parent 9a9b3f8 commit cf9ad00
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,11 @@ public static Text onMessage(Text message, boolean overlay) {
.append(Text.literal(result)
.formatted(Formatting.AQUA))
.append(ScreenTexts.SPACE)
.append(Text.translatable("text.skyblocker.clickToCopy")
.append(Text.translatable("text.skyblocker.clickToSuggest")
.formatted(Formatting.GREEN)
.styled(style ->
style.withClickEvent(new ClickEvent(ClickEvent.Action.COPY_TO_CLIPBOARD, result))
.withHoverEvent(new HoverEvent(HoverEvent.Action.SHOW_TEXT, Constants.PREFIX.get().append(Text.translatable("text.skyblocker.clickToCopy.@Tooltip"))))
style.withClickEvent(new ClickEvent(ClickEvent.Action.SUGGEST_COMMAND, result))
.withHoverEvent(new HoverEvent(HoverEvent.Action.SHOW_TEXT, Constants.PREFIX.get().append(Text.translatable("text.skyblocker.clickToSuggest.@Tooltip"))))
));
} catch (Exception e) {
return message;
Expand Down
4 changes: 2 additions & 2 deletions src/main/resources/assets/skyblocker/lang/en_us.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@
"text.skyblocker.translate": "Translate",
"text.skyblocker.modrinth": "Modrinth",
"text.skyblocker.discord": "Discord",
"text.skyblocker.clickToCopy": "[Click To Copy]",
"text.skyblocker.clickToCopy.@Tooltip": "Click to copy to clipboard.",
"text.skyblocker.clickToSuggest": "[Click To Suggest In Chat]",
"text.skyblocker.clickToSuggest.@Tooltip": "Click to suggest this in chat.",

"skyblocker.skyblockerScreen": "Skyblocker Main Screen",

Expand Down

0 comments on commit cf9ad00

Please sign in to comment.