Skip to content

Commit

Permalink
tweaked 'disable inherit scale' check
Browse files Browse the repository at this point in the history
  • Loading branch information
Rich committed Apr 5, 2019
1 parent b024648 commit faf9fbf
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/core/Bone.ts
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,12 @@ namespace pixi_spine.core {
za *= s;
zc *= s;
s = Math.sqrt(za * za + zc * zc);
if (
this.data.transformMode == TransformMode.NoScale
&& (pa * pd - pb * pc < 0) != (Bone.yDown?
(this.skeleton.scaleX < 0 != this.skeleton.scaleY > 0) :
(this.skeleton.scaleX < 0 != this.skeleton.scaleY < 0))
) s = -s;
let r = Math.PI / 2 + Math.atan2(zc, za);
let zb = Math.cos(r) * s;
let zd = Math.sin(r) * s;
Expand Down

0 comments on commit faf9fbf

Please sign in to comment.