proton:admanager_flurry
Differences
This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| proton:admanager_flurry [2012/07/07 04:07] – created seth | proton:admanager_flurry [2012/07/26 03:59] (current) – seth | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | No docs yet. | + | === Flurry === |
| + | |||
| + | [[http:// | ||
| + | |||
| + | Currently supported | ||
| + | |||
| + | Requires an [[http:// | ||
| + | |||
| + | === Adding Flurry to the AdManager === | ||
| + | |||
| + | * Add / | ||
| + | |||
| + | Add the following under your other # | ||
| + | |||
| + | < | ||
| + | #ifdef RT_FLURRY_ENABLED | ||
| + | #include " | ||
| + | #endif | ||
| + | </ | ||
| + | |||
| + | Note, the #ifdefs I use are not really required here, but it's useful so you can turn on/off different ad systems easily | ||
| + | |||
| + | Next, add the following code under the existing m_adManager.Init() statement. (You did already setup AdManager, right?!) | ||
| + | |||
| + | < | ||
| + | #ifdef RT_FLURRY_ENABLED | ||
| + | |||
| + | AdProviderFlurry *pFlurryProvider = new AdProviderFlurry; | ||
| + | pFlurryProvider-> | ||
| + | m_adManager.AddProvider(pFlurryProvider); | ||
| + | #endif | ||
| + | |||
| + | Note: You'll need to replace the <your flurry api key> part with the stuff you cut and paste from the Flurry control panel. | ||
| + | </ | ||
| + | |||
| + | In your App.h, add the following somewhere so Flurry will actually be used. (You can still compile with it under Windows builds for testing, it just won't do much) | ||
| + | |||
| + | < | ||
| + | #define RT_FLURRY_ENABLED | ||
| + | </ | ||
| + | |||
| + | Tracking stuff. | ||
| + | |||
| + | < | ||
| + | //on your about menu, you could add this to see how many people actually look at it: | ||
| + | GetApp()-> | ||
| + | |||
| + | //when someone buys IAP, you could add this to track what people are buying: | ||
| + | GetApp()-> | ||
| + | </ | ||
| + | |||
| + | === Enabling Flurry for Windows Android build === | ||
| + | |||
| + | These directions assume you are using the proton v2 android build system, which nearly all examples use now. You can look at RTAdManager for an example if needed. | ||
| + | |||
| + | The plugin will automatically handle creating multiple Flurry sessions upon suspend/ | ||
| + | |||
| + | First, download the Flurry SDK for Android (you' | ||
| + | |||
| + | * Add -DRT_FLURRY_ENABLED to the SHARED_FLAGS variable in your / | ||
| + | * Make sure shared/ | ||
| + | |||
| + | In your build_prepare.bat, | ||
| + | |||
| + | < | ||
| + | :for Flurry | ||
| + | goto skipflurry; | ||
| + | set TEMPFILE=..\..\shared\android\optional_src\libs\Flurry\FlurryAgent.jar | ||
| + | |||
| + | :Extra check to make sure we can locate the files | ||
| + | if exist " | ||
| + | echo Located flurry files. | ||
| + | ) else ( | ||
| + | echo Cannot find FlurryAgent.jar. | ||
| + | ..\..\shared\win\utils\beeper.exe /p | ||
| + | ) | ||
| + | copy %TEMPFILE% libs | ||
| + | : | ||
| + | </ | ||
| + | |||
| + | Change ":goto skipflurry;" | ||
| + | |||
| + | Next, edit your android/ | ||
| + | < | ||
| + | // #define RT_FLURRY_SUPPORT | ||
| + | </ | ||
| + | to | ||
| + | < | ||
| + | //#define RT_FLURRY_SUPPORT | ||
| + | </ | ||
| + | |||
| + | to enable it. | ||
| + | |||
| + | The android/ | ||
| + | |||
| + | That's it, Flurry should work in your Android build now. | ||
| + | |||
| + | Note: When testing, the Flurry control panel seemed very slow to show activity, like 10+ hours to update. | ||
| + | |||
| + | == Important note about Flurry on Android == | ||
| + | Flurry actually sends the the statistical data it's collected when it closes the session. | ||
| + | |||
| + | To work around this, don't send MESSAGE_FINISH_APP or have a quit button. | ||
| + | |||
| + | RTAdTest does it this way, you can check it for an example. | ||
proton/admanager_flurry.1341634020.txt.gz · Last modified: 2012/07/07 04:07 by seth
