本文整理汇总了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;
}
示例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;
}
示例3:
public float this[ResistanceType type]
{
get
{
return resistanceMods[(int)type];
}
set
{
resistanceMods[(int)type] = value;
}
}
示例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;
}
示例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;
}
示例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;
}
示例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;
}
示例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;
}
示例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;
}
示例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;
}
示例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;
}
示例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);
}
示例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;
}
示例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;
}
示例15: SwitchDamageEntry
public SwitchDamageEntry( PlayerMobile owner, BardSpellbook book, ResistanceType element )
: base(GetElementalDamageCliloc( element ))
{
m_Owner = owner;
m_Book = book;
m_Element = element;
}