Skip to content

Commit

Permalink
Load/save bug fix
Browse files Browse the repository at this point in the history
  • Loading branch information
schwiti6190 committed Apr 9, 2024
1 parent 1ad472f commit 6a050f8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scripts/specializations/CpHud.lua
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ function CpHud:onLoad(savegame)
setting:refresh()
end
if savegame == nil or savegame.resetVehicles then return end
CpSettingsUtil.loadFromXmlFile(spec, savegame.xmlFile,
CpSettingsUtil.loadFromXmlFile(spec.hudSettings, savegame.xmlFile,
savegame.key .. CpHud.KEY .. CpHud.SETTINGS_KEY, self)
end

Expand All @@ -227,7 +227,7 @@ end
function CpHud:saveToXMLFile(xmlFile, baseKey, usedModNames)
--- Saves the settings.
local spec = self.spec_cpHud
CpSettingsUtil.saveToXmlFile(spec.settings, xmlFile,
CpSettingsUtil.saveToXmlFile(spec.hudSettings.settings, xmlFile,
baseKey .. CpHud.SETTINGS_KEY, self, nil)
end

Expand Down

0 comments on commit 6a050f8

Please sign in to comment.