mirror of
https://github.com/cocos/cocos4.git
synced 2026-12-03 09:32:38 +08:00
Fix tmx object group x, y parse issue (#3108)
This commit is contained in:
@@ -582,7 +582,7 @@ var Sprite = cc.Class({
|
||||
}
|
||||
},
|
||||
|
||||
_onTextureLoaded: function (event) {
|
||||
_onTextureLoaded: function () {
|
||||
if (!this.isValid) {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -867,8 +867,8 @@ cc.TMXMapInfo.prototype = {
|
||||
objectProp["width"] = parseFloat(selObj.getAttribute('width')) || 0;
|
||||
objectProp["height"] = parseFloat(selObj.getAttribute('height')) || 0;
|
||||
|
||||
objectProp["x"] = (selObj.getAttribute('x') || 0);
|
||||
objectProp["y"] = (selObj.getAttribute('y') || 0);
|
||||
objectProp["x"] = parseFloat(selObj.getAttribute('x')) || 0;
|
||||
objectProp["y"] = parseFloat(selObj.getAttribute('y')) || 0;
|
||||
|
||||
objectProp["rotation"] = parseFloat(selObj.getAttribute('rotation')) || 0;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user