Don't desync while the world is disposing
This commit is contained in:
@@ -194,7 +194,10 @@ namespace OpenRA
|
||||
finally
|
||||
{
|
||||
inUnsyncedCode = false;
|
||||
if (sync != world.SyncHash())
|
||||
|
||||
// When the world is disposing all actors and effects have been removed
|
||||
// So do not check the hash for a disposing world since it definitively has changed
|
||||
if (!world.Disposing && sync != world.SyncHash())
|
||||
throw new InvalidOperationException("RunUnsynced: sync-changing code may not run here");
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user