C# Class AStartTest.TileSystem.TileMap

Show file Open project: holtkampw/UH-Sample-XNA-Project Class Usage Examples

Public Methods

Method Description
Draw ( ) : void
GetTileFromPos ( System.Vector3 position ) : Tile

Returns a tile given a Vector3 position

GetTileFromType ( TileType tileType ) : Tile
GetTileNeighbor ( Tile tile, NeighborTile neighborTile ) : Tile

Gets a neigbhoring tile's position

GetWalkableNeighbors ( Tile tile ) : List
GetWalkableNeighbors ( Tile tile, Tile>.Dictionary exclude ) : List
InitializeTileMap ( System.Vector3 position, System.Vector2 numTiles, System.Vector2 tileSize ) : void
IsTilePathsValid ( ) : bool
RemoveTower ( Tile tile ) : void
SetBase ( Base setBase ) : void
SetObject ( Base gameObject, Tile tile ) : void
SetObject ( Tower gameObject, Tile tile ) : void
SetTower ( Tower tower, Tile tile ) : bool
SetTowerForLevelMap ( Tower tower, Tile tile ) : void
UpdateTilePaths ( ) : void

Protected Methods

Method Description
InitializeTiles ( ) : void

Private Methods

Method Description
OnTowerCreated ( ) : void

Method Details

Draw() public static method

public static Draw ( ) : void
return void

GetTileFromPos() public static method

Returns a tile given a Vector3 position
public static GetTileFromPos ( System.Vector3 position ) : Tile
position System.Vector3 The position to investigate
return Tile

GetTileFromType() public static method

public static GetTileFromType ( TileType tileType ) : Tile
tileType TileType
return Tile

GetTileNeighbor() public static method

Gets a neigbhoring tile's position
public static GetTileNeighbor ( Tile tile, NeighborTile neighborTile ) : Tile
tile Tile The start tile
neighborTile NeighborTile The neighbor to examine
return Tile

GetWalkableNeighbors() public static method

public static GetWalkableNeighbors ( Tile tile ) : List
tile Tile
return List

GetWalkableNeighbors() public static method

public static GetWalkableNeighbors ( Tile tile, Tile>.Dictionary exclude ) : List
tile Tile
exclude Tile>.Dictionary
return List

InitializeTileMap() public static method

public static InitializeTileMap ( System.Vector3 position, System.Vector2 numTiles, System.Vector2 tileSize ) : void
position System.Vector3
numTiles System.Vector2
tileSize System.Vector2
return void

InitializeTiles() protected static method

protected static InitializeTiles ( ) : void
return void

IsTilePathsValid() public static method

public static IsTilePathsValid ( ) : bool
return bool

RemoveTower() public static method

public static RemoveTower ( Tile tile ) : void
tile Tile
return void

SetBase() public static method

public static SetBase ( Base setBase ) : void
setBase Base
return void

SetObject() public static method

public static SetObject ( Base gameObject, Tile tile ) : void
gameObject Base
tile Tile
return void

SetObject() public static method

public static SetObject ( Tower gameObject, Tile tile ) : void
gameObject Tower
tile Tile
return void

SetTower() public static method

public static SetTower ( Tower tower, Tile tile ) : bool
tower Tower
tile Tile
return bool

SetTowerForLevelMap() public static method

public static SetTowerForLevelMap ( Tower tower, Tile tile ) : void
tower Tower
tile Tile
return void

UpdateTilePaths() public static method

public static UpdateTilePaths ( ) : void
return void