1
0
forked from 0ad/0ad

reset the trigger script when changing map, fix #2793

This was SVN commit r15750.
This commit is contained in:
mimo 2014-09-14 16:52:33 +00:00
parent 4f7a935f44
commit 67c3a80c42

View File

@ -868,6 +868,9 @@ function selectMap(name)
if (!name)
return;
// reset the triggerSripts as some maps don't have one
g_GameAttributes.settings.TriggerScripts = undefined;
var mapData = loadMapData(name);
var mapSettings = (mapData && mapData.settings ? deepcopy(mapData.settings) : {});
@ -1335,15 +1338,13 @@ function onGameAttributesChange()
function updateGameAttributes()
{
if (g_IsNetworked)
{
{
Engine.SetNetworkGameAttributes(g_GameAttributes);
if (g_IsController && g_LoadingState >= 2)
sendRegisterGameStanza();
}
else
{
onGameAttributesChange();
}
}
function AIConfigCallback(ai)