HelperLib: rename load() -> loadFile(), add doFile()

This commit is contained in:
Van
2026-11-13 17:06:08 +03:00
parent 2243ed7532
commit 1e91290b02
4 changed files with 52 additions and 26 deletions

View File

@@ -1,20 +1,24 @@
---SMC helper lib
---@class Smc
Smc = {}
---@type boolean
Smc.isAsync = false
local modInfo = Mod.getInfo('smc__system__helper_lib')
local load = modInfo.load
local doFile = modInfo.doFile
-- Independent of SMC methods
load(Smc, 'Lib.activeFormspecs')
load(Smc, 'Lib.globalStep')
load(Smc, 'Lib.inventoryHelpers')
load(Smc, 'Lib.color')
load(Smc, 'Lib.itemStackInventory')
load(Smc, 'Lib.nodeSuperClasses')
load(Smc, 'Lib.getObjectByGUID')
load(Smc, 'Lib.receiveFields')
load(Smc, 'Lib.registeredItems')
load(Smc, 'Lib.loads')
doFile('Lib.activeFormspecs')
doFile('Lib.globalStep')
doFile('Lib.inventoryHelpers')
doFile('Lib.color')
doFile('Lib.itemStackInventory')
doFile('Lib.nodeSuperClasses')
doFile('Lib.getObjectByGUID')
doFile('Lib.receiveFields')
doFile('Lib.registeredItems')
doFile('Lib.requires')
--- Dependent of SMC methods
load(Smc, 'Lib.matchItemDescription')
doFile('Lib.matchItemDescription')