diff options
| -rw-r--r-- | .luacheckrc | 1 | ||||
| -rw-r--r-- | init.lua | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/.luacheckrc b/.luacheckrc index d57e796..a9d7661 100644 --- a/.luacheckrc +++ b/.luacheckrc @@ -6,5 +6,4 @@ globals = { read_globals = { "vector", - "carts", } @@ -122,6 +122,8 @@ for _,mod in ipairs({"vehicle_mash","motorbike","bike","ufos"}) do local obj = self.object local pos = vector.round(obj:get_pos()) local maxradius = tonumber(core.settings:get("cars_despawn.search_radius") or 8) or 8 + local radiusv = vector.new(maxradius,maxradius,maxradius) + core.load_area(pos-radiusv,pos+radiusv) local parked = core.find_node_near(pos,maxradius,"group:parking",true) if not parked then obj:remove() end end |
