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.IsTileInteractable(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 InteractWithOnlyInteractableTiles() { var level = new Level(new Size(2, 2)); level.RenderIn3D = true; level.SetTile(new Vector2D(0, 0), LevelTileType.Blocked); level.SetTile(new Vector2D(1, 0), LevelTileType.ExitPoint); level.SetTile(new Vector2D(0, 1), LevelTileType.SpawnPoint); level.SetTile(new Vector2D(1, 1), LevelTileType.Placeable); Assert.IsFalse(level.IsTileInteractable(new Vector2D(0, 0))); Assert.IsFalse(level.IsTileInteractable(new Vector2D(1, 0))); Assert.IsFalse(level.IsTileInteractable(new Vector2D(0, 1))); Assert.IsTrue(level.IsTileInteractable(new Vector2D(1, 1))); Assert.IsTrue(level.IsTileInteractable(new Vector2D(2, 2))); }
See Also