fermmm
fermmm

Reputation: 1216

Empty cocos2D-x project is too big

I want to create a very small (in apk size) Android game, I hope is not more than 3mb, so anyone with low avaiable space in the phone can play it. I can do it with libgdx but I want to use cocos2d-x.

The problem is that I built the start template project that only has the cocos logo image, using Android Studio in release mode and the APK built is 3.2Mb. Is too big. I run the analysis and the .so file size is 2.4mb.

I'm missing some optimizations or something? I'm new in cocos2d-x so maybe there is something I don't know.

Upvotes: 0

Views: 406

Answers (1)

Adam
Adam

Reputation: 1518

Here are the things you can try:

  1. Comment out physics engine, particle engine, any 3D libraries and other unused file formats from CCConfig.h
  2. Check if you are loading any TTF fonts (they can take around 600kb each)
  3. Build only for 1 arch at a time (not arm and x86 mixed)

If you do all that you can probably get down to around 1mb theoreticaly.

Upvotes: 0

Related Questions