Fix #7925: Reset temporary saveload data at the start of loading a savegame instead of at the end.
Otherwise temporary data may be passed from an aborted load action to the next load action.
This commit is contained in:

committed by
Niels Martin Hansen

parent
41163331aa
commit
a4be4514c9
@@ -12,6 +12,7 @@
|
||||
#include "../tunnelbridge_map.h"
|
||||
|
||||
#include "saveload.h"
|
||||
#include "saveload_internal.h"
|
||||
|
||||
#include "../safeguards.h"
|
||||
|
||||
@@ -79,6 +80,11 @@ void AfterLoadLabelMaps()
|
||||
}
|
||||
}
|
||||
|
||||
ResetLabelMaps();
|
||||
}
|
||||
|
||||
void ResetLabelMaps()
|
||||
{
|
||||
_railtype_list.clear();
|
||||
}
|
||||
|
||||
@@ -106,7 +112,7 @@ static void Save_RAIL()
|
||||
|
||||
static void Load_RAIL()
|
||||
{
|
||||
_railtype_list.clear();
|
||||
ResetLabelMaps();
|
||||
|
||||
LabelObject lo;
|
||||
|
||||
|
Reference in New Issue
Block a user