diff --git a/bridgeipelago.py b/bridgeipelago.py index bd986f1..fa08b23 100644 --- a/bridgeipelago.py +++ b/bridgeipelago.py @@ -776,11 +776,15 @@ async def ProcessDeathQueue(): o.close() if EnableDeathlinkMessages == "true": - DeathMessage = "**Deathlink received from: " + str(chatmessage['data']['source']) + "**" + DeathMessage = "**Deathlink!** " + # Flavour + if EnableFlavorDeathlink == "true": + DeathMessage += GetFlavorText(str(chatmessage['data']['source'])) + else: + DeathMessage += "Received from **" + str(chatmessage['data']['source']) + "**" + # Cause if chatmessage['data'].get('cause') is not None and chatmessage['data'].get('cause') != "": - DeathMessage = DeathMessage + "\n" + "Cause: " + str(chatmessage['data']['cause']) - elif EnableFlavorDeathlink == "true": - DeathMessage = "Deathlink: " + GetFlavorText(str(chatmessage['data']['source'])) + DeathMessage += "\n" + "*Cause:* " + str(chatmessage['data']['cause']) await SendMainChannelMessage(DeathMessage) else: return diff --git a/modules/DeathlinkFlavor.py b/modules/DeathlinkFlavor.py index 9290575..bd24934 100644 --- a/modules/DeathlinkFlavor.py +++ b/modules/DeathlinkFlavor.py @@ -104,4 +104,5 @@ def GetFlavorText(PlayerName): "PLAYER walked into logic’s trap.", "PLAYER perished chasing progression.", ] - return (random.choice(FlavorList)).replace("PLAYER", PlayerName) \ No newline at end of file + PlayerNameFormatted = f"**{PlayerName}**" + return (random.choice(FlavorList)).replace("PLAYER", PlayerNameFormatted) \ No newline at end of file