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

[csharp] Port of commit 687260a: Removed SlotData#path.

Luke Ingram 1 жил өмнө
parent
commit
88aa654a77

+ 1 - 8
spine-csharp/src/SkeletonBinary.cs

@@ -193,14 +193,7 @@ namespace Spine {
 			// Slots.
 			SlotData[] slots = skeletonData.slots.Resize(n = input.ReadInt(true)).Items;
 			for (int i = 0; i < n; i++) {
-				String slotName = input.ReadString(); //, path = null;
-				if (nonessential) {
-					int slash = slotName.LastIndexOf('/');
-					if (slash != -1) {
-						//path = slotName.Substring(0, slash);
-						slotName = slotName.Substring(slash + 1);
-					}
-				}
+				String slotName = input.ReadString();
 
 				BoneData boneData = bones[input.ReadInt(true)];
 				SlotData slotData = new SlotData(i, slotName, boneData);

+ 1 - 8
spine-csharp/src/SkeletonJson.cs

@@ -144,13 +144,7 @@ namespace Spine {
 			// Slots.
 			if (root.ContainsKey("slots")) {
 				foreach (Dictionary<string, Object> slotMap in (List<Object>)root["slots"]) {
-					string slotName = (string)slotMap["name"]; //, path = null;
-					int slash = slotName.LastIndexOf('/');
-					if (slash != -1) {
-						//path = slotName.Substring(0, slash);
-						slotName = slotName.Substring(slash + 1);
-					}
-
+					string slotName = (string)slotMap["name"];
 					string boneName = (string)slotMap["bone"];
 					BoneData boneData = skeletonData.FindBone(boneName);
 					if (boneData == null) throw new Exception("Slot bone not found: " + boneName);
@@ -178,7 +172,6 @@ namespace Spine {
 					else
 						data.blendMode = BlendMode.Normal;
 					//data.visible = slotMap.getBoolean("visible", true);
-					//data.path = path;
 					skeletonData.slots.Add(data);
 				}
 			}

+ 0 - 1
spine-csharp/src/SlotData.cs

@@ -42,7 +42,6 @@ namespace Spine {
 
 		// Nonessential.
 		// bool visible = true;
-		// string path;
 
 		/// <summary>The index of the slot in <see cref="Skeleton.Slots"/>.</summary>
 		public int Index { get { return index; } }