So I have this problem happening in cocos2d-x for windows phone. I completed my entire game in debug mode and wanted to release this morning. I rebuilt the game in release mode and saw my heading not showing up. At this point I inspected the xap file to check if the file has been included. I then looked at the csproj file to see if it's linked and set to content. I built the same code in debug and saw my MenuItem showing up again. These are the things I have tried with no real results:
Is this a bug in coco2d-x v3.2? I have looked around and the only similar problems I have seen, in the sense of debug being different to release, is a green screen showing up in release mode with no sound. I do not have this problem. My sound is fine and all the other screens have all the elements on it. I did however try the recommended solutions for those problem, which were to remove NDEBUG from the preprocessors.
The next thing i'll be trying is to make the image smaller and see if that changes anything. I'll also be creating different MenuItems with the same image and add those to the game instead. All of this is a pain since the cocos projects take quite some time to build and I don't have the fastest machine in the world.
I am hoping that it's a 'setting' or flag that has to be set rather than a restructuring of code or something that requires me to rework my awesome menu's. Any suggestions are welcome, I'm fairly familiar with all games development/graphics concepts also I create a lot of Windows Phone content so I know a bit in that field too.
For all of the devs that will run into this problem, i found a 'hacky' solution that I will use to release with and then do some proper investigation on why it's happening. I hope some cocos2d-x developers see this and check if it's a bug.
The pattern i saw was this, the first image used in a menu, will invalidate that menuItem completely (only in my starting scene). Any other MenuItem that uses that same image will be removed as well, it's completely out of the scene as well. How I found this was by creating the following small app.
Setup in the helloworld scene: item1 = MenuItem: using header.png item2 = MenuItem: using header.png ... item 6 : " " " "
Added all the items to one menu:
menu:create(with items) addMenuToScene (^).
Nothing showed up in my application.
I then made a copy of header.png, called it header2.png. I used header2.png for all items except for item1 and the rest all showed up.
To confirm this behavious i then changed random items to use the first_defined item's image, and they dissapeared from the scene as well.
this is very weird behavior, I will post this to cocos2d-x devs and have them look at it.