public override void OnGotMeleeAttack(Mobile attacker) { base.OnGotMeleeAttack(attacker); double effectChance = .2; SpecialAbilities.EnrageSpecialAbility(effectChance, attacker, this, .2, 20, -1, true, "Your attack enrages the target.", "", "*becomes enraged*"); }
public override void OnGotMeleeAttack(Mobile attacker) { base.OnGotMeleeAttack(attacker); if (Utility.RandomDouble() <= .1) { MassiveCorpseExplosion(this, Location, Location, false, true, Map, 0, 5, 4, 6); } SpecialAbilities.EnrageSpecialAbility(.2, attacker, this, .2, 20, -1, true, "Your attack enrages the target.", "", "*becomes enraged*"); }
public override void OnGaveMeleeAttack(Mobile defender) { base.OnGaveMeleeAttack(defender); if (Utility.RandomDouble() < .1 && DateTime.UtcNow >= m_NextAssaultAllowed) { SpecialAbilities.ExpertiseSpecialAbility(1.0, this, defender, .25, 20, -1, true, "", "", "*begins to strike with fury*"); SpecialAbilities.EnrageSpecialAbility(1.0, null, this, .5, 20, 0, false, "", "", "-1"); m_NextAssaultAllowed = DateTime.UtcNow + NextAssaultDelay; } }
public override void OnGotMeleeAttack(Mobile attacker) { base.OnGotMeleeAttack(attacker); double effectChance = .15; if (Controlled && ControlMaster != null) { if (ControlMaster is PlayerMobile) { if (attacker is PlayerMobile) { effectChance = .02; } else { effectChance = .25; } } } SpecialAbilities.EnrageSpecialAbility(effectChance, attacker, this, .25, 10, -1, true, "Your attack enrages the target.", "", "*becomes enraged*"); }
public void Enrage() { double spawnPercent = (double)intervalCount / (double)totalIntervals; double directionDelay = .25; double initialDelay = 1; double totalDelay = directionDelay + initialDelay; SpecialAbilities.HinderSpecialAbility(1.0, null, this, 1.0, totalDelay, true, 0, false, "", "", "-1"); m_NextEnrageAllowed = DateTime.UtcNow + NextEnrageDelay; m_NextAbilityAllowed = DateTime.UtcNow + NextAbilityDelay + TimeSpan.FromSeconds(totalDelay); AbilityInProgress = true; Timer.DelayCall(TimeSpan.FromSeconds(totalDelay), delegate { if (!SpecialAbilities.Exists(this)) { return; } AbilityInProgress = false; }); Effects.PlaySound(Location, Map, 0x4d7); PublicOverheadMessage(MessageType.Regular, 0, false, "*enters a fowl mood*"); Point3D location = Location; Map map = Map; PlaySound(GetAngerSound()); Animate(16, 8, 1, true, false, 0); Timer.DelayCall(TimeSpan.FromSeconds(directionDelay), delegate { if (!SpecialAbilities.Exists(this)) { return; } PlaySound(0x46A); FeatherExplosion(Location, Map, 20); SpecialAbilities.FrenzySpecialAbility(1.0, this, null, 1.0, EnrageDuration.TotalSeconds, 0, false, "", "", ""); SpecialAbilities.EnrageSpecialAbility(1.0, null, this, .5, EnrageDuration.TotalSeconds, 0, false, "", "", ""); Hue = EnragedHue; ActiveSpeed = .25; PassiveSpeed = .25; CurrentSpeed = .25; Timer.DelayCall(EnrageDuration, delegate { if (!SpecialAbilities.Exists(this)) { return; } Hue = NormalHue; ActiveSpeed = .35; PassiveSpeed = .35; CurrentSpeed = .35; }); }); }