Example #1
0
 public static IEnumerable <string> GetRoleNames()
 {
     foreach (GameRole role in Enum.GetValues(typeof(GameRole)))
     {
         yield return(GameElement.Role(role));
     }
 }
Example #2
0
 public static PollCommandArguments Kick(string name)
 {
     return(new PollCommandArguments
     {
         Title = $"Excommunicate vote",
         Description = $"Is {name} a {GameElement.Role(GameRole.Killer)} ?"
     });
 }
Example #3
0
        public static Embed Of(GroupType group, List <PlayerReward> rewardedPlayers)
        {
            EmbedFieldBuilder[] playerScore = rewardedPlayers
                                              .OrderByDescending(s => s.Reward)
                                              .Select(PlayerScore)
                                              .ToArray();

            return(new EmbedBuilder()
                   .WithTitle("S C O R E B O A R D")
                   .WithDescription($"{GameElement.Group(group)} WIN")
                   .WithFields(playerScore)
                   .WithColor(Color.DarkRed)
                   .Build());
        }
Example #4
0
        public static EmbedFieldBuilder PlayerScore(PlayerReward obj)
        {
            string description = string.Join("\n", new string[]
            {
                string.Empty,
                $"Role: {GameElement.Role(obj.Player.Role)}",
                $"Alive: {IsAlive(obj.Player.Active)}",
                $"Alive for: {obj.DaysAliveFor} days",
                $"Reward: {obj.Reward} coins"
            });

            return(new EmbedFieldBuilder()
                   .WithIsInline(true)
                   .WithName(obj.Player.User.Username)
                   .WithValue(description));
        }
Example #5
0
 public static string InitialRoleReveal(GameRole role)
 => $"Your role is {GameElement.Role(role)}.";
Example #6
0
 public static string SeenTheSigns(Player targetPlayer)
 => $"{targetPlayer.User.Username} flocks with {GameElement.Group(targetPlayer.Group)}.";