diff options
author | Schark <jordan@schark.online> | 2024-03-18 01:44:32 -0700 |
---|---|---|
committer | Schark <jordan@schark.online> | 2024-03-18 01:44:32 -0700 |
commit | 8e2508626776d1300b351f2326773b5bb0cb528f (patch) | |
tree | ee7daf330a91c8770ed860564c2c2d77fb138fb4 /height-map-display/src/map/square.h | |
parent | 69de9b320ad3c45e0a19845c88ae8323cfb59bf1 (diff) | |
download | gamedev-8e2508626776d1300b351f2326773b5bb0cb528f.tar.gz gamedev-8e2508626776d1300b351f2326773b5bb0cb528f.zip |
Adding selected square functionality and aesthetics
Diffstat (limited to '')
-rw-r--r-- | height-map-display/src/map/square.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/height-map-display/src/map/square.h b/height-map-display/src/map/square.h index 2654eb5..132b43c 100644 --- a/height-map-display/src/map/square.h +++ b/height-map-display/src/map/square.h @@ -1,6 +1,8 @@ #ifndef SQUARE_H #define SQUARE_H +#include <stdbool.h> + #include "node.h" // Include node.h to use Node type. // Define the Terrain_Type enum @@ -17,12 +19,14 @@ typedef struct Square { Node *node_tr; Node *node_bl; Node *node_br; + bool selected; } Square; // Function prototypes -Square* init_square(Node *tl, Node *tr, Node *bl, Node *br, Terrain_Type terrain); +Square* init_square(Node *tl, Node *tr, Node *bl, Node *br, Terrain_Type terrain, bool selected); void change_square_height(Square* square, float diff); void change_square_terrain(Square* square, Terrain_Type terrain); +Square* find_selected_square(Square*** squares, int x, int y); #endif |