以前3.10时候能正常播放的spine骨骼动画,现在无法播放了,
请问有哪些细节要修改?
PS:3.10修改过SPINE内部一些参数使其支持当时的新的版本SPINE》:3.0.10
查看test里面的案例发现自相矛盾的做法:
在3.10里spine可以这样创建,但是在3.15.1里如果这样做,就会找不到骨骼文件:
// var hero = new sp.SkeletonAnimation(“res/didi_left_side/spine.json”,“res/didi_left_side/spine.atlas”, 0.25);
3.15.1里必须这样写,才能正常运行:
var hero = sp.SkeletonAnimation.createWithJsonFile(“res/didi_left_side/spine.json”,“res/didi_left_side/spine.atlas”, 0.25);
hero.anchorX = 0.5;
hero.anchorY = 0;
hero.setTimeScale(1);
hero.setAnimation(0, "run", true);
hero.x=400;
hero.y=300;
_self.addChild(hero);