Reimnop / Discord4Fabric

A beautiful Discord bot client for Fabric
MIT License
37 stars 20 forks source link

[Feature/Enhancement:request] Role checks and features #37

Closed gadget78 closed 2 years ago

gadget78 commented 2 years ago

is there a way to have an added, Constraint, that checks to see if a linked account has a role within discord ? like..
check_role

to use this within the CustomEvents, for example..

{ "minecraft_message": { "requires": [ "linked_account", "check_role": "993535629453430835", "%d4f:message%": "!request-sword" ], "actions": [ { "id": "run_command", "value": "give %player:name_unformatted% minecraft:diamond_sword" } ] } }

so people with certain roles within discord, can then have direct access to inventory, or other Minecraft perks.

... did some edits, as re-thought this, when looking at the source code, and did a much better example

gadget78 commented 2 years ago

edited above message so it had a better example . but realised in doing so, that there isnt a "constraint" that can refine/match whats actually in a message ? .. or have i missed that somewhere ? ..

Reimnop commented 2 years ago

There is not one at the moment, you can request it

gadget78 commented 2 years ago

Thankyou for the reply, and the continued support/updates.. will create a new post to request it separately, again thankyou for taken these ideas onboard. with these two enhancement, will make the "Custom Event" very powerful indeed ! ..

gadget78 commented 2 years ago

be cool to also have the discord chat thats bridged to MC to use the colour that is assigned in discord ... and if linked player, the msg thats bridged from MC to discord, could use their discord colour within the embed ?