Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tylerzhu/SpriteSheet
ActionScript 3.0 Sprite Sheet render engine
https://github.com/tylerzhu/SpriteSheet
Last synced: 2 months ago
JSON representation
ActionScript 3.0 Sprite Sheet render engine
- Host: GitHub
- URL: https://github.com/tylerzhu/SpriteSheet
- Owner: tylerzhu
- Created: 2014-02-26T12:49:09.000Z (almost 11 years ago)
- Default Branch: master
- Last Pushed: 2014-04-01T12:17:42.000Z (almost 11 years ago)
- Last Synced: 2024-08-04T05:04:13.880Z (6 months ago)
- Language: ActionScript
- Size: 602 KB
- Stars: 27
- Watchers: 2
- Forks: 7
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-actionscript-sorted - SpriteSheet - ActionScript 3.0 Sprite Sheet render engine (Apps & Tools / Development Tool)
README
SpriteSheet
===========ActionScript 3.0 Sprite Sheet render engine
实现了SpriteSheet精灵序列图引擎,可以解析Flash Cs6/TexturePacker导出的JSON、JSON-Array、XML格式的SpriteSheet。
相关介绍:http://www.cnblogs.com/skynet/p/3570421.htmlSpriteSheet调整中心等功能,参考SpriteSheet编辑工具:https://github.com/saylorzhu/SpriteSheetEdit
Demo
-----------
. 加载SpriteSheet png图片及数据描述文件>AssetManager.getInstance().getGroupAssets("spritesheets-json", ["data/json/jsonformat.json", "data/json/jsonformat.png"], onAnimLoaded);
. 创建SpriteSheet实例:
>private function onAnimLoaded():void
{
var bitmapData:BitmapData = AssetManager.getInstance().bulkLoader.getBitmapData("data/json/jsonformat.png");
var sheets:* = AssetManager.getInstance().getContent("data/json/jsonformat.json");
var sp:SpriteSheet = new SpriteSheet(bitmapData, sheets, DataFormat.FORMAT_JSON);
sp.setAction("呼吸", 14);
sp.play();
addChild(sp);
}