Эх сурвалжийг харах

[libgdx] Simpler hashcode.

NathanSweet 6 жил өмнө
parent
commit
42e5222cbf

+ 1 - 1
spine-libgdx/spine-libgdx/src/com/esotericsoftware/spine/Skin.java

@@ -127,7 +127,7 @@ public class Skin {
 			if (name == null) throw new IllegalArgumentException("name cannot be null.");
 			if (name == null) throw new IllegalArgumentException("name cannot be null.");
 			this.slotIndex = slotIndex;
 			this.slotIndex = slotIndex;
 			this.name = name;
 			this.name = name;
-			hashCode = 31 * (31 + name.hashCode()) + slotIndex;
+			hashCode = name.hashCode() + slotIndex * 37;
 		}
 		}
 
 
 		public int hashCode () {
 		public int hashCode () {