mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-03-26 22:49:01 +08:00
[haxe] Fix SkeletonSprite.advanceTime to use the actual delta time.
This commit is contained in:
parent
8f8bf06610
commit
f2f1a8ce46
@ -49,6 +49,6 @@ class Main extends Sprite {
|
|||||||
starlingSingleton.start();
|
starlingSingleton.start();
|
||||||
Starling.current.stage.color = 0x000000;
|
Starling.current.stage.color = 0x000000;
|
||||||
|
|
||||||
SceneManager.getInstance().switchScene(new SequenceExample());
|
SceneManager.getInstance().switchScene(new BasicExample());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -338,13 +338,8 @@ class SkeletonSprite extends DisplayObject implements IAnimatable {
|
|||||||
return _smoothing;
|
return _smoothing;
|
||||||
}
|
}
|
||||||
|
|
||||||
var updated = false;
|
|
||||||
|
|
||||||
public function advanceTime(time:Float):Void {
|
public function advanceTime(time:Float):Void {
|
||||||
if (!updated) {
|
_state.update(time);
|
||||||
// updated = true;
|
|
||||||
_state.update(0.016 * 0.1);
|
|
||||||
}
|
|
||||||
_state.apply(skeleton);
|
_state.apply(skeleton);
|
||||||
skeleton.updateWorldTransform();
|
skeleton.updateWorldTransform();
|
||||||
this.setRequiresRedraw();
|
this.setRequiresRedraw();
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user