so i have the following code in a file called mainMenu:
[[CCDirector sharedDirector] runWithScene:[GameLayer scene]];
and I have #import "GameLayer.h". GameLayer has cocos2d, box2d, GLES-Render included in the .h header file.
so whenever I include GameLayer in the mainMenu file (.m) and try to build the app, it fails returning around 360 errors all about b2d (b2settings, b2math etc). anyone has any idea what I am doing wrong??
NOTE the mainMenu code works perfectly fine without including the GameLayer, and so does GameLayer without mainMenu!
Change Main Menu’s extension to .mm. This makes it an Objective-C++ file, which is needed, because box2d is in C++.