Browse Source

change toString to toText

ncannasse 11 năm trước cách đây
mục cha
commit
327b2fc7b5
2 tập tin đã thay đổi với 7 bổ sung2 xóa
  1. 2 2
      hxd/res/Any.hx
  2. 5 0
      hxd/res/Resource.hx

+ 2 - 2
hxd/res/Any.hx

@@ -43,10 +43,10 @@ class Any extends Resource {
 		return loader.loadImage(entry.path).toTile();
 	}
 	
-	public function toString() {
+	public function toText() {
 		return entry.getBytes().toString();
 	}
-
+	
 	public function toImage() {
 		return loader.loadImage(entry.path);
 	}

+ 5 - 0
hxd/res/Resource.hx

@@ -13,4 +13,9 @@ class Resource {
 		return entry.name;
 	}
 	
+	function toString() {
+		return entry.path;
+	}
+
+	
 }