ANE-Chartboost is a native extension that allows the use of Chartboost SDK on iOS and Android. Chartboost is a platform that helps developer monetize their games, making money promoting other games or spending money acquiring quality users in the Chartboost network.
Chartboost is based on interstitial, some sort of banner displayed within the game. Using the extension is possible to decide the exact moment to show an interstitial. It’s also possible to cache them, which reduces network use.
Sample
public static function getInstance() : AirChartboost; public function get isChartboostSupported() : Boolean; public function startSession( appID : String, appSignature : String ) : void; public function showInterstitial( location : String = null ) : void; public function cacheInterstitial( location : String = null ) : void; public function hasCachedInterstitial( location : String = null ) : Boolean;
RT @as3gamegears: New: ANE-Chartboost (native extension to use Chartboost SDK) http://t.co/yrcwY9dISc #as3 #flash #gamedev
This is our first post and there are chances of mistakes so please bear with me.
Scenario
We got a project from a client to create an ios game from a flash action script 3.0 game. He have bought the game code and given us to modify it so it can be played back on iPhone and iPod. This was not a big deal for a company like us. We made the game and it got approved straight away. So we got another project with a new requirement of displaying ads from chartboost. We have read through Adobe forums and find out about the Native Extension so we made a deal with client.
Problems
We thought it would be an easy job but as we dig into creating NE, Native Extension, we find out lots of difficulties. We first contacted to ChartBoost if they already have any solution for games developed in Flash and ported for iOS. Their answer was a “NOâ€. So we decided to develop it in our lab. Next trouble was to combine static library from ChartBoost with NE we wanted to create. Salil worked on that problem and as we are in different timezones I had to work during nights for testing. Salil has wrote a post about it here.
Solution
My Brother have developed .a file using ChartBoost SDK and I have developed .swc component to be used inside the game. So to compile .ane file I have to get library.swf from the swc file and send to him so he can compile .a file using swc and library.swf and generate .ane file. He then send .ane file back to me so I can compile the game using that .ane file. After a week we got it working perfectly and the game showing ChartBoost ads. We submit the game and it got approved. Cool isn’t it.
Files
Here are the files. Create ane file using adt compiler and do the following
1. Import swc file in your game
2. Ad the following code to the game
var _chartboostExtension:ChartBoost = new ChartBoost();
_chartboostExtension.startAndShowChartboost(“Your App Idâ€,â€Your App Signatureâ€);
Due to work load we can not provide support for this. Please leave your message and we will try to help you out.
Thanks for reading though. I hope it was not a bad experience
download:http://code.google.com/p/chartboost-sdk/