jaqobb / message-editor

Spigot plugin that allows editing in-game messages that were previously unmodifiable
MIT License
13 stars 2 forks source link

Translatable chat #6

Closed CodeDoctorDE closed 3 years ago

CodeDoctorDE commented 4 years ago

Can you please add that you can use translatable messages?

See the javadocs:

https://javadoc.io/doc/net.md-5/bungeecord-chat/latest/net/md_5/bungee/api/chat/TranslatableComponent.html

btw: nice idea :)

jaqobb commented 4 years ago

Hey, I'm gonna see what I can do but no ETA for now, wanna focus on other features.

jaqobb commented 3 years ago

Now that I think of it, unless you are talking about something else I believe translatable chat is already supported. As you can see (message JSON), you can easily replace translatable message path and placeholders:

[22:22:19 INFO]: [MessageEditor] Place: SYSTEM_CHAT
[22:22:19 INFO]: [MessageEditor] Player: jaq0bb
[22:22:19 INFO]: [MessageEditor] Message JSON: '\{"translate":"commands\.gamemode\.success\.self","with":\[\{"translate":"gameMode\.spectator"\}\]\}'
[22:22:19 INFO]: [MessageEditor] Message clear: 'Set own game mode to Spectator Mode'
[22:22:19 INFO]: [MessageEditor] Message ID: 'SCghhTeg'

I'm gonna close this issue for now as I believe it's solved. If you talked about some other translatable chat, feel free to reopen it with more information about the feature.