Settings don't work. Please help.
mod.lua
local modUtil = require "merk_modutil_1"
local LeylandGH7_options = {
LeylandGH7_asset = {
type = "boolean",
default = false,
name = _(TPFMM_LeylandGH7_option),
description = _(TPFMM_LeylandGH7_desc),
image = "res/textures/ui/construction/asset/vehicle/bus/LeylandGH7.tga"
},
}
-----
settings = LeylandGH7_options,
runFn = function(settings)
modUtil.initialize("LeylandGH7", LeylandGH7_options, files)
end
Alles anzeigen
LeylandGH7.con:
local modUtil = require "merk_modutil_1"
local result = {
****
}
modUtil.vehicles.changeMetadata("LeylandGH7", "@(.*/)res/construction/asset/vehicle/bus/leyland.con", result)
local settings = modUtil.userSettings.get("LeylandGH7")
if not settings.LeylandGH7_asset then
result.metadata = {}
end
function data()
return result
end
Alles anzeigen