DiscordSRV

DiscordSRV

86.8k Downloads

Ability to use placeholders from PlaceholderAPI in discord to mc chat

saboooor opened this issue ยท 11 comments

commented

This would be useful for when a server has custom multicolored prefixes and they want to use that instead of discord roles
How I imagine it would look like in message.yml:

DiscordToMinecraftChatMessageFormatLinked: ""
DiscordToMinecraftChatMessageFormat: ""

DiscordToMinecraftChatMessageFormatLinked would be the message format if the user is linked and placeholders can be used in it
DiscordToMinecraftChatMessageFormat would be the same as we have now

commented

oh also this doesn't really mention splitting the options, it mentions the example to add placeholderapi support only to the "Linked" format because adding placeholder api support to the non-linked format would be kinda useless or wouldn't make sense

What if the user isn't linked and there's a placeholder that will not work/return empty if no player is provided? Would lead to ugly placeholders in chat or empty spots/inconsistency

commented

oh also this doesn't really mention splitting the options, it mentions the example to add placeholderapi support only to the "Linked" format because adding placeholder api support to the non-linked format would be kinda useless or wouldn't make sense

What if the user isn't linked and there's a placeholder that will not work/return empty if no player is provided? Would lead to ugly placeholders in chat or empty spots/inconsistency

I think that DiscordSRV would just use the normal NoRole format we have now because of the absence of a minecraft account that's linked to the discord

commented

oh also this doesn't really mention splitting the options, it mentions the example to add placeholderapi support only to the "Linked" format because adding placeholder api support to the non-linked format would be kinda useless or wouldn't make sense

What if the user isn't linked and there's a placeholder that will not work/return empty if no player is provided? Would lead to ugly placeholders in chat or empty spots/inconsistency

I think that DiscordSRV would just use the normal NoRole format we have now because of the absence of a minecraft account that's linked to the discord

So then in that case there would be 3 formats, where one of them is for linked accounts, what if having linked users have a different format for people with and without roles is desired: then we end up back at 4 config options

commented

Or instead of that it could be the other way around for compatibility with old config with

DiscordToMinecraftChatMessageFormat: ""
DiscordToMinecraftChatMessageFormatUnlinked: ""

DiscordToMinecraftChatMessageFormatUnlinked would be the same as DiscordToMinecraftChatMessageFormat that we have now
DiscordToMinecraftChatMessageFormat would be the message format if the user is linked and placeholders can be used in it

commented

woowo!! very epic

commented

Is this not a duplicate of #893?

commented

that ticket doesn't mention splitting the options, which would essentially render it a nearly useless feature

commented

Fair enough. This seems like a better way of handling it, I'll close #893.

commented

One issue I'm seeing with the suggested implementation of this is that would result in 4 formats for to discord, since we already have ...NoRole on top of the default.

commented

@underscore11code i don't think anyone would use placeholders for the NoRole format though

commented

oh also this doesn't really mention splitting the options, it mentions the example to add placeholderapi support only to the "Linked" format because adding placeholder api support to the non-linked format would be kinda useless or wouldn't make sense