Namespace: DeltaEngine.Input.Tests
Assembly: DeltaEngine.Input.Tests (in DeltaEngine.Input.Tests.dll) Version: 1.1.1.0 (1.1.1)
Assembly: DeltaEngine.Input.Tests (in DeltaEngine.Input.Tests.dll) Version: 1.1.1.0 (1.1.1)
Syntax
Examples
[Test] public void MovingARectangleWithTheArrows() { var rect = new FilledRect(new Rectangle(0.4f, 0.4f, 0.2f, 0.2f), Color.Green); new Command(Command.MoveDown, () => rect.DrawArea = rect.DrawArea.Move(0, 0.01f)); new Command(Command.MoveUp, () => rect.DrawArea = rect.DrawArea.Move(0, -0.01f)); new Command(Command.MoveLeft, () => rect.DrawArea = rect.DrawArea.Move(-0.01f, 0)); new Command(Command.MoveRight, () => rect.DrawArea = rect.DrawArea.Move(0.01f, 0)); }
See Also