Click here to Skip to main content
15,910,471 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I am totally new to cocos2d-x ios game development and really learning a lot from codeproject.Just want to thank all the software coders.Now my question is I am making a game with levels and high score.But still couldn't find a way to store the high score and the levels cleared.When the game restarts all the values are set to initial values as there is no database to fetch.I have heard about userdefault in cocos2d-x but really couldn't find a way to execute. Can anyone help me with a sample. I will be thankful to you
Posted
Updated 13-Jan-14 6:44am
v2

I don't have it in front of me, but I think there is a demo in cocos2d-x that shows how to use it - loof through the demo sources & you should find it.
 
Share this answer
 
You May Find Answer In Your cocos2d-x Project.
Path is
cocos2d-x-2.1.5\samples\Cpp\TestCpp\Classes\UserDefaultTest\UserDefaultTest.h
cocos2d-x-2.1.5\samples\Cpp\TestCpp\Classes\UserDefaultTest\UserDefaultTest.cpp
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900