mirror of https://github.com/axmolengine/axmol.git
add animate support new
This commit is contained in:
parent
e25c4f88ae
commit
d51f0b1f05
|
@ -374,7 +374,7 @@ var Camera3DTest = (function(){
|
|||
if(playAnimation){
|
||||
var animation = new jsb.Animation3D(file, "Take 001");
|
||||
if(animation){
|
||||
var animate = jsb.Animate3D.create(animation);
|
||||
var animate = new jsb.Animate3D(animation);
|
||||
sprite.runAction(cc.repeatForever(animate));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -184,7 +184,7 @@ var LightTest = LightTestDemo.extend({
|
|||
orc.getAttachNode("Bip001 R Hand").addChild(axe);
|
||||
var animation = new jsb.Animation3D("Sprite3DTest/orc.c3b");
|
||||
if(animation){
|
||||
var animate = jsb.Animate3D.create(animation);
|
||||
var animate = new jsb.Animate3D(animation);
|
||||
orc.runAction(cc.repeatForever(animate));
|
||||
}
|
||||
this.addChild(orc);
|
||||
|
|
|
@ -158,7 +158,7 @@ var NavMeshBaseTestDemo = NavMeshTestScene.extend({
|
|||
physicsScene.addChild(node);
|
||||
|
||||
var animation = new jsb.Animation3D(filePath);
|
||||
var animate = jsb.Animate3D.create(animation);
|
||||
var animate = new jsb.Animate3D(animation);
|
||||
|
||||
if (animate){
|
||||
agentNode.runAction(new cc.RepeatForever(animate));
|
||||
|
|
|
@ -379,7 +379,7 @@ var Particle3DWithSprite3DDemo = Particle3DTestDemo.extend({
|
|||
sprite.setCameraMask(2);
|
||||
var animation = new jsb.Animation3D(c3bfileName);
|
||||
if(animation){
|
||||
var animate = jsb.Animate3D.create(animation);
|
||||
var animate = new jsb.Animate3D(animation);
|
||||
sprite.runAction(cc.repeatForever(animate));
|
||||
}
|
||||
|
||||
|
|
|
@ -308,7 +308,7 @@ var Sprite3DWithSkinTest = Sprite3DTestDemo.extend({
|
|||
|
||||
var animation = new jsb.Animation3D("Sprite3DTest/orc.c3b");
|
||||
if(animation){
|
||||
var animate = jsb.Animate3D.create(animation);
|
||||
var animate = new jsb.Animate3D(animation);
|
||||
var inverse = Math.random() < 0.33 ? true : false;
|
||||
|
||||
var rand2 = Math.random();
|
||||
|
@ -373,12 +373,12 @@ var Animate3DTest = (function(){
|
|||
|
||||
var animation = new jsb.Animation3D("Sprite3DTest/tortoise.c3b");
|
||||
if(animation){
|
||||
var animate = jsb.Animate3D.create(animation, 0, 1.933);
|
||||
var animate = new jsb.Animate3D(animation, 0, 1.933);
|
||||
this._swim = new cc.RepeatForever(animate);
|
||||
sprite.runAction(this._swim);
|
||||
|
||||
this._swim.retain();
|
||||
this._hurt = jsb.Animate3D.create(animation, 1.933, 2.8);
|
||||
this._hurt = new jsb.Animate3D(animation, 1.933, 2.8);
|
||||
this._hurt.retain();
|
||||
|
||||
this._state = State.SWIMMING;
|
||||
|
@ -486,7 +486,7 @@ var AttachmentTest = Sprite3DTestDemo.extend({
|
|||
|
||||
var animation = new jsb.Animation3D("Sprite3DTest/orc.c3b");
|
||||
if(animation){
|
||||
var animate = jsb.Animate3D.create(animation);
|
||||
var animate = new jsb.Animate3D(animation);
|
||||
sprite.runAction(cc.repeatForever(animate));
|
||||
}
|
||||
|
||||
|
@ -568,7 +568,7 @@ var Sprite3DReskinTest = (function(){
|
|||
sprite.setPosition(cc.p(position.x, position.y - 60));
|
||||
var animation = new jsb.Animation3D("Sprite3DTest/ReskinGirl.c3b");
|
||||
if(animation){
|
||||
var animate = jsb.Animate3D.create(animation);
|
||||
var animate = new jsb.Animate3D(animation);
|
||||
sprite.runAction(cc.repeatForever(animate));
|
||||
}
|
||||
this._sprite = sprite;
|
||||
|
@ -702,7 +702,7 @@ var Sprite3DWithOBBPerformanceTest = Sprite3DTestDemo.extend({
|
|||
this._sprite = sprite;
|
||||
var animation = new jsb.Animation3D("Sprite3DTest/tortoise.c3b");
|
||||
if(animation){
|
||||
var animate = jsb.Animate3D.create(animation);
|
||||
var animate = new jsb.Animate3D(animation);
|
||||
sprite.runAction(cc.repeatForever(animate));
|
||||
}
|
||||
|
||||
|
@ -812,7 +812,7 @@ var Sprite3DMirrorTest = Sprite3DTestDemo.extend({
|
|||
|
||||
var animation = new jsb.Animation3D(fileName);
|
||||
if(animation){
|
||||
var animate = jsb.Animate3D.create(animation);
|
||||
var animate = new jsb.Animate3D(animation);
|
||||
sprite.runAction(cc.repeatForever(animate));
|
||||
}
|
||||
|
||||
|
@ -831,7 +831,7 @@ var Sprite3DMirrorTest = Sprite3DTestDemo.extend({
|
|||
|
||||
var animation = new jsb.Animation3D(fileName);
|
||||
if(animation){
|
||||
var animate = jsb.Animate3D.create(animation);
|
||||
var animate = new jsb.Animate3D(animation);
|
||||
sprite.runAction(cc.repeatForever(animate));
|
||||
}
|
||||
}
|
||||
|
@ -856,7 +856,7 @@ var QuaternionTest = Sprite3DTestDemo.extend({
|
|||
this._sprite = sprite;
|
||||
var animation = new jsb.Animation3D("Sprite3DTest/tortoise.c3b");
|
||||
if(animation){
|
||||
var animate = jsb.Animate3D.create(animation, 0, 1.933);
|
||||
var animate = new jsb.Animate3D(animation, 0, 1.933);
|
||||
sprite.runAction(cc.repeatForever(animate));
|
||||
}
|
||||
|
||||
|
@ -939,7 +939,7 @@ var UseCaseSprite3D1 = Sprite3DTestDemo.extend({
|
|||
sprite.setScale(0.15);
|
||||
var animation = new jsb.Animation3D("Sprite3DTest/girl.c3b");
|
||||
if(animation){
|
||||
var animate = jsb.Animate3D.create(animation);
|
||||
var animate = new jsb.Animate3D(animation);
|
||||
sprite.runAction(cc.repeatForever(animate));
|
||||
}
|
||||
|
||||
|
@ -1008,7 +1008,7 @@ var UseCaseSprite3D2 = Sprite3DTestDemo.extend({
|
|||
sprite.setScale(0.5);
|
||||
var animation = new jsb.Animation3D("Sprite3DTest/girl.c3b");
|
||||
if(animation){
|
||||
var animate = jsb.Animate3D.create(animation);
|
||||
var animate = new jsb.Animate3D(animation);
|
||||
sprite.runAction(cc.repeatForever(animate));
|
||||
}
|
||||
sprite.setPosition(s.width/4, s.height/4);
|
||||
|
@ -1141,7 +1141,7 @@ var Sprite3DWithSkinOutlineTest = Sprite3DTestDemo.extend({
|
|||
|
||||
var animation = new jsb.Animation3D("Sprite3DTest/orc.c3b");
|
||||
if(animation){
|
||||
var animate = jsb.Animate3D.create(animation);
|
||||
var animate = new jsb.Animate3D(animation);
|
||||
var inverse = Math.random() < 0.33 ? true : false;
|
||||
|
||||
var rand2 = Math.random();
|
||||
|
|
|
@ -334,7 +334,7 @@ var TerrainWalkThru = (function(){
|
|||
|
||||
var animation = new jsb.Animation3D("Sprite3DTest/girl.c3b", "Take 001");
|
||||
if(animation){
|
||||
var animate = jsb.Animate3D.create(animation);
|
||||
var animate = new jsb.Animate3D(animation);
|
||||
this._player.runAction(cc.repeatForever(animate));
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue