summaryrefslogtreecommitdiff
path: root/ecs
diff options
context:
space:
mode:
authorewy <ewy0@protonmail.com>2026-08-13 13:59:25 +0200
committerewy <ewy0@protonmail.com>2026-08-13 14:03:36 +0200
commit06dd690345a02ad5f158138b2d6597220b716e38 (patch)
treed2ee623052dbbd215924f95c7d834988d891f89b /ecs
parent83b6f3af3ff4195801c0973a10c1519958d4fe71 (diff)
add stuff
Diffstat (limited to 'ecs')
-rw-r--r--ecs/event.go6
-rw-r--r--ecs/gameobject.go16
2 files changed, 22 insertions, 0 deletions
diff --git a/ecs/event.go b/ecs/event.go
new file mode 100644
index 0000000..00904d9
--- /dev/null
+++ b/ecs/event.go
@@ -0,0 +1,6 @@
+package ecs
+
+type Event struct {
+ // Delta is time between events in ms
+ Delta uint64
+}
diff --git a/ecs/gameobject.go b/ecs/gameobject.go
new file mode 100644
index 0000000..a2718c3
--- /dev/null
+++ b/ecs/gameobject.go
@@ -0,0 +1,16 @@
+package ecs
+
+import "github.com/Zyko0/go-sdl3/sdl"
+
+type GameObject struct {
+ Position sdl.FPoint
+ Children []IsGameObject
+}
+
+func (g *GameObject) GO() *GameObject {
+ return g
+}
+
+type IsGameObject interface {
+ GO() *GameObject
+}