From 08474d91efed02d658219a6ad37a75ccb6673021 Mon Sep 17 00:00:00 2001 From: Joseph Ferano Date: Mon, 28 Mar 2022 23:17:56 +0700 Subject: [PATCH] Fix a few text bugs and send message to HoP when buying whitelist --- Bot/Games/Trainer.fs | 2 +- Bot/InviteTracker.fs | 13 +++++++++++-- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/Bot/Games/Trainer.fs b/Bot/Games/Trainer.fs index 13399c6..816d718 100644 --- a/Bot/Games/Trainer.fs +++ b/Bot/Games/Trainer.fs @@ -83,7 +83,7 @@ let defend (ctx : IDiscordContext) = let handleDefenseMsg hackId = { ButtonId = "Trainer-3" - ButtonText = "Got it" + ButtonText = "Next" Message = $"🎉 Congratulations you successfully defended my {hackId} hack!\n\n" + "Shields only protect you for a LIMITED TIME, so remember to keep them mounted at all times, or risk getting hacked!" } diff --git a/Bot/InviteTracker.fs b/Bot/InviteTracker.fs index b3d10b8..725b527 100644 --- a/Bot/InviteTracker.fs +++ b/Bot/InviteTracker.fs @@ -202,7 +202,7 @@ let private showInviteMessage (ctx : IDiscordContext) = do! sendFollowUpMessage ctx $""" ⚠️ Only Degen Hackers can `/recuit` others to the Degenz Army. You must **COMPLETE YOUR TRAINING FIRST!** Then you can `/recruit`... -Go to {GuildEnvironment.channelTraining} now to become a **HACKER**! +Go to <#{GuildEnvironment.channelTraining}> now to become a **HACKER**! """ | None -> do! sendFollowUpMessage ctx $"You're not in the game! Go to <#{GuildEnvironment.channelShelters}> NOW to get assigned a private bunk, and **JOIN THE GAME!**" @@ -331,7 +331,7 @@ Your NFT will be your In-Game Character that provides you with unique traits, an |> Async.AwaitTask |> Async.Ignore with e -> - printfn $"Error trying to get channel {GuildEnvironment.channelTraining}\n\n{e.Message}" + printfn $"Error trying to get channel Training Dojo\n\n{e.Message}" } |> Async.RunSynchronously type WhitelistResult = @@ -478,6 +478,15 @@ let handleBuyWhitelist (ctx : IDiscordContext) = do! ctx.GetDiscordMember().GrantRoleAsync(role) let! _ = DbService.updatePlayerCurrency -WhitelistPrice player builder.AddEmbed(embed) |> ignore + + // Send message to hall of privacy + let builder = DiscordMessageBuilder() + builder.WithContent($"{player.Name} just purchased WHITELIST!") |> ignore + let channel = ctx.GetGuild().GetChannel(GuildEnvironment.channelEventsHackerBattle) + do! channel.SendMessageAsync(builder) + |> Async.AwaitTask + |> Async.Ignore + do! ctx.FollowUp(builder) } :> Task