瀏覽代碼

[ts][phaser] Fix SkinsAndAnimationBoundsProvider.

Davide Tantillo 7 月之前
父節點
當前提交
8f84f8daa5
共有 1 個文件被更改,包括 2 次插入2 次删除
  1. 2 2
      spine-ts/spine-phaser/src/SpineGameObject.ts

+ 2 - 2
spine-ts/spine-phaser/src/SpineGameObject.ts

@@ -149,8 +149,8 @@ export class SkinsAndAnimationBoundsProvider
 				const bounds = skeleton.getBoundsRect();
 				minX = Math.min(minX, bounds.x);
 				minY = Math.min(minY, bounds.y);
-				maxX = Math.max(maxX, minX + bounds.width);
-				maxY = Math.max(maxY, minY + bounds.height);
+				maxX = Math.max(maxX, bounds.x + bounds.width);
+				maxY = Math.max(maxY, bounds.y + bounds.height);
 			}
 			const bounds = {
 				x: minX,