From bcd7f38fa7900bd033aafe071bb6473e18510ec4 Mon Sep 17 00:00:00 2001 From: ancientmarinerdev Date: Mon, 20 Mar 2023 13:29:25 +0000 Subject: [PATCH] Use new style vectors --- mods/ENTITIES/mcl_minecarts/init.lua | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/mods/ENTITIES/mcl_minecarts/init.lua b/mods/ENTITIES/mcl_minecarts/init.lua index ee3dce438..9c0199a4c 100644 --- a/mods/ENTITIES/mcl_minecarts/init.lua +++ b/mods/ENTITIES/mcl_minecarts/init.lua @@ -179,6 +179,8 @@ local function register_entity(entity_id, mesh, textures, drop, on_rightclick, o cart.on_activate_by_rail = on_activate_by_rail + local passenger_attach_position = vector.new(0, -1.75, 0) + function cart:on_step(dtime) local ctrl, player = nil, nil if self._driver then @@ -224,7 +226,7 @@ local function register_entity(entity_id, mesh, textures, drop, on_rightclick, o local entity = mob:get_luaentity() if entity and entity.is_mob then self._passenger = entity - mob:set_attach(self.object, "", {x=0, y=-1.75, z=0}, {x=0, y=0, z=0}) + mob:set_attach(self.object, "", passenger_attach_position, vector.zero()) break end end