Structure that represents the game map.
More...
Structure that represents the game map.
Programmatical representation of the map grid. Composed of Nodes that represent each tile on the grid.
§ Graph()
Model.Graph.Graph |
( |
int |
x, |
|
|
int |
y |
|
) |
| |
Creates a graph for each tile in the game, using the passed in parameter Width and Height
- Parameters
-
x | Width of the graph. |
y | Height of the graph. |
§ getNode() [1/3]
Node Model.Graph.getNode |
( |
int |
x, |
|
|
int |
y |
|
) |
| |
Returns the node on the graph at the specified position (by nodes).
- Parameters
-
x | X position of the node (by nodes). |
y | Y position of the node (by nodes). |
§ getNode() [2/3]
Node Model.Graph.getNode |
( |
Vector2 |
pixelCoordinates | ) |
|
Returns the node on the graph at the specified position (by pixel coordinates).
- Parameters
-
pixelCoordinates | Pixel coordinates of the node, which contains the X coordinate and Y coordinate. |
§ getNode() [3/3]
Node Model.Graph.getNode |
( |
Tuple< int, int > |
position | ) |
|
Returns the node on the graph at the specified position (by nodes).
- Parameters
-
position | Position of the node, which contains the X position and Y position (by nodes). |
§ setNode()
void Model.Graph.setNode |
( |
Node |
node, |
|
|
int |
x, |
|
|
int |
y |
|
) |
| |
Sets the node at the specified position on the graph to the specified node.
- Parameters
-
node | Node to set. |
x | X position of the node (by nodes). |
y | Y position of the node (by nodes). |
§ Height
Returns the height of the graph (by number of nodes).
§ NumberOfNodes
int Model.Graph.NumberOfNodes |
|
get |
Returns the total number of nodes in the graph.
§ Width
Returns the width of the graph (by number of nodes).
The documentation for this class was generated from the following file:
- C:/Users/Thien Trandinh/Documents/Blaze-Brigade/src/Blaze-Brigade/Blaze_Brigade/Graph.cs