Esempio n. 1
0
    public static void ShowRewardedVideoCallBack()
    {
        Srot.StartLimit();

        Debug.Log("ShowRewardedVideo");

        if (isDebug)
        {
            watchCompletedActionSelf?.Invoke();
            watchFailActionSelf?.Invoke();
            watchCompletedActionSelf = null;
            watchFailActionSelf      = null;
            watchEnterActionSelf     = null;
            entrySelf = 0;
            return;
        }

#if UNITY_EDITOR || SafeMode || NoAd
        watchCompletedActionSelf?.Invoke();
        watchFailActionSelf?.Invoke();
#elif UNITY_ANDROID && !UNITY_EDITOR
        CrossAndroid.ShowRewardedVideo(watchCompletedActionSelf, entrySelf);
#elif UNITY_IPHONE && !UNITY_EDITOR
        CrossIos.ShowRewardedVideo(entrySelf, watchCompletedActionSelf, Call, null, watchFailActionSelf);
#endif
        watchCompletedActionSelf = null;
        watchFailActionSelf      = null;
        entrySelf = 0;
    }