2 using System.Collections.Generic;
5 using System.Xml.Serialization;
7 namespace DirectOutput.FX.TimmedFX
29 get {
return _RetriggerBehaviour; }
30 set { _RetriggerBehaviour = value; }
33 private int _DurationMs = 500;
41 public int MinDurationMs
43 get {
return _DurationMs; }
44 set { _DurationMs = value; }
56 public bool Active {
get;
private set; }
58 private Queue<Table.TableElementData> UntriggerData =
new Queue<Table.TableElementData>();
65 public override void Trigger(Table.TableElementData TableElementData)
67 if (TargetEffect != null)
69 Table.TableElementData TED = TableElementData;
75 Table.Pinball.Alarms.RegisterAlarm(MinDurationMs, MinDurationEnd);
84 UntriggerData.Enqueue(TED.Clone());
89 TargetEffect.Trigger(TED);
98 private void MinDurationEnd()
100 while (UntriggerData.Count>0)
102 TargetEffect.Trigger(UntriggerData.Dequeue());
112 public override void Finish()
117 Table.Pinball.Alarms.UnregisterAlarm(MinDurationEnd);