feat: initial 6-character HID rework

This commit is contained in:
Iris System 2024-04-28 15:46:06 +12:00
parent 73f43b8cb3
commit 9f56697241
30 changed files with 208 additions and 91 deletions

View file

@ -175,6 +175,8 @@ public class ReactionAdded: IEventHandler<MessageReactionAddEvent>
private async ValueTask HandleQueryReaction(MessageReactionAddEvent evt, FullMessage msg)
{
var guild = await _cache.GetGuild(evt.GuildId!.Value);
var system = await _repo.GetSystemByAccount(evt.UserId);
var config = system != null ? await _repo.GetSystemConfig(system.Id) : null;
// Try to DM the user info about the message
try
@ -188,11 +190,12 @@ public class ReactionAdded: IEventHandler<MessageReactionAddEvent>
msg.System,
msg.Member,
guild,
config,
LookupContext.ByNonOwner,
DateTimeZone.Utc
));
embeds.Add(await _embeds.CreateMessageInfoEmbed(msg, true));
embeds.Add(await _embeds.CreateMessageInfoEmbed(msg, true, config));
await _rest.CreateMessage(dm, new MessageRequest { Embeds = embeds.ToArray() });
}