public static void DoTaintEffects(Mobile from) { if (TaintTable == null) TaintTable = new List<Mobile>(); if (!TaintTable.Contains(from)) { from.SendLocalizedMessage(1151482); // Your mana has been tainted! TaintTable.Add(from); Timer.DelayCall(TimeSpan.FromSeconds(5), () => { TaintTable.Remove(from); from.SendLocalizedMessage(1151483); // Your mana is no longer corrupted. }); } }
public static bool IsUnderTaintEffects(Mobile from) { return from != null && TaintTable != null && TaintTable.Contains(from); }