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


C# ResistanceType类代码示例

本文整理汇总了C#中ResistanceType的典型用法代码示例。如果您正苦于以下问题:C# ResistanceType类的具体用法?C# ResistanceType怎么用?C# ResistanceType使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


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

示例1: resistenciaBonus

 /*
  * Bonus que a habilidade da no tipo de resistência.
  */
 public override int resistenciaBonus(HabilidadeNode node, ResistanceType type)
 {
     if (ResistanceType.Fire.Equals(type) || ResistanceType.Cold.Equals(type) || ResistanceType.Energy.Equals(type))
     {
         return node.Nivel * 3;
     }
     return 0;
 }
开发者ID:evildude807,项目名称:kaltar,代码行数:11,代码来源:ResistenciaElemental.cs

示例2: resistenciaBonus

 /*
  * Bonus que a habilidade da no tipo de resistência.
  */
 public override int resistenciaBonus(HabilidadeNode node, ResistanceType type)
 {
     if (ResistanceType.Poison.Equals(type))
     {
         return node.Nivel * 3;
     }
     return 0;
 }
开发者ID:evildude807,项目名称:kaltar,代码行数:11,代码来源:CouroDeCobra.cs

示例3:

 public float this[ResistanceType type]
 {
     get
     {
         return resistanceMods[(int)type];
     }
     set
     {
         resistanceMods[(int)type] = value;
     }
 }
开发者ID:massdriver,项目名称:FreeUniverse,代码行数:11,代码来源:ResistanceStats.cs

示例4: Deserialize

 public override void Deserialize(GenericReader reader)
 {
     base.Deserialize(reader);
     var version = reader.ReadInt();
     MinAuraDelay = reader.ReadInt();
     MaxAuraDelay = reader.ReadInt();
     MinAuraDamage = reader.ReadInt();
     MaxAuraDamage = reader.ReadInt();
     AuraRange = reader.ReadInt();
     m_AuraType = (ResistanceType) reader.ReadInt();
     AuraPoison = Poison.Deserialize(reader);
     m_AuraMessage = reader.ReadString();
     m_AuraDelay = DateTime.UtcNow;
 }
开发者ID:rokann,项目名称:JustUO,代码行数:14,代码来源:AuraCreature.cs

示例5: bonusResistencia

        /**
         * Retorna o bônus que o jogador tem para o tipo de resistencia.
         */
        public int bonusResistencia(Jogador jogador, ResistanceType type)
        {
            int bonus = 0;

            //habilidade racial
            Dictionary<IdHabilidadeRacial, HabilidadeNode> racial = jogador.getSistemaRaca().getHabilidades();
            List<HabilidadeNode> habilidadesNode = new List<HabilidadeNode>(racial.Values);
            bonus += getBonus(habilidadesNode, HabilidadeTipo.racial, type);

            //habilidade talento
            Dictionary<IdHabilidadeTalento, HabilidadeNode> talento = jogador.getSistemaTalento().getHabilidades();
            habilidadesNode = new List<HabilidadeNode>(talento.Values);
            bonus += getBonus(habilidadesNode, HabilidadeTipo.talento, type);

            return bonus;
        }
开发者ID:evildude807,项目名称:kaltar,代码行数:19,代码来源:ResistenciaUtil.cs

示例6: RaelisDragonStageOne

		public RaelisDragonStageOne()
		{
			EvolutionMessage = "has evolved";
			NextEpThreshold = 75000; EpMinDivisor = 10; EpMaxDivisor = 5; DustMultiplier = 20;
			BaseSoundID = 0xDB;
			BodyValue = 52; ControlSlots = 2; MinTameSkill = 99.9; VirtualArmor = 25;

			DamagesTypes = new ResistanceType[1] { ResistanceType.Physical };
			MinDamages = new int[1] { 100 };
			MaxDamages = new int[1] { 100 };

			ResistanceTypes = new ResistanceType[1] { ResistanceType.Physical };
			MinResistances = new int[1] { 15 };
			MaxResistances = new int[1] { 15 };

			DamageMin = 11; DamageMax = 17; HitsMin = 250; HitsMax = 350;
			StrMin = 50; StrMax = 60; DexMin = 56; DexMax = 75; IntMin = 26; IntMax = 36;
		}
开发者ID:kamronbatman,项目名称:DefianceUO-Pre1.10,代码行数:18,代码来源:DragonEvoSpec.cs

示例7: resistiu

        /**
         * Realiza o teste se o alvo conseguiu resistir ao tipo de ataque.
         * O teste é baseado na resistencia menos a dificultade.
         * A dificuldade deve ser um valor entre 0 a 100. Que será como %.
         *
         * Ex.: (Resistencia - dificuldade) %
         */
        public bool resistiu(Mobile alvo, int dificultade, ResistanceType tipo)
        {
            bool resistiu = false;

            int valorResistencia = alvo.GetResistance(tipo);
            valorResistencia -= dificultade;

            //ajusta para ter mínimo de 5% e máximo de 95%
            valorResistencia = valorResistencia < 5 ? 5 : valorResistencia;
            valorResistencia = valorResistencia > 100 ? 95 : valorResistencia;
            valorResistencia /= 100;

            if (valorResistencia > Utility.RandomDouble())
            {
                resistiu = true;
            }

            return resistiu;
        }
开发者ID:evildude807,项目名称:kaltar,代码行数:26,代码来源:ResistenciaUtil.cs

示例8: HiryuStageOne

		public HiryuStageOne()
		{
			EvolutionMessage = "has evolved";
			NextEpThreshold = 50000; EpMinDivisor = 10; EpMaxDivisor = 5; DustMultiplier = 20;
			BaseSoundID = 0x4FD;
			Hue = 2406;
			BodyValue = 201; ControlSlots = 3; MinTameSkill = 99.9; VirtualArmor = 30;

			DamagesTypes = new ResistanceType[1] { ResistanceType.Physical };
			MinDamages = new int[1] { 100 };
			MaxDamages = new int[1] { 100 };

			ResistanceTypes = new ResistanceType[1] { ResistanceType.Physical };
			MinResistances = new int[1] { 15 };
			MaxResistances = new int[1] { 15 };

			DamageMin = 11; DamageMax = 15; HitsMin = 1; HitsMax = 1;
			StrMin = 75; StrMax = 85; DexMin = 95; DexMax = 105; IntMin = 80; IntMax = 100;
		}
开发者ID:kamronbatman,项目名称:DefianceUO-Pre1.10,代码行数:19,代码来源:HiryuEvoSpec.cs

示例9: RaelisDragonStageTwo

		public RaelisDragonStageTwo()
		{
			EvolutionMessage = "has evolved";
			NextEpThreshold = 175000; EpMinDivisor = 20; EpMaxDivisor = 40; DustMultiplier = 20;
			BaseSoundID = 219;
			BodyValue = 89; VirtualArmor = 30;

			DamagesTypes = new ResistanceType[5] { ResistanceType.Physical, ResistanceType.Fire, ResistanceType.Cold,
													ResistanceType.Poison, ResistanceType.Energy };
			MinDamages = new int[5] { 100, 25, 25, 25, 25 };
			MaxDamages = new int[5] { 100, 25, 25, 25, 25 };

			ResistanceTypes = new ResistanceType[5] { ResistanceType.Physical, ResistanceType.Fire, ResistanceType.Cold,
														ResistanceType.Poison, ResistanceType.Energy };
			MinResistances = new int[5] { 20, 20, 20, 20, 20 };
			MaxResistances = new int[5] { 20, 20, 20, 20, 20 };

			DamageMin = 1; DamageMax = 1; HitsMin= 500; HitsMax = 550;
			StrMin = 60; StrMax = 70; DexMin = 20; DexMax = 30; IntMin = 10; IntMax = 15;
		}
开发者ID:kamronbatman,项目名称:DefianceUO-Pre1.10,代码行数:20,代码来源:DragonEvoSpec.cs

示例10: HiryuStageTwo

		public HiryuStageTwo()
		{
			EvolutionMessage = "has evolved";
			NextEpThreshold = 150000; EpMinDivisor = 20; EpMaxDivisor = 10; DustMultiplier = 20;
			BaseSoundID = 0x4FD;
			BodyValue = 217; VirtualArmor = 40;
			Hue = 2406;

			DamagesTypes = new ResistanceType[5] { ResistanceType.Physical, ResistanceType.Fire, ResistanceType.Cold,
													ResistanceType.Poison, ResistanceType.Energy };
			MinDamages = new int[5] { 20, 20, 20, 20, 20 };
			MaxDamages = new int[5] { 20, 20, 20, 20, 20 };

			ResistanceTypes = new ResistanceType[5] { ResistanceType.Physical, ResistanceType.Fire, ResistanceType.Cold,
														ResistanceType.Poison, ResistanceType.Energy };
			MinResistances = new int[5] { 25, 25, 25, 25, 25 };
			MaxResistances = new int[5] { 25, 25, 25, 25, 25 };

			DamageMin = 2; DamageMax = 2; HitsMin= 1; HitsMax = 1;
			StrMin = 65; StrMax = 75; DexMin = 40; DexMax = 45; IntMin = 40; IntMax = 50;
		}
开发者ID:kamronbatman,项目名称:DefianceUO-Pre1.10,代码行数:21,代码来源:HiryuEvoSpec.cs

示例11: RaelisDragonStageOne

		public RaelisDragonStageOne()
		{
			EvolutionMessage = "has evolved.";//stage 1 - green
			NextEpThreshold = 25000; EpMinDivisor = 10; EpMaxDivisor = 5; DustMultiplier = 20;
			BaseSoundID = 0xDB;
			BodyValue = 733;
			ControlSlots = 2;
			MinTameSkill = 99.9;
			VirtualArmor = 30;
//			Hue = Evo.Flags.kRandomHueFlag;
//			Hue = 0;

			DamagesTypes = new ResistanceType[1] { ResistanceType.Physical };
			MinDamages = new int[1] { 100 };
			MaxDamages = new int[1] { 100 };

			ResistanceTypes = new ResistanceType[1] { ResistanceType.Physical };
			MinResistances = new int[1] { 15 };
			MaxResistances = new int[1] { 15 };

			DamageMin = 11; DamageMax = 17; HitsMin = 200; HitsMax = 250;
			StrMin = 296; StrMax = 325; DexMin = 56; DexMax = 75; IntMin = 76; IntMax = 96;
		}
开发者ID:greeduomacro,项目名称:dragonknights-uo,代码行数:23,代码来源:DragonEvoSpec.cs

示例12: Aura

 // No Effects
 public static void Aura(Point3D location, Map map, Mobile from, int min, int max, ResistanceType type, int range,
     Poison poison, string text, bool scales, bool allownull)
 {
     Aura(location, map, from, min, max, type, range, poison, text, scales, allownull, false, 0, 0);
 }
开发者ID:rokann,项目名称:JustUO,代码行数:6,代码来源:Abilities.cs

示例13: SetResistBonus

        public int SetResistBonus(ResistanceType resist)
        {
            switch (resist)
            {
                case ResistanceType.Physical: return PhysicalResistance;
                case ResistanceType.Fire: return FireResistance;
                case ResistanceType.Cold: return ColdResistance;
                case ResistanceType.Poison: return PoisonResistance;
                case ResistanceType.Energy: return EnergyResistance;
            }

            return 0;
        }
开发者ID:Ravenwolfe,项目名称:ServUO,代码行数:13,代码来源:BaseJewel.cs

示例14: GetMaxResistance

		public override int GetMaxResistance(ResistanceType type)
		{
			if (IsStaff())
			{
				return int.MaxValue;
			}

			int max = base.GetMaxResistance(type);

			if (type != ResistanceType.Physical && 60 < max && CurseSpell.UnderEffect(this))
			{
				max = 60;
			}

			if (Core.ML && Race == Race.Elf && type == ResistanceType.Energy)
			{
				max += 5; //Intended to go after the 60 max from curse
			}

			return max;
		}
开发者ID:zerodowned,项目名称:justuo-with-ec-support,代码行数:21,代码来源:PlayerMobile.cs

示例15: SwitchDamageEntry

 public SwitchDamageEntry( PlayerMobile owner, BardSpellbook book, ResistanceType element )
     : base(GetElementalDamageCliloc( element ))
 {
     m_Owner = owner;
     m_Book = book;
     m_Element = element;
 }
开发者ID:Ravenwolfe,项目名称:xrunuo,代码行数:7,代码来源:BardSpellbook.cs


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