Initial commit

This commit is contained in:
2026-04-24 14:22:25 +02:00
commit 91e205869c
5 changed files with 183 additions and 0 deletions

19
infrastructure/node.odin Normal file
View File

@@ -0,0 +1,19 @@
package infrastructure
import rl "vendor:raylib"
Node :: struct {
id: u32,
enabled: bool,
pos: rl.Vector2,
roads: [dynamic]u32,
}
node_init :: proc(new_id: u32, new_pos: rl.Vector2) -> Node {
return {
id = new_id,
enabled = true,
pos = new_pos,
roads = nil,
}
}

13
infrastructure/road.odin Normal file
View File

@@ -0,0 +1,13 @@
package infrastructure
Road :: struct {
id: u32,
nodes: [2]u32,
}
road_init :: proc(new_id: u32, start: u32, end: u32) -> Road {
return {
id = new_id,
nodes = {start, end}
}
}