DiscordSRV Integration
A5H73Y opened this issue ยท 3 comments
Integrate with the DiscordSRV plugin to allow Parkour to communicate with Discord for certain events. Such as:
- Finishing a Course
- Earning the best time on a Course
- Earning a new ParkourLevel / Rank
Each of these should be disableable, as to not spam server with unwanted information.
A nice solution might be to listen to the Parkour events then send the output straight to the DiscordSRV plugin.
I'm afraid I'm not going to continue with this task, I don't want to add another plugin dependency to the project.
As most discord functionality can be achieved through commands, paired with Parkour's event system and placeholders this should be achievable without the linking of the two.
Yes, you can use /discord broadcast command however that is very limited to what we can do about the formatting. many plugins already implemented DiscordSVR integration and all we have to do is specify which channel ID it needs to broadcast. and the plugin will broadcast the configured things to the discord automatically given that DiscordSVR and the bot has been properly set up.
So in the configuration we can specify which announcements to be broadcasted on Discord.
For example in parkour config.yml a new section can be added in future updates like the following example:
Discord:
Enabled: true
# Specify which channel certain announcement messages get sent.
Channels:
PlayerJoinCourse:
Enabled: true
Channel-ID: 821043826504237148
PlayerReachCheckpoint:
Enabled: true
Channel-ID: 821043826504237148
PlayerFinishCourse:
Enabled: true
Channel-ID: 821043826504237148
BestTimeEver:
Enabled: true
Channel-ID: 821043826504237148
BestTimeEver:
Enabled: true
Channel-ID: 821043826504237148
PlayerRecievedReward:
Enabled: true
Channel-ID: 821043826504237148