Use HashSets for AI

This commit is contained in:
reaperrr
2015-09-06 22:59:49 +02:00
parent aae3c8ef7d
commit 60359cc6f5
2 changed files with 4 additions and 4 deletions

View File

@@ -186,7 +186,7 @@ namespace OpenRA.Mods.Common.AI
ActorInfo GetProducibleBuilding(string commonName, IEnumerable<ActorInfo> buildables, Func<ActorInfo, int> orderBy = null)
{
string[] actors;
HashSet<string> actors;
if (!ai.Info.BuildingCommonNames.TryGetValue(commonName, out actors))
throw new InvalidOperationException("Can't find {0} in the HackyAI BuildingCommonNames definition.".F(commonName));