Track LocalMods as part of monolith

This commit is contained in:
2026-06-08 18:50:16 +03:00
parent 143f2fed7c
commit 1b214b44c2
1287 changed files with 139255 additions and 1 deletions
@@ -0,0 +1,30 @@
if SERVER then return end
local mods = require("mods")
function DisableTextPackage(workshopId)
local targetPackage
for package in ContentPackageManager.EnabledPackages.All do
if tostring(package.UgcId) == workshopId then
targetPackage = package
break
end
end
if targetPackage == nil then
print("Could not find package with workshop id ", workshopId)
return
end
for file in targetPackage.Files do
if LuaUserData.IsTargetType(file, "Barotrauma.TextFile") and string.endsWith(file.Path.Value, "ussian.xml") then
file.UnloadFile()
print("Disabled " .. file.Path.Value .. " in package ", workshopId)
break
end
end
end
for _, id in pairs(mods) do
DisableTextPackage(id)
end