public InternalTimer(Mobile from, IPoint3D p, Map map, CookableFood cookableFood) : base(TimeSpan.FromSeconds(5.0)) { m_From = from; m_Point = p; m_Map = map; m_CookableFood = cookableFood; }
protected override void OnTarget(Mobile from, object targeted) { if (m_Item.Deleted) { return; } if (CookableFood.IsHeatSource(targeted)) { if (from.BeginAction(typeof(CookableFood))) { from.PlaySound(0x225); m_Item.Consume(); InternalTimer t = new InternalTimer(from, targeted as IPoint3D, from.Map, m_Item); t.Start(); } else { from.SendLocalizedMessage(500119); // You must wait to perform another action } } }
public InternalTarget(CookableFood item) : base(1, false, TargetFlags.None) { m_Item = item; }