summaryrefslogtreecommitdiff
path: root/src/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/main.c b/src/main.c
index 9b79dcf..9a66308 100644
--- a/src/main.c
+++ b/src/main.c
@@ -1,3 +1,4 @@
+#include <stddef.h>
#include <stdlib.h>
#include "level.h"
@@ -35,6 +36,26 @@ int main() {
DrawLine(0, y * gridSize, GetScreenWidth(), y * gridSize, LIGHTGRAY);
}
+ // Drawing points
+ for (int x = 0; x < level->width; x++) {
+ for (int y = 0; y < level->height; y++) {
+ Color color = GRAY;
+
+ for (int i = 0; i < level->height * level->width; i++) {
+ Side *side = level->sides[i];
+ if (side == NULL) continue;
+
+ if ((x == side->a.x && y == side->a.y) ||
+ (x == side->b.x && y == side->b.y)) {
+ color = RED;
+ break;
+ }
+ }
+
+ DrawCircle(x * gridSize, y * gridSize, 4, color);
+ }
+ }
+
EndDrawing();
}