Don't serialize the technology modifications cache. Fixes #1384.

This was SVN commit r11761.
This commit is contained in:
quantumstate
2012-05-05 21:21:36 +00:00
parent 490182ddd0
commit c4efc223ed
@@ -2,6 +2,21 @@ function TechnologyManager() {}
TechnologyManager.prototype.Schema =
"<a:component type='system'/><empty/>";
TechnologyManager.prototype.Serialize = function()
{
// The modifications cache will be affected by property reads from the GUI and other places so we shouldn't
// serialize it.
var ret = {};
for (i in this)
{
if (this.hasOwnProperty(i))
ret[i] = this[i];
}
ret.modificationCache = {};
return ret;
};
TechnologyManager.prototype.Init = function ()
{