Coqfight Spine assets

Every Chikn and Roostr from Coqfight as Spine 4.2 skeletons: bodies, traits and 34 animations, ready to load in any official Spine runtime.

What's included

ChiknRoostr
Body skins2121
Trait skins174224
Animations3434

Both series share the same rig (68 bones, 66 slots) and the same animations. Units are pixels, at 100 px per game unit, with the root bone at the coq's feet.

File URLs

Everything is served from this site with CORS enabled, so you can load it straight from your own page. Replace chikn with roostr for the other series.

URLWhat it is
/v1/chikn/chikn.jsonSkeleton data (bones, slots, skins, animations)
/v1/chikn/chikn.atlasTexture atlas. Each body skin and each trait has its own page.
/v1/chikn/atlas/*.pngAtlas pages, for example atlas/Bullion.png or atlas/trait-chikn_gentlechikn.png
/v1/chikn/images/<Skin>/<Part>.pngThe same art as loose images, for the Spine editor
/v1/chikn/chikn-animations-meta.jsonEach animation's loop flag, plus game-script curves (see Animations)
/v1/traits/traits.jsonTrait catalogue: series, parts, thumbnails and sound effect names
/v1/traits/trait-rules.jsonWhich base part to hide when a trait is shown (see Traits)

Versions

/v1/ never changes in a way that breaks your code. Fixes such as a nudged trait can still land in it. Anything that would break existing code, like renamed skins or slots, goes into /v2/. /latest/ always points at the newest version, if you'd rather take every change.

Quick start (web)

This loads a Chikn with two traits and plays its idle animation on a canvas. It fetches only the atlas pages that this coq uses. See it running in the live example.

<script src="https://cdn.jsdelivr.net/npm/@esotericsoftware/spine-canvas@4.2.120/dist/iife/spine-canvas.min.js"></script>
<canvas id="c" width="600" height="700"></canvas>
<script>
const BASE = '__BASE__';
const HIDES = { 'Tail.Special': 'Tail', 'Front.Leg.Foot.Special': 'Front.Leg.Foot',
                'Back.Leg.Foot.Special': 'Back.Leg.Foot', 'Head.Special': 'Head.Comb' };

async function loadCoq(series, body, traits) {
  const [atlasText, json] = await Promise.all([
    fetch(`${BASE}${series}/${series}.atlas`).then(r => r.text()),
    fetch(`${BASE}${series}/${series}.json`).then(r => r.text()),
  ]);
  const atlas = new spine.TextureAtlas(atlasText);
  const data = new spine.SkeletonJson(new spine.AtlasAttachmentLoader(atlas)).readSkeletonData(json);

  const skin = new spine.Skin('coq');
  skin.addSkin(data.findSkin(body));
  for (const t of traits) skin.addSkin(data.findSkin('trait/' + t));
  for (const [special, base] of Object.entries(HIDES)) {
    const s = data.findSlot(special), b = data.findSlot(base);
    if (s && b && skin.getAttachment(s.index, special)) skin.removeAttachment(b.index, base);
  }

  // Load only the atlas pages this coq needs.
  const pages = new Set();
  for (const e of skin.getAttachments()) if (e.attachment.region) pages.add(e.attachment.region.page);
  await Promise.all([...pages].map(page => new Promise((resolve, reject) => {
    const img = new Image();
    img.crossOrigin = 'anonymous';
    img.onload = () => { page.setTexture(new spine.CanvasTexture(img)); resolve(); };
    img.onerror = reject;
    img.src = `${BASE}${series}/${page.name}`;
  })));

  const skeleton = new spine.Skeleton(data);
  skeleton.setSkin(skin);
  skeleton.setSlotsToSetupPose();
  return { skeleton, state: new spine.AnimationState(new spine.AnimationStateData(data)) };
}

(async () => {
  const canvas = document.getElementById('c'), ctx = canvas.getContext('2d');
  const renderer = new spine.SkeletonRenderer(ctx);
  const { skeleton, state } = await loadCoq('chikn', 'Bullion', ['chikn_gentlechikn', 'chikn_kfckicks']);
  state.setAnimation(0, 'Idle', true);
  let last = performance.now();
  requestAnimationFrame(function frame(now) {
    state.update((now - last) / 1000); last = now;
    state.apply(skeleton);
    skeleton.updateWorldTransform(spine.Physics.update);
    const scale = canvas.height / 2400;  // Spine is y-up; flip it and put the feet near the bottom
    ctx.setTransform(1, 0, 0, 1, 0, 0);
    ctx.clearRect(0, 0, canvas.width, canvas.height);
    ctx.setTransform(scale, 0, 0, -scale, canvas.width / 2, canvas.height * 0.9);
    renderer.draw(skeleton);
    requestAnimationFrame(frame);
  });
})();
</script>

For WebGL, Pixi, Phaser or Three.js, use the matching official Spine runtime. The skeleton and atlas files are the same.

Other engines and the Spine editor

Downloads

Each zip has the skeleton, atlas, loose images, animation notes and trait catalogue for one series. Your browser builds it from the files on this site, so it always matches the current version.

Body skins

Chikn

Roostr

Crystale/Crystalé and PixelChan/Pixel-Chan have identical art. Both names are kept because the game used both.

Traits

Animations

Licence

Spine runtimes: the official Spine runtimes are licensed by Esoteric Software. Anyone who builds them into a product needs their own Spine Editor licence.

Art: the Chikn and Roostr art is released under the Chikn Community Asset Licence. Non-commercial use is free. Commercial use needs a separate agreement: it's royalty-free for the first AUD $100,000 of gross revenue, with a 10% royalty above that. Credit the assets visibly, for example:

Contains assets © Chikn. Used under licence. https://chikn.farm

The full licence is the binding text. It's also in every download as LICENSE.md.

Assets © Chikn, released under the Chikn Community Asset Licence.