Пример #1
0
        public static Badge AwardUserCustom(Guid userId, string image, string title, string description = null)
        {
            BaseBadge badge = new BaseBadge
            {
                Image       = image,
                Title       = title,
                Description = description,
                IsAcquired  = true
            };

            return(badge.AwardUser(userId));
        }
Пример #2
0
        public static Badge AwardUser <T>(Guid userId) where T : BaseBadge
        {
            BaseBadge badge = (BaseBadge)Activator.CreateInstance(typeof(T));

            return(badge.AwardUser(userId));
        }