|
@@ -1,5 +1,6 @@
|
|
|
using System.Collections.Generic;
|
|
|
using MafiaTelegramBot.Game;
|
|
|
+using MafiaTelegramBot.Game.GameRoles;
|
|
|
using MafiaTelegramBot.Game.GameRooms;
|
|
|
using Telegram.Bot.Types.ReplyMarkups;
|
|
|
|
|
@@ -189,10 +190,12 @@ namespace MafiaTelegramBot.Resources
|
|
|
var inlineButtons = new InlineKeyboardButton[players.Count + 1][];
|
|
|
for (var i = 0; i<players.Count; ++i)
|
|
|
{
|
|
|
+ var isMafia = (players[i].GetRole() is Roles.Mafia or Roles.Don or Roles.Dame)
|
|
|
+ || (players[i].GetRole() is Roles.Werewolf && ((WerewolfRole) players[i].CurrentRole).IsMafia);
|
|
|
inlineButtons[i] = new[]
|
|
|
{
|
|
|
InlineKeyboardButton.WithCallbackData($"({players[i].TurnOrder}) " +
|
|
|
- $"{players[i].NickName}{(players[i].GetRole() is Roles.Mafia or Roles.Don or Roles.Dame ? " - " + players[i].GetRoleName() : "")}",
|
|
|
+ $"{players[i].NickName}{(isMafia ? " - " + players[i].GetRoleName() : "")}",
|
|
|
$"{Callback.MafiaTarget}|{userId}|{players[i].Id}")
|
|
|
};
|
|
|
}
|