mirror of
https://github.com/ZDoom/gzdoom.git
synced 2025-04-16 15:32:32 +00:00
- store current time in the save game node when saving a new game
- when overwriting a save force it to reposition itself in the list in case any of its details have changed
This commit is contained in:
parent
902bf03c47
commit
d42e3b0037
1 changed files with 8 additions and 1 deletions
|
@ -183,12 +183,18 @@ void FSavegameManagerBase::NotifyNewSave(const FString &file, const FString &tit
|
|||
#endif
|
||||
{
|
||||
node->SaveTitle = title;
|
||||
node->CreationTime = myasctime();
|
||||
node->bOldVersion = false;
|
||||
node->bMissingWads = false;
|
||||
|
||||
// refresh my game's position on the list (needed if time/name changed)
|
||||
SaveGames.Delete(i);
|
||||
int index = InsertSaveNode(node);
|
||||
|
||||
if (okForQuicksave)
|
||||
{
|
||||
if (quickSaveSlot == nullptr || quickSaveSlot == (FSaveGameNode*)1 || forceQuicksave) quickSaveSlot = node;
|
||||
LastAccessed = LastSaved = i;
|
||||
LastAccessed = LastSaved = index;
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
@ -196,6 +202,7 @@ void FSavegameManagerBase::NotifyNewSave(const FString &file, const FString &tit
|
|||
|
||||
auto node = new FSaveGameNode;
|
||||
node->SaveTitle = title;
|
||||
node->CreationTime = myasctime();
|
||||
node->Filename = file;
|
||||
node->bOldVersion = false;
|
||||
node->bMissingWads = false;
|
||||
|
|
Loading…
Reference in a new issue