Inheritance Hierarchy
DeltaEngine.Entities UpdateBehavior
DeltaEngine.GameLogic TimeTrigger
Namespace: DeltaEngine.GameLogic
Assembly: DeltaEngine.GameLogic (in DeltaEngine.GameLogic.dll) Version: 1.1.1.0 (1.1.1)
Syntax
The TimeTrigger type exposes the following members.
Constructors
Name | Description | |
---|---|---|
TimeTrigger | Initializes a new instance of the TimeTrigger class |
Methods
Name | Description | |
---|---|---|
Update | (Overrides UpdateBehavior Update(IEnumerable Entity ).) |
Remarks
Examples
[Test, CloseAfterFirstFrame] public void TestTimeTrigger() { var actor = new MockActor(Vector3D.Zero, 0.0f); var data = new TimeTrigger.Data(Color.Red, Color.Green, 1.0f); actor.Add(data); actor.Start<TimeTrigger>(); actor.Add(Color.Black); Assert.AreEqual(Color.Black, actor.Get<Color>()); Assert.AreEqual(Color.Red, data.FirstColor); Assert.AreEqual(Color.Green, data.SecondColor); Assert.AreEqual(1.0f, data.Interval); AdvanceTimeAndUpdateEntities(1.1f); Assert.AreEqual(Color.Red, actor.Get<Color>()); }
See Also