[as3] Fix path constraint for when path length is NaN. See #1230.

This commit is contained in:
badlogic 2018-12-17 15:23:24 +01:00
parent 19fdea7d80
commit 9f8003a3b6
4 changed files with 2 additions and 2 deletions

View File

@ -189,7 +189,7 @@ package spine {
var pathLength : Number = lengths[curveCount];
if (percentPosition) position *= pathLength;
if (percentSpacing) {
for (var i : int = 0; i < spacesCount; i++)
for (var i : int = 1; i < spacesCount; i++)
spaces[i] *= pathLength;
}
this._world.length = 8;
@ -305,7 +305,7 @@ package spine {
else
position *= pathLength / path.lengths[curveCount - 1];
if (percentSpacing) {
for (i = 0; i < spacesCount; i++)
for (i = 1; i < spacesCount; i++)
spaces[i] *= pathLength;
}