Beispiel #1
0
        public override void Impact(WalkingEntity hit)
        {
            Direction = Vector2.Zero;
            thrower = null;

            if (hit != null && hit.Alive)
            {
                hit.Health -= 300;
                hit.Bleeding = true;
                if (hit.Health <= 0 && hit.GetType() == typeof(Human))
                {
                    Achievements.Achieve("bulletkill");
                    if (firedManually)
                    {
                        Achievements.Achieve("manualbulletkill");
                    }
                    if (hit.Grabbed)
                    {
                        Achievements.Achieve("killwithbulletswhileholding");
                    }
                }
            }

            DeleteMe = true;
        }
Beispiel #2
0
 public virtual void Impact(WalkingEntity hit)
 {
     Direction = Vector2.Zero;
     thrower = null;
     if (hit != null && hit.Alive)
     {
         hit.Health -= 1000;
         if (hit.GetType() == typeof(Human))
         {
             if (!hit.Alive)
             {
                 World.score += score;
                 if (meat)
                 {
                     Achievements.Achieve("killwithmeatcube");
                 }
                 else
                 {
                     Achievements.Achieve("cratekill");
                 }
             }
         }
     }
 }
Beispiel #3
0
        public override void Impact(WalkingEntity hit)
        {
            Direction = Vector2.Zero;
            thrower = null;

            int kills = 0;

            foreach (var ent in World.entities.OfType<WalkingEntity>().Where(e => (e.Position - Position).Length() < 32))
            {
                if (ent.Alive)
                {
                    ent.Health -= 2500;
                    if (!ent.Alive && ent.GetType() == typeof(Human))
                    {
                        kills++;
                    }
                }
            }

            int add = 50 * kills + Math.Max(0, (50 * (kills - 1)));
            World.score += add;
            if (kills >= 1)
            {
                Achievements.Achieve("explosivekill");
            }
            if (kills >= 3)
            {
                Achievements.Achieve("multikill");
            }
            RM.PlaySound("explosion");
            DeleteMe = true;
        }