Guidelines on what goes native in a cross platform game

Guidelines on what goes native in a cross platform game
0.0 0



I am creating a cross platform game using cocos2d-x for iphone and android,

and i know few things has to be done native (different code for ios and android to achieve something)

What are the places which require such a thing? What operations cannot be done generic and have to be done separately?

Just looking for some guidelines/tips/common practices, which other developers might have experienced…

Thank You :slight_smile:


You only need to code in Obj-C/Java if you are planning on using 3rd party libraries, i.e. AdMob, Game Center, etc.

If you aren’t planning on using them, you can safely create a COCOS2D-X game with basic knowledge of Obj-C and Java.


Hi Lance, Thank you :slight_smile:

Say i have this function,
void application:(CCApplication *)application didReceiveLocalNotification:(UILocalNotification *)notification

I have to implement this in objective C, as i dont see any equivalent generic cocos2dx way of doing it… (correct me if im wrong)

So i was looking for things which are better implemented separately rather spending more time on making it generic :slight_smile:

Thanks again for your time :slight_smile:


I’m not sure but you might want to look at CCNotificationCenter.