This is an old revision of the document!
Tapjoy lets you run ads and use virtual currency.
Check RTAdTest for an example, it's supported on Android and iOS.
Requires an AdManager object to be setup to use.
To initialize it, add:
//put this somewhere after m_adManager.Init(); is called AdManager::InitTapjoy("your tapjoyID", "your tapjoyAppSecretKey");
Android note: If the tapjoy info was manually set in android/src/Main.java, the android build will ignore this. (to keep compatibility with old projects that did it that way)
Download the Tapjoy iOS Publisher (+Virtual Goods) SDK and put the TapjoyConnectVirtualGoodsSDK_iOS directory in /shared/iOS.
Add the entire /shared/iOS/TapjoyConnectVirtualGoodsSDK/TapjoyConnect folder to your Xcode project. (Select the “Create Groups for any added folders” option)
Add the source files /shared/iOS/app/TapjoyManager.mm (and its .h) to your project.
Define the compiler environmental variable RT_TAPJOY_ENABLED to the project's xCode settings.
If you get link errors about the CoreTelephony, sqlite3, MPMoviePlayer libraries missing, you'll need to add them:
Go to your Xcode project settings and select Build Phases, exapand “Link Binary With Libraries”, click the plus sign to add the following libraries if you don't already have them:
Note: I got some strange errors in the Tapjoy SDK source about UIKit elements missing and had to add #import <UIKit/UIKit.h> in a few places in the Tapjoy source. Not sure why! Something setup differently in the RTAdTest project as compared to their example project I guess. Let me know if you know.
Download the Tapjoy Android Virtual Publishers SDK and copy the com/tapjoy directory to /shared/android/optional_src/com. (This is where Proton will expect to find the SDK files when doing the build)
Edit android/build_prepare.bat and uncomment the tapjoy lib copy so it looks like below:
:for tapjoy (optional) echo d | xcopy ..\..\shared\android\optional_src\com\tapjoy temp_final_src\com\tapjoy /E /F /Y
Edit android/src/Main.java and change #define RT_TAPJOY_SUPPORT to #define RT_TAPJOY_SUPPORT
Also look below in that file and change this to valid info:
TapjoyConnect.requestTapjoyConnect(getApplicationContext(), "replace with tapjoy app id", "replace with tapjoy app secret key");