Engine Integration

Use Bone3 2D Skeletal Animations in Cocos Creator (sp.Skeleton)

Bone3 exports both Spine 3.8 and Spine 4.2 packages (.json / .skel + .atlas + PNG) so Cocos Creator 2.x and 3.x projects can load animations directly in sp.Skeleton components.

Export Spine 3.8 for Cocos Creator 2.x / 3.x legacy runtimes, or Spine 4.2 for Cocos Creator 3.8+.

Compact binary .skel and single-page texture atlases help mini-games stay under strict bundle budgets.

Supports draw order keyframes, skins, mesh deformation, and audio/event triggers.

Step-by-Step Workflow

  1. 1

    Check Your Cocos Creator Spine Runtime Version

    Confirm whether your Cocos Creator version uses Spine 3.8 or Spine 4.2 in Project Settings.

  2. 2

    Export Matching Format from Bone3

    Choose Spine 3.8 or 4.2 in Bone3's Export panel and download the .json/.skel, .atlas, and .png bundle.

  3. 3

    Import into Cocos Creator Assets

    Drag all three files into your assets folder; Cocos Creator recognizes them as a sp.SkeletonData asset automatically.

  4. 4

    Assign to sp.Skeleton and Play in TypeScript

    Attach a sp.Skeleton component to a Node, assign skeletonData, and control animations via setAnimation.

Runtime Integration Example

HeroSpine.tstypescript
import { _decorator, Component, sp } from "cc";
const { ccclass, property } = _decorator;

@ccclass("HeroSpine")
export class HeroSpine extends Component {
  @property(sp.Skeleton)
  skeleton: sp.Skeleton | null = null;

  start() {
    this.skeleton?.setAnimation(0, "idle", true);
  }

  playAttack() {
    this.skeleton?.setAnimation(0, "attack", false);
    this.skeleton?.addAnimation(0, "idle", true, 0);
  }
}

Frequently Asked Questions

Which Spine version should I pick for Cocos Creator?
Cocos Creator 2.x and early 3.x default to Spine 3.8, while Cocos Creator 3.8+ supports Spine 4.2. Bone3 exports both versions cleanly.
Does Bone3 export work in WeChat / TikTok Mini Games built with Cocos?
Yes. Standard Spine 3.8 / 4.2 exports run natively in Cocos Creator's mini-game runtime targets.

Related Guides & Integrations