mirror of https://github.com/axmolengine/axmol.git
Sync timelineParser and fix issue
This commit is contained in:
parent
54330576e6
commit
05bb775438
|
@ -112,12 +112,16 @@
|
|||
node.setTag(json["Tag"] || 0);
|
||||
|
||||
var actionTag = json["ActionTag"] || 0;
|
||||
var extensionData = new ccs.ObjectExtensionData();
|
||||
var extensionData = new ccs.ComExtensionData();
|
||||
var customProperty = json["UserData"];
|
||||
if(customProperty !== undefined)
|
||||
extensionData.setCustomProperty(customProperty);
|
||||
extensionData.setActionTag(actionTag);
|
||||
node.setUserObject(extensionData);
|
||||
if (node.getComponent("ComExtensionData"))
|
||||
{
|
||||
node.removeComponent("ComExtensionData");
|
||||
}
|
||||
node.addComponent(extensionData);
|
||||
|
||||
node.setCascadeColorEnabled(true);
|
||||
node.setCascadeOpacityEnabled(true);
|
||||
|
@ -284,12 +288,16 @@
|
|||
|
||||
var actionTag = json["ActionTag"] || 0;
|
||||
widget.setActionTag(actionTag);
|
||||
var extensionData = new ccs.ObjectExtensionData();
|
||||
var extensionData = new ccs.ComExtensionData();
|
||||
var customProperty = json["UserData"];
|
||||
if(customProperty !== undefined)
|
||||
extensionData.setCustomProperty(customProperty);
|
||||
extensionData.setActionTag(actionTag);
|
||||
widget.setUserObject(extensionData);
|
||||
if (widget.getComponent("ComExtensionData"))
|
||||
{
|
||||
widget.removeComponent("ComExtensionData");
|
||||
}
|
||||
widget.addComponent(extensionData);
|
||||
|
||||
var rotationSkewX = json["RotationSkewX"];
|
||||
if (rotationSkewX)
|
||||
|
@ -1291,6 +1299,28 @@
|
|||
return node;
|
||||
};
|
||||
|
||||
parser.initBoneNode = function(json, resourcePath){
|
||||
|
||||
var node = new ccs.BoneNode();
|
||||
|
||||
var length = json["Length"];
|
||||
if(length !== undefined)
|
||||
node.setDebugDrawLength(length);
|
||||
|
||||
var blendFunc = json["BlendFunc"];
|
||||
if(blendFunc)
|
||||
node.setBlendFunc(new cc.BlendFunc(blendFunc["Src"] || 0, blendFunc["Dst"] || 0));
|
||||
|
||||
parser.generalAttributes(node, json);
|
||||
return node;
|
||||
};
|
||||
|
||||
parser.initSkeletonNode = function(json){
|
||||
var node = new ccs.SkeletonNode();
|
||||
parser.generalAttributes(node, json);
|
||||
return node;
|
||||
};
|
||||
|
||||
var loadedPlist = {};
|
||||
var loadTexture = function(json, resourcePath, cb){
|
||||
if(json != null){
|
||||
|
@ -1571,6 +1601,8 @@
|
|||
{name: "GameMapObjectData", handle: parser.initGameMap},
|
||||
{name: "ProjectNodeObjectData", handle: parser.initProjectNode},
|
||||
{name: "ArmatureNodeObjectData", handle: parser.initArmature},
|
||||
{name: "BoneNodeObjectData", handle: parser.initBoneNode},
|
||||
{name: "SkeletonNodeObjectData", handle: parser.initSkeletonNode},
|
||||
|
||||
{name: "Sprite3DObjectData", handle: parser.initSprite3D},
|
||||
{name: "Particle3DObjectData", handle: parser.initParticle3D},
|
||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue