summaryrefslogtreecommitdiff
path: root/honey/ecs/collision.lua
diff options
context:
space:
mode:
authorsanine-a <sanine.not@pm.me>2023-05-09 16:21:47 -0500
committersanine-a <sanine.not@pm.me>2023-05-09 16:21:47 -0500
commitb24a64fd45d71cfc18fea0e333906baceda031c8 (patch)
treed12a3353da5be1fd2faa7529e59fd5b31a0600b0 /honey/ecs/collision.lua
parent68ef488e8f3bafa0ed68eb8326ac26fd63416891 (diff)
fix bug when getting components no entity has
Diffstat (limited to 'honey/ecs/collision.lua')
-rw-r--r--honey/ecs/collision.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/honey/ecs/collision.lua b/honey/ecs/collision.lua
index 722c256..5c0452b 100644
--- a/honey/ecs/collision.lua
+++ b/honey/ecs/collision.lua
@@ -26,6 +26,9 @@ local function createGeom(self, id, collision)
print(normal, d)
geom = ode.CreatePlane(self.space, normal[1], normal[2], normal[3], d)
end
+
+ ode.GeomSetData(geom, id)
+
collision._geom = geom
collision._gc = honey.util.gc_canary(function()
print("release geom for id"..id)