Made FieldLoader thread-safe, and cache some expensive reflection calls.

This commit is contained in:
RoosterDragon
2015-04-09 22:26:33 +01:00
parent 109ccbb0b0
commit d2d2f4a838
2 changed files with 32 additions and 17 deletions

View File

@@ -116,7 +116,6 @@ namespace OpenRA
if (!Manifest.Translations.Any())
{
Languages = new string[0];
FieldLoader.Translations = new Dictionary<string, string>();
return;
}
@@ -144,7 +143,7 @@ namespace OpenRA
translations.Add(tkv.Key, tkv.Value);
}
FieldLoader.Translations = translations;
FieldLoader.SetTranslations(translations);
}
public Map PrepareMap(string uid)