private static void WardDetected(Obj_AI_Minion Detectedward) { if (Detectedward.IsDead || Detectedward.Health < 1) { return; } var buff = Detectedward.Buffs.Find(b => b.Name == "sharedwardbuff"); var endtime = 0; if (buff != null) { endtime = (int)buff.EndTime; } var newward = new Wards.DetectedWards(Detectedward, Detectedward.ServerPosition, Detectedward.Type(), (int)Game.Time, endtime); if (Detectedwards.All(w => w.Position != newward.Position)) { Detectedwards.Add(newward); } }