mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-02-06 15:24:55 +08:00
Fixes.
This commit is contained in:
parent
8887677cd7
commit
ab15078b3e
@ -43,7 +43,7 @@ public class FfdTimeline extends CurveTimeline {
|
||||
public function FfdTimeline (frameCount:int) {
|
||||
super(frameCount);
|
||||
frames = new Vector.<Number>(frameCount, true);
|
||||
frameVertices = new Vector.<Number>(frameCount, true);
|
||||
frameVertices = new Vector.<Vector.<Number>>(frameCount, true);
|
||||
}
|
||||
|
||||
/** Sets the time and value of the specified keyframe. */
|
||||
|
||||
@ -68,7 +68,7 @@ public dynamic class MeshAttachment extends Attachment {
|
||||
|
||||
public function updateUVs () : void {
|
||||
var width:Number = regionU2 - regionU, height:Number = regionV2 - regionV;
|
||||
var i:int, n:int = uvs.length;
|
||||
var i:int, n:int = regionUVs.length;
|
||||
if (!uvs || uvs.length != n) uvs = new Vector.<Number>(n, true);
|
||||
if (regionRotate) {
|
||||
for (i = 0; i < n; i += 2) {
|
||||
|
||||
@ -69,7 +69,7 @@ public dynamic class SkinnedMeshAttachment extends Attachment {
|
||||
|
||||
public function updateUVs () : void {
|
||||
var width:Number = regionU2 - regionU, height:Number = regionV2 - regionV;
|
||||
var i:int, n:int = uvs.length;
|
||||
var i:int, n:int = regionUVs.length;
|
||||
if (!uvs || uvs.length != n) uvs = new Vector.<Number>(n, true);
|
||||
if (regionRotate) {
|
||||
for (i = 0; i < n; i += 2) {
|
||||
|
||||
@ -70,6 +70,7 @@ public class SkinnedMeshAttachment extends Attachment {
|
||||
}
|
||||
|
||||
public void updateUVs () {
|
||||
float[] regionUVs = this.regionUVs;
|
||||
int verticesLength = regionUVs.length;
|
||||
int worldVerticesLength = verticesLength / 2 * 5;
|
||||
if (worldVertices == null || worldVertices.length != worldVerticesLength) worldVertices = new float[worldVerticesLength];
|
||||
@ -84,7 +85,6 @@ public class SkinnedMeshAttachment extends Attachment {
|
||||
width = region.getU2() - u;
|
||||
height = region.getV2() - v;
|
||||
}
|
||||
float[] regionUVs = this.regionUVs;
|
||||
if (region instanceof AtlasRegion && ((AtlasRegion)region).rotate) {
|
||||
for (int i = 0, w = 3; i < verticesLength; i += 2, w += 5) {
|
||||
worldVertices[w] = u + regionUVs[i + 1] * width;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user