Pārlūkot izejas kodu

[phaser] Fix control bones example.

Mario Zechner 2 gadi atpakaļ
vecāks
revīzija
9dbada6541

BIN
examples/stretchyman/stretchyman-pro.spine


BIN
spine-ts/spine-phaser/example/assets/stretchyman-pro.skel


+ 1 - 1
spine-ts/spine-phaser/example/control-bones-example.html

@@ -21,7 +21,7 @@
 
             create() {
                 const stretchyman = this.add.spine(400, 580, 'stretchyman-data', "stretchyman-atlas");                  
-                stretchyman.animationState.setEmptyAnimation(0, true);
+                stretchyman.animationState.setAnimation(0, "idle", true);
                 stretchyman.updatePose(0);
 
                 const controlBoneNames = ["back-arm-ik-target", "back-leg-ik-target", "front-arm-ik-target", "front-leg-ik-target"];

+ 1 - 1
spine-ts/spine-phaser/src/SpineGameObject.ts

@@ -183,7 +183,7 @@ export class SpineGameObject extends ComputedSizeMixin(DepthMixin(FlipMixin(Scro
 
 	preUpdate (time: number, delta: number) {
 		if (!this.skeleton || !this.animationState) return;
-		this.updatePose();
+		this.updatePose(delta);
 	}
 
 	preDestroy () {