feat: expose storage engine compatibility context

This commit is contained in:
MaxTomahawk
2026-08-07 17:14:42 +02:00
parent 05b43ca258
commit af00d6ad14
4 changed files with 19 additions and 5 deletions
+6 -1
View File
@@ -3,6 +3,7 @@
local SaveData = require("src.core.SaveData")
local SaveSerializer = require("src.core.SaveSerializer")
local Version = require("src.core.Version")
local Storage = {}
Storage.__index = Storage
@@ -81,7 +82,11 @@ end
function Storage:context(game)
local scope, code, message = self:_scope(game)
if not scope then return nil, code, message end
return { gameVersion = scope.gameVersion, playthroughId = scope.playthroughId }
return {
engineVersion = Version.engine,
gameVersion = scope.gameVersion,
playthroughId = scope.playthroughId,
}
end
function Storage:_names(game, key, allowEmpty)