Hm my Spine src is from 6/28 and the LibGDX nightlies are about a month old, I don't recall needing to fix anything. :-/
And I'm using the json skeleton rather than the binary exports, but thge index error could be if your Atlas file hasn't been refreshed?
and here's what I popped into my BoxAtlasAttachmentLoader
import com.badlogic.gdx.graphics.g2d.TextureAtlas;
import com.badlogic.gdx.graphics.g2d.TextureAtlas.AtlasRegion;
import com.badlogic.gdx.physics.box2d.Body;
import com.esotericsoftware.spine.Skin;
import com.esotericsoftware.spine.attachments.AttachmentLoader;
import com.esotericsoftware.spine.attachments.AttachmentType;
import com.esotericsoftware.spine.attachments.RegionAttachment;
public class BoxAtlasAttachmentLoader implements AttachmentLoader {
private TextureAtlas atlas;
public BoxAtlasAttachmentLoader (TextureAtlas atlas) {
if (atlas == null) throw new IllegalArgumentException("atlas cannot be null.");
this.atlas = atlas;
}
public Box2dAttachment newAttachment (Skin skin, AttachmentType type, String name) {
Box2dAttachment attachment = new Box2dAttachment(name);
AtlasRegion region = atlas.findRegion(attachment.getName());
if (region == null) throw new RuntimeException("Region not found in atlas: " + attachment);
attachment.setRegion(region);
return attachment;
}
static class Box2dAttachment extends RegionAttachment {
Body body;
public Box2dAttachment (String name) {
super(name);
}
}
}