Last active
February 7, 2021 13:32
-
-
Save flurrydev/7f4777eb0cc48c226ef02de86a10a870 to your computer and use it in GitHub Desktop.
initialize Flurry in Unity project
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using FlurrySDK; | |
| public class FlurryStart : MonoBehaviour | |
| { | |
| #if UNITY_ANDROID | |
| private string FLURRY_API_KEY = "ANDROID_API_KEY"; | |
| #elif UNITY_IPHONE | |
| private string FLURRY_API_KEY = "IOS_API_KEY"; | |
| #else | |
| private string FLURRY_API_KEY = null; | |
| #endif | |
| void Start() | |
| { | |
| // Initialize Flurry. | |
| new Flurry.Builder() | |
| .WithCrashReporting(true) | |
| .WithLogEnabled(true) | |
| .WithLogLevel(Flurry.LogLevel.VERBOSE) | |
| .withMessaging(true); | |
| .Build(FLURRY_API_KEY); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
.withMessaging(true);is incorrect (causing compilation error). It should be:.WithMessaging(true)(uppercase W, and without;)