Namespace: DeltaEngine.GameLogic
Assembly: DeltaEngine.GameLogic (in DeltaEngine.GameLogic.dll) Version: 1.1.1.0 (1.1.1)
Tests: DeltaEngine.GameLogic.Tests.LevelTests
1 unit tests call DeltaEngine.GameLogic.Level.IsInsideLevelGrid(DeltaEngine.Datatypes.Vector2D)
Assembly: DeltaEngine.GameLogic (in DeltaEngine.GameLogic.dll) Version: 1.1.1.0 (1.1.1)
Syntax
Parameters
- gridPosition
- Type: DeltaEngine.Datatypes Vector2D
Return Value
Type: BooleanRemarks
Examples
[Test, CloseAfterFirstFrame] public void TestIsInsideLevelGrid() { var level = new MockLevel(new Size(3)); Assert.IsTrue(level.IsInsideLevelGrid(new Vector2D(0, 0))); Assert.IsTrue(level.IsInsideLevelGrid(new Vector2D(1, 1))); Assert.IsTrue(level.IsInsideLevelGrid(new Vector2D(3, 3))); Assert.IsFalse(level.IsInsideLevelGrid(new Vector2D(-0.1f, -0.1f))); Assert.IsFalse(level.IsInsideLevelGrid(new Vector2D(3.1f, 3.1f))); }
See Also