working on snapshots
This commit is contained in:
parent
b95a963f07
commit
3167b2f77d
|
@ -26,11 +26,10 @@ stead.restore_snapshot = function (nr)
|
|||
if not ss[nr] then return nil, true end -- nothing todo
|
||||
local i,v
|
||||
|
||||
stead:init();
|
||||
-- game.lifes:zap();
|
||||
gamefile("main.lua", true);
|
||||
stead.pclr();
|
||||
-- if type(init) == 'function' then -- no hooks here!!!
|
||||
-- init();
|
||||
-- end
|
||||
|
||||
local f, err = loadstring(ss[nr]);
|
||||
if not f then return end
|
||||
local i,r = f();
|
||||
|
|
|
@ -1638,8 +1638,6 @@ function gamefile(file, forget)
|
|||
if forget then
|
||||
game._scripts = { }
|
||||
end
|
||||
stead:init();
|
||||
game.lifes:zap();
|
||||
dofile(file);
|
||||
game:ini();
|
||||
if #game._scripts == 0 or file ~= game._scripts[#game._scripts] then
|
||||
|
@ -1647,7 +1645,6 @@ function gamefile(file, forget)
|
|||
stead.table.insert(game._scripts, file);
|
||||
end
|
||||
end
|
||||
return goto(here())
|
||||
end
|
||||
|
||||
function do_savegame(s, h)
|
||||
|
|
Reference in a new issue