Skip to content

Migrate Spine extension to @esotericsoftware/spine-pixi-v7#8595

Open
malec-palec wants to merge 8 commits into
4ian:masterfrom
PlaytikaOSS:feat/spine-pixi-v7
Open

Migrate Spine extension to @esotericsoftware/spine-pixi-v7#8595
malec-palec wants to merge 8 commits into
4ian:masterfrom
PlaytikaOSS:feat/spine-pixi-v7

Conversation

@malec-palec

Copy link
Copy Markdown
Contributor

Replace a third-party pixi-spine@4.0.4 with the official Esoteric Software runtime for PixiJS v7 (@esotericsoftware/spine-pixi-v7@4.2.116).

Changes

  • Dependencies: Swapped pixi-spine@esotericsoftware/spine-pixi-v7 in GDJS and newIDE/app. Added @pixi/* version overrides to prevent duplicate packages.
  • Vendor bundle: Removed pixi-spine/pixi-spine.js. Added the official unmodified IIFE bundle at spine-pixi-v7/spine-pixi-v7.js with a separate spine-pixi-v7-pre.js shim that maps @pixi/* requires to the global PIXI object in browser context.
  • Managers: Rewrote atlas and skeleton managers to use PIXI.Assets for loading/caching. Skeleton and atlas are registered as named aliases consumed by Spine.from().
  • Renderer: Replaced new PIXI.Spine() with spine.Spine.from(). Adapted type references to the new API (Bone, Slot, AnimationStateListener, etc.).
  • IDE: Updated PixiResourcesLoader to load spine data through PIXI.Assets and expose a createSpine() helper. Updated SpineEditor and ObjectSkinNameField accordingly.
  • Version warning: Console warning (runtime) and UI banner (editor) when a Spine resource was exported with a version older than 4.2.

Breaking change

The new runtime only fully supports skeletons exported from Spine 4.2. Older exports (e.g. 4.0) may partially render but mesh deformations won't work due to a JSON schema change (deformattachments).

@malec-palec malec-palec marked this pull request as ready for review June 10, 2026 14:25
@malec-palec malec-palec requested a review from 4ian as a code owner June 10, 2026 14:25

@4ian 4ian left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Made a first pass, looks good overall!

Would be good to replace GDJS/tests/games/capabilities/assets/spineboy.json by a new version?

Comment thread newIDE/app/src/Utils/i18n/getTranslationFunction.js Outdated
Comment thread Extensions/Spine/managers/pixi-spine-atlas-manager.ts Outdated
@malec-palec

Copy link
Copy Markdown
Contributor Author

Would be good to replace GDJS/tests/games/capabilities/assets/spineboy.json by a new version?

Replaced spineboy.json, spineboy.atlas and spineboy.png with the official Spine 4.2 spineboy-pro export (spine: 4.2.22). The 4.2 skeleton dropped the hit animation, so I also removed the now-invalid hit entry from the Spine object config in capabilities.json.

@4ian

4ian commented Jun 12, 2026

Copy link
Copy Markdown
Owner

Thanks! We'll merge this soon

@4ian 4ian added the 🏁PR almost ready: final fixes The PR is almost ready and needs final fixes and/or polishing before merge label Jun 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🏁PR almost ready: final fixes The PR is almost ready and needs final fixes and/or polishing before merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants