Esempio n. 1
0
        public static void start(AdjustConfig adjustConfig)
        {
            if (Adjust.instance != null)
            {
                Debug.Log("adjust: Error, SDK already started.");
                return;
            }

            if (adjustConfig == null)
            {
                Debug.Log("adjust: Missing config to start.");
                return;
            }

                        #if UNITY_EDITOR
            Adjust.instance = null;
                        #elif UNITY_IOS
            Adjust.instance = new AdjustiOS();
                        #elif UNITY_ANDROID
            Adjust.instance = new AdjustAndroid();
                        #else
            Adjust.instance = null;
                        #endif

            if (Adjust.instance == null)
            {
                Debug.Log("adjust: SDK can only be used in Android, iOS, Windows Phone 8 or Windows Store apps.");
                return;
            }

            adjustConfig.setSdkPrefix(Adjust.sdkPrefix);
            Adjust.attributionChangedDelegate = adjustConfig.getAttributionChangedDelegate();

            Adjust.instance.start(adjustConfig);
        }
Esempio n. 2
0
        public static void start(AdjustConfig adjustConfig)
        {
            if (Adjust.instance != null) {
                Debug.Log ("adjust: Error, SDK already started.");
                return;
            }

            if (adjustConfig == null) {
                Debug.Log ("adjust: Missing config to start.");
                return;
            }

            #if UNITY_EDITOR
                Adjust.instance = null;
            #elif UNITY_IOS
                Adjust.instance = new AdjustiOS();
            #elif UNITY_ANDROID
                Adjust.instance = new AdjustAndroid();
            #else
                Adjust.instance = null;
            #endif

            if (Adjust.instance == null) {
                Debug.Log ("adjust: SDK can only be used in Android, iOS, Windows Phone 8 or Windows Store apps.");
                return;
            }

            adjustConfig.setSdkPrefix(Adjust.sdkPrefix);
            Adjust.attributionChangedDelegate = adjustConfig.getAttributionChangedDelegate ();

            Adjust.instance.start (adjustConfig);
        }