This repo is forked from splhack/Hello-LWF-Cocos2d-x and is the sample code for this blog post, which explains how to use cocos2d-x to support animations in a fragment.
If you just want to run the demo. Open the project under BabyAnimationDemo
.
To modify the animation part, you can:
- Open the project under
proj.ios_mac
orproj.win32
; - Make changes. Note that if you added or removed C++ files,
Android.mk
should also be updated; - Run
./build_native.py -b release
underproj.android
to compile for android platform; - Copy files under
proj.android/libs/
toBabyAnimationDemo/app/src/main/libs/
; - Re-run
BabyAnimationDemo
该项目是从 splhack/Hello-LWF-Cocos2d-x fork 出来的。是这一篇 Blog 的示例代码。
如果你只是想要打开看看效果,打开 BabyAnimationDemo
下的项目。
如果要对动画部分作出更改:
- 打开
proj.ios_mac
或proj.win32
下的项目; - 作出更改。 注意,如果你添加或删除了 C++ 的源文件,
Android.mk
也需要做相应的更新; - 在
proj.android
目录下运行./build_native.py -b release
进行编译; - 将
proj.android/libs/
目录下的文件拷贝到BabyAnimationDemo/app/src/main/libs/
; - 重新运行
BabyAnimationDemo