public void OutOfBoundsTile_GetTileOutSideMap_ReturnsTileWithImpassableWall() { TileMap map = new TileMap(new Size(0, 0)); XmasEntity actual = map[0, 1].Entities.First(); Assert.IsInstanceOf<ImpassableWall>(actual); }
public void OutOfBoundsWallChunk_RequestBuildWallOutsideMap_ReturnWallNotBuilt() { TileMap map = new TileMap(new Size(0, 0)); //map.AddChunk<Wall> (new Point (1, 1), new Point (1, 1)); XmasEntity actual = map[1, 1].Entities.First(); Assert.IsInstanceOf<ImpassableWall>(actual); }
public void MisplacedWallChunk_RequestBuildWallOnUnit_ReturnWallNotBuilt() { TileMap map = new TileMap(new Size(0, 0)); map[0, 0].AddEntity(new Player()); //map.AddChunk<Wall> (new Point (0, 0), new Point (0, 0)); Assert.That(map[0, 0].Entities, Has.Some.InstanceOf<Player>()); Assert.That(map[0, 0].Entities, Has.None.InstanceOf<ImpassableWall>()); }
public TileWorld(TileMap map) { this.map = map; }
public TileWorld(Size burstSize) { this.map = new TileMap(burstSize); }