changeset 421:b622937ac879

Fixes #362: Files fail to complete loading in GTK# UI (IBDev) * Change GameSystem hashcode to rely on unchanging values
author IBBoard <dev@ibboard.co.uk>
date Wed, 28 Sep 2011 20:33:10 +0100
parents 22561233df69
children 87f4710b7f8c
files API/Objects/GameSystem.cs
diffstat 1 files changed, 1 insertions(+), 13 deletions(-) [+]
line wrap: on
line diff
--- a/API/Objects/GameSystem.cs	Mon Sep 26 20:17:37 2011 +0100
+++ b/API/Objects/GameSystem.cs	Wed Sep 28 20:33:10 2011 +0100
@@ -238,19 +238,7 @@
 
 		public override int GetHashCode()
 		{
-			return ID.GetHashCode() + Name.GetHashCode() + GetCategoryHash() + warnOnError.GetHashCode();
-		}
-
-		private int GetCategoryHash()
-		{
-			int hash = 0;
-
-			foreach (Category cat in RawCategories.Values)
-			{
-				hash += cat.ID.GetHashCode();
-			}
-
-			return hash;
+			return ID.GetHashCode() + Name.GetHashCode();
 		}
 
 		public bool UnitTypeMaxed(UnitType unitType, Army army)