public async Task <IActionResult> Edit(int id, [Bind("Intimidationid,Intimidationprof")] Intimidation intimidation)
        {
            if (id != intimidation.Intimidationid)
            {
                return(NotFound());
            }

            if (ModelState.IsValid)
            {
                try
                {
                    _context.Update(intimidation);
                    await _context.SaveChangesAsync();
                }
                catch (DbUpdateConcurrencyException)
                {
                    if (!IntimidationExists(intimidation.Intimidationid))
                    {
                        return(NotFound());
                    }
                    else
                    {
                        throw;
                    }
                }
                return(RedirectToAction(nameof(Index)));
            }
            return(View(intimidation));
        }
        public void ShouldReturnName()
        {
            //assign
            ISkill actualSkillBase = new Intimidation();
            //act
            ITextObj name = actualSkillBase.Name();

            //assert
            name.Should().Be(new TextObj("Intimidation"));
        }
Exemplo n.º 3
0
        public void Bonus_IntimidationSpecified_ShouldWork()
        {
            SetupCharacter();

            Skills intimidation = new Intimidation(true, true);

            Assert.AreEqual(-5, intimidation.Bonus);
            Assert.IsTrue(intimidation.Proficiency);
            Assert.IsTrue(intimidation.Expertise);
        }
        public void ShouldReturnBaseAttribute()
        {
            //arrange
            ISkill skill = new Intimidation();
            ICharacterAttribute charismaAttribute = new CharismaAttribute();
            //act
            ICharacterAttribute actualAttribute = skill.BaseAttribute();

            //assert
            actualAttribute.Should().Be(charismaAttribute);
        }
        public async Task <IActionResult> Create([Bind("Intimidationid,Intimidationprof")] Intimidation intimidation)
        {
            if (ModelState.IsValid)
            {
                _context.Add(intimidation);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(intimidation));
        }
        public void ShouldReturnBonusOfBaseAttribute()
        {
            //arrange
            CharismaAttribute dexterityAttribute = new CharismaAttribute(new AttributeScore(14));
            ISkill            intimidation       = new Intimidation(dexterityAttribute);
            IAttributeScore   expectedScore      = new AttributeScore(2);
            //act
            IAttributeScore actualScore = intimidation.SkillBonus();

            //assert
            actualScore.Should().Be(expectedScore);
        }
Exemplo n.º 7
0
 public override string ToString()
 {
     return(Acrobatics.ToString() + ' ' +
            AnimalHandling.ToString() + ' ' +
            Arcana.ToString() + ' ' +
            Athletics.ToString() + ' ' +
            Deception.ToString() + ' ' +
            History.ToString() + ' ' +
            Insight.ToString() + ' ' +
            Intimidation.ToString() + ' ' +
            Investigation.ToString() + ' ' +
            Medicine.ToString() + ' ' +
            Nature.ToString() + ' ' +
            Perception.ToString() + ' ' +
            Performance.ToString() + ' ' +
            Persusion.ToString() + ' ' +
            Religion.ToString() + ' ' +
            SleightOfHand.ToString() + ' ' +
            Stealth.ToString() + ' ' +
            Survival.ToString());
 }
Exemplo n.º 8
0
    internal static void CombatRotation()
    {
        WoWUnit Target = ObjectManager.Target;

        if (Target.GetDistance < 10f && !_isBackingUp)
        {
            ToolBox.CheckAutoAttack(Attack);
        }

        if (Target.GetDistance > 10f && !_isBackingUp)
        {
            ReenableAutoshot();
        }

        // Aspect of the viper
        if (AspectViper.KnownSpell && AspectViper.IsSpellUsable && !Me.HaveBuff("Aspect of the Viper") &&
            Me.ManaPercentage < 30)
        {
            AspectViper.Launch();
        }

        // Aspect of the Hawk
        if (AspectHawk.KnownSpell && AspectHawk.IsSpellUsable && !Me.HaveBuff("Aspect of the Hawk") &&
            (Me.ManaPercentage > 90 || Me.HaveBuff("Aspect of the Cheetah")))
        {
            AspectHawk.Launch();
        }

        // Aspect of the Monkey
        if (AspectMonkey.KnownSpell && AspectMonkey.IsSpellUsable && !Me.HaveBuff("Aspect of the Monkey") &&
            !AspectHawk.KnownSpell)
        {
            AspectMonkey.Launch();
        }

        // Disengage
        if (Disengage.KnownSpell && Disengage.IsSpellUsable && ObjectManager.Pet.Target == Me.Target &&
            Target.Target == Me.Guid && Target.GetDistance < 10 && !_isBackingUp)
        {
            Disengage.Launch();
        }

        // Bestial Wrath
        if (BestialWrath.KnownSpell && BestialWrath.IsSpellUsable && Target.GetDistance < 34f &&
            Target.HealthPercent >= 60 && Me.ManaPercentage > 10 && BestialWrath.IsSpellUsable &&
            ((_settings.BestialWrathOnMulti && ObjectManager.GetUnitAttackPlayer().Count > 1) || !_settings.BestialWrathOnMulti))
        {
            BestialWrath.Launch();
        }

        // Rapid Fire
        if (RapidFire.KnownSpell && RapidFire.IsSpellUsable && Target.GetDistance < 34f &&
            Target.HealthPercent >= 80.0 &&
            ((_settings.RapidFireOnMulti && ObjectManager.GetUnitAttackPlayer().Count > 1) || !_settings.RapidFireOnMulti))
        {
            RapidFire.Launch();
        }

        // Kill Command
        if (KillCommand.KnownSpell && KillCommand.IsSpellUsable)
        {
            KillCommand.Launch();
        }

        // Raptor Strike
        if (RaptorStrike.KnownSpell && RaptorStrike.IsSpellUsable && Target.GetDistance < 6f && !RaptorStrikeOn())
        {
            RaptorStrike.Launch();
        }

        // Mongoose Bite
        if (MongooseBite.KnownSpell && MongooseBite.IsSpellUsable && Target.GetDistance < 6f)
        {
            MongooseBite.Launch();
        }

        // Feign Death
        if (FeignDeath.KnownSpell && FeignDeath.IsSpellUsable && Me.HealthPercent < 20)
        {
            FeignDeath.Launch();
            Fight.StopFight();
        }

        // Freezing Trap
        if (FreezingTrap.KnownSpell && FreezingTrap.IsSpellUsable && ObjectManager.Pet.HaveBuff("Mend Pet") &&
            ObjectManager.GetUnitAttackPlayer().Count > 1 && _settings.UseFreezingTrap)
        {
            FreezingTrap.Launch();
        }

        // Mend Pet
        if (ObjectManager.Pet.IsValid && MendPet.KnownSpell && MendPet.IsSpellUsable && ObjectManager.Pet.HealthPercent <= 30.0 &&
            !ObjectManager.Pet.HaveBuff("Mend Pet"))
        {
            MendPet.Launch();
        }

        // Hunter's Mark
        if (HuntersMark.KnownSpell && HuntersMark.IsSpellUsable && ObjectManager.Pet.IsValid && !HuntersMark.TargetHaveBuff &&
            Target.GetDistance > 13f && Target.IsAlive)
        {
            HuntersMark.Launch();
        }

        // Steady Shot
        if (SteadyShot.KnownSpell && SteadyShot.IsSpellUsable && Me.ManaPercentage > 30 && SteadyShot.IsDistanceGood && !_isBackingUp)
        {
            SteadyShot.Launch();
            Thread.Sleep(_steadyShotSleep);
        }

        // Serpent Sting
        if (SerpentSting.KnownSpell && SerpentSting.IsSpellUsable && !Target.HaveBuff("Serpent Sting") &&
            Target.GetDistance < 34f && ToolBox.CanBleed(Me.TargetObject) &&
            Target.HealthPercent >= 80 && Me.ManaPercentage > 50u && !SteadyShot.KnownSpell &&
            Target.GetDistance > 13f)
        {
            SerpentSting.Launch();
        }

        // Intimidation
        if (Intimidation.KnownSpell && Intimidation.IsSpellUsable && Target.GetDistance < 34f &&
            Target.GetDistance > 10f && Target.HealthPercent >= 20 && Me.ManaPercentage > 10 &&
            Intimidation.IsSpellUsable)
        {
            Intimidation.Launch();
        }

        // Arcane Shot
        if (ArcaneShot.KnownSpell && ArcaneShot.IsSpellUsable && Target.GetDistance < 34f &&
            Target.HealthPercent >= 30 && Me.ManaPercentage > 80 &&
            !SteadyShot.KnownSpell)
        {
            ArcaneShot.Launch();
        }
    }