[libgdx] Fixed loading stepped timelines from JSON.

closes #1902
This commit is contained in:
Nathan Sweet 2021-06-14 22:28:09 -04:00
parent 8e21d09c79
commit 9b37c31cae

View File

@ -1025,7 +1025,7 @@ public class SkeletonJson extends SkeletonLoader {
int readCurve (JsonValue curve, CurveTimeline timeline, int bezier, int frame, int value, float time1, float time2, int readCurve (JsonValue curve, CurveTimeline timeline, int bezier, int frame, int value, float time1, float time2,
float value1, float value2, float scale) { float value1, float value2, float scale) {
if (curve.isString()) { if (curve.isString()) {
if (value != 0) timeline.setStepped(frame); if (curve.asString().equals("stepped")) timeline.setStepped(frame);
return bezier; return bezier;
} }
curve = curve.get(value << 2); curve = curve.get(value << 2);