Kamcord is a free SDK that records the gameplay of your game in real time, on the device and then (more importantly to us devs needing viral promotion) lets the user share the video via YouTube, Facebook, Twitter or email!! The SDK works really quite amazingly well, has a very smart user interface and is easy for the player to use. For the possible user sharing promotion aspect alone, this is a no brainer. One more great benefit is you can see how your players play your game, where they are getting stuck in levels, adjust your levels and so on.
Take a look at the Kamcord page for my Arrow Mania 2 (all shared videos are also available on Kamcord.com even if they are shared to other places like YouTube and Facebook).

It’s pretty easy to do, the most tedious bit being the interface from Cocos2D-X to ObjC; To save you time I’m supplying the code to do this for you along with a simple guide. I wrote this for the latest V2 Cocos2D-x 2.2.2 but I assume it should work in V3 just fine (I haven’t looked at V3 myself, been too busy finishing Arrow Mania 2, please let me know if you try it and this isn’t the case – I’ll be upgrading to V3 and updating this article sometime in the future).
Instructions:
1. Go register for Kamcord and get yourself a key here: http://kamcord.com/developers/
2. Download the Kamcord SDK here: http://kamcord.com/developers/download/
3. Add the Kamcord SDK to your Cocos2D-X iOS project as they tell you to on their website, you just need to add the Kamcord framework and the iOS frameworks they mention: http://kamcord.com/developers/download/
4. Add these lines to your AppDelegate.mm file, in your “didFinishLaunchingWithOptions” function, preferably after you’ve created your viewcontroller!
[php]
// Tell Kamcord your developer key, secret, app name, and the parent view controller
// that will present the Kamcord UI.
[Kamcord setDeveloperKey:@"" // Put your Kamcord dev key inside these quote marks!
developerSecret:@"" // Put your Kamcord secret key inside these quote marks!
appName:@"" // Put your app name inside these quote marks!
parentViewController:viewController]; // Passing your Cocos2D-X view controller here, should have been created above this.
// Optional notifications stuff – see the Kamcord docs if you want the notification feature – you will need to set this in you provisioning profile too in iTunesConnect
//UILocalNotification *localNotif = [launchOptions objectForKey:UIApplicationLaunchOptionsLocalNotificationKey];
//if (localNotif) {
// [self application:application didReceiveLocalNotification:localNotif]; }
[/php]
5. Download my Cocos2D-X to ObjC Kamcord wrapper files and unzip it, add the files to your project.
http://www.gmtdev.com/downloads/KamCord.zip
6. Now for the fun part.
- Add “KamCordInt m_KamCord;” to your main scene class (in its header file).
- In your init call “m_KamCord.init();”
- When you want to start recording, just call “m_KamCord.record();”
- When you want to stop recording call “m_KamCord.stop();”
- To show the Kamcord interface (after a record and stop) call “
- m_KamCord.showKamCordViewer();”
- To pause a recording (say the play hits your pause button in the game), call “m_KamCord.pause();” and then “m_KamCord.resume();” when done.
- Once you have it all working, you can set some other things like the Youtube video title and description with a call to “m_KamCord.setVideoInfo”, this should be after you’ve stopped the recording:
[php]
CCString *csLevelTitle = CCString::createWithFormat("%s – %3.3i – %s", "Arrow Mania 2", 5, "A Fun Level");
CCString *csLevelNumberName = CCString::createWithFormat( "Level %i", 5 );
CCString *csLongDesc = CCString::createWithFormat("%s. %s", "This is a level from my game, go get it from more http://www.arrowmania.com",
csLevelTitle->getCString());
CCString *csYoutubeTags = CCString::createWithFormat(g_Strings->GetString(STR_POSTING_VID_YOUTUBE_TAGS), gdata.m_iCurrentLevel+1 );
m_KamCord.setVideoInfo(csLevelTitle->getCString(), csLevelNumberName->getCString(), gdata.m_iScore,
csLongDesc->getCString(), csYoutubeTags->getCString(),
csLongDesc->getCString() );
[/php]
” Cocos2D-X to ObjC Kamcord wrapper files and unzip it”
Where is this .Zip file .. From where i found for download…?
Whoops, I fixed the link: http://www.gmtdev.com/downloads/KamCord.zip