当前位置: 首页>>代码示例>>C#>>正文


C# Card.SetTags方法代码示例

本文整理汇总了C#中Card.SetTags方法的典型用法代码示例。如果您正苦于以下问题:C# Card.SetTags方法的具体用法?C# Card.SetTags怎么用?C# Card.SetTags使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Card的用法示例。


在下文中一共展示了Card.SetTags方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: Create

 public Card Create(Game game)
 {
     var card = new Card(game)
                    {
                        Type = CardType.Item,
                        Name = "Thunderstone Shard",
                        Gold = 1,
                        Cost = 0,
                        Text = "<b>Dungeon:</b> One hero gains Strength +2."
                               + "<br/><br/>"
                               + "<b>Spoils:</b> Gain 1 XP.",
                        Vp = 1
                    };
     card.SetTags("Item", "Thunderstone");
     card.CreateAbility()
         .Description("One hero gains Strength +2")
         .SelectCards(x => x.Select().FromHand().Filter(c => c.IsHero()).Caption("Select Hero").Message("Select hero to use Thunderstone Shard"))
         .OnCardsSelected(x => x.Selected.First().AddModifier(new PlusMod(card, Attr.Strength, 2)))
     //                .Condition(player => player.Hand.Any(c => c.IsHero()))
         .On(Phase.Dungeon);
     card.CreateAbility()
         .Description("Gain 1 XP")
         .Action(x => x.Player.Xp++)
         .On(Phase.Spoils);
     return card;
 }
开发者ID:Slugburn,项目名称:Thunderstone,代码行数:26,代码来源:ThunderstoneShard.cs

示例2: CreateCard

        private Card CreateCard(Game game, MonsterDef def)
        {
            var card = new Card(game)
                           {
                               Type = CardType.Monster,
                               Name = def.Name,
                               Health = def.Health,
                               Gold = def.Gold,
                               Text = def.Text,
                               Xp = def.Xp,
                               Vp = def.Vp,
                           };
            card.SetTags(Tags);
            card.SetTags("Level {0}".Template(Level));
            if (def.Modify != null)
                def.Modify(card);

            return card;
        }
开发者ID:Slugburn,项目名称:Thunderstone,代码行数:19,代码来源:MonsterRandomizer.cs

示例3: Create

 public Card Create(Game game)
 {
     var card = new Card(game)
                    {
                        Type = CardType.Item,
                        Name = "Torch",
                        Gold = 2,
                        Light = 1,
                        Cost = 3
                    };
     card.SetTags("Item", "Light", "Basic");
     return card;
 }
开发者ID:Slugburn,项目名称:Thunderstone,代码行数:13,代码来源:Torch.cs

示例4: CreateCard

 private Card CreateCard(Game game, HeroDef def)
 {
     var card = new Card(game)
                    {
                        Level = def.Level,
                        Type = CardType.Hero,
                        Name = "{0} {1}".Template(Name, def.Name),
                        Cost = def.Cost,
                        Gold = def.Gold,
                        Light = def.Light,
                        MagicAttack = def.MagicAttack,
                        PhysicalAttack = def.PhysicalAttack,
                        Strength = def.Strength,
                        Text = def.Text,
                        Vp = def.Vp,
                        Xp = def.Xp,
                    };
     card.SetTags(Tags);
     card.SetTags("Level {0}".Template(def.Level));
     if (def.Modify != null)
         def.Modify(card);
     return card;
 }
开发者ID:Slugburn,项目名称:Thunderstone,代码行数:23,代码来源:HeroRandomizer.cs

示例5: Create

 public Card Create(Game game)
 {
     var card = new Card(game)
                    {
                        Type = CardType.Weapon,
                        Name = "Longspear",
                        Gold = 2,
                        Strength = 3,
                        Cost = 3,
                        Text = "<b>Physical Attack +1</b>",
                        PotentialPhysicalAttack = () => 1,
                    };
     card.SetTags("Weapon", "Polearm", "Basic");
     card.CreateAbility().EquipWeapon(Attr.PhysicalAttack, 1).On(Phase.Equip);
     return card;
 }
开发者ID:Slugburn,项目名称:Thunderstone,代码行数:16,代码来源:Longspear.cs

示例6: CreateCards

 public override IEnumerable<Card> CreateCards(Game game)
 {
     var card = new Card(game)
                    {
                        Type = CardType.ThunderstoneBearer,
                        Name = Name,
                        Health = Health,
                        Gold = Gold,
                        Text = Text,
                        Xp = Xp,
                        Vp = Vp
                    };
     card.SetTags(Tags);
     Modify(card);
     return new[] {card};
 }
开发者ID:Slugburn,项目名称:Thunderstone,代码行数:16,代码来源:ThunderstoneBearer.cs

示例7: CreateCard

 private Card CreateCard(Game game)
 {
     var card = new Card(game)
                    {
                        Type = Type,
                        Cost = Cost,
                        Gold = Gold,
                        Light = Light,
                        Name = Name,
                        Strength = Strength,
                        Text = Text,
                        Vp = Vp,
                    };
     card.SetTags(Tags);
     Modify(card);
     return card;
 }
开发者ID:Slugburn,项目名称:Thunderstone,代码行数:17,代码来源:VillageRandomizer.cs

示例8: CreateCards

 public override IEnumerable<Card> CreateCards(Game game)
 {
     return Enumerable.Range(0, 4)
         .Select(x =>
             {
                 var card = new Card(game)
                     {
                         Name = Name,
                         PhysicalAttack = -1,
                         Text = "<b>Attack -1</b><br/><br/>" + GetAdditionalText(),
                         Owner = CardOwner.Game,
                         Type = CardType.Curse
                     };
                 card.SetTags(Tags);
                 Modify(card);
                 return card;
             });
 }
开发者ID:Slugburn,项目名称:Thunderstone,代码行数:18,代码来源:CurseRandomizer.cs

示例9: Create

        public Card Create(Game game)
        {
            var card = new Card(game)
                           {
                               Type = CardType.Hero,
                               Name = "Regular",
                               Gold = 0,
                               Strength = 3,
                               Cost = 0,
                               Text = "<b>Physical Attack +1</b>"
                                      + "<br/><br/>"
                                      + "<b>Dungeon:</b> If equipped with a polearm, draw a card.",
                               PhysicalAttack = 1,
                               Xp = 2,
                               Owner = CardOwner.Village
                           };
            card.SetTags("Level 0", "Basic");
            card.CreateAbility()
                .DrawCards(1)
                .Condition(player => card.IsEquipped && card.GetEquipped().First().HasTag("Polearm"))
                .On(Phase.Dungeon);

            return card;
        }
开发者ID:Slugburn,项目名称:Thunderstone,代码行数:24,代码来源:Regular.cs


注:本文中的Card.SetTags方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。