Fix reply mention oddities
Created by: VelvetThePanda
Summary
Provides a proper fix to #1044, which would've introduced more bugs regarding mentions.
Details
This fixes an issue where editing a message would absolutely wreck mentions, which is at least partly Discord's fault
This also closes #833.
Changes proposed
Fix the use of DiscordMentions
, which was the actual cause of the reply bug.
Add GetMentions
method to DiscordMessage, which resolves what entities have actually been mentioned.
Remove parsing users by regex as per this comment. It could be a breaking change.
Added a _rawMentionedRoles
field to aid in figuring out what roles are actually mentioned, because _mentionedRoles
contains API-provided mentions + regex'd mentions.
Notes
Closes #1044, Closes #833 (For GitHub)
I've tested this manually for the past hour figuring out how to get it to work, so I'm gonna hope I didn't break it.