Ejemplo n.º 1
0
        public void TestInvincibleCloneDyingEarly()
        {
            var game  = new Game(200, 200);
            var bagel = new BagelEnemy(BagelType.InvincibleClone, game, game, health: 3);

            bagel.DamageEntity(null, 1);
            Assert.IsFalse(bagel.IsDead);
            bagel.DamageEntity(null, 1);
            Assert.IsTrue(bagel.IsDead);
        }
Ejemplo n.º 2
0
        public void TestCollisionBoxChangingAfterDamage()
        {
            var bagel  = new BagelEnemy(BagelType.Basic, null, null, health: 3);
            var oldCBW = bagel.CollisionBox.Width;
            var oldCBH = bagel.CollisionBox.Height;

            bagel.DamageEntity(null, 1);
            Assert.IsTrue(oldCBW > bagel.CollisionBox.Width);
            Assert.IsTrue(oldCBH > bagel.CollisionBox.Height);
        }