From 9fc02be2a0f96d9f87ccf5d4fc1ae4f6977c43fc Mon Sep 17 00:00:00 2001 From: Zenon Seth Date: Tue, 12 Mar 2024 10:29:17 +0000 Subject: [PATCH] Make embedded cables into full block drawtypes for performance --- api/cables.lua | 2 +- registration/machines_api_reg.lua | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/api/cables.lua b/api/cables.lua index 1057342..e031218 100644 --- a/api/cables.lua +++ b/api/cables.lua @@ -39,7 +39,7 @@ function logistica.register_cable(desc, name, customNodeBox, customTiles, custom paramtype = "light", paramtype2 = "facedir", sunlight_propagates = true, - drawtype = "nodebox", + drawtype = cnb.type or "nodebox", node_box = node_box, connects_to = { "group:" .. cable_group, logistica.GROUP_ALL, logistica.GROUP_CABLE_OFF }, on_construct = function(pos) logistica.on_cable_change(pos) end, diff --git a/registration/machines_api_reg.lua b/registration/machines_api_reg.lua index e0bd654..5f150e6 100644 --- a/registration/machines_api_reg.lua +++ b/registration/machines_api_reg.lua @@ -31,6 +31,7 @@ logistica.register_cable("Optic Cable", "optic_cable") -- full-block cable logistica.register_cable("Embedded Optic Cable", "optic_cable_block", { + type = "normal", fixed = { { -0.5, -0.5, -0.5, 0.5, 0.5, 0.5 } },