fix:1、接入合作方的sdk。2、支付逻辑接入sdk中的接口
This commit is contained in:
@@ -1,61 +1,61 @@
|
||||
using System.Collections;
|
||||
using UnityEngine;
|
||||
using AppsFlyerSDK;
|
||||
using System.Collections.Generic;
|
||||
using System;
|
||||
using BallKingdomCrush;
|
||||
using DG.Tweening;
|
||||
using SGModule.NetKit;
|
||||
|
||||
namespace DontConfuse
|
||||
{
|
||||
|
||||
|
||||
internal class AppsFlyerObjectScript1 : MonoBehaviour, IAppsFlyerConversionData
|
||||
{
|
||||
void Start()
|
||||
{
|
||||
AppsFlyer.initSDK("h8pivQvBQbZtoxhkSY7BJ6", null, this);
|
||||
AppsFlyer.startSDK();
|
||||
|
||||
#if UNITY_EDITOR
|
||||
NetworkDispatcher.Instance.Dispatch(NetworkMsg.Login);
|
||||
#endif
|
||||
}
|
||||
void Update()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
// Mark AppsFlyer CallBacks
|
||||
public void onConversionDataSuccess(string conversionData)
|
||||
{
|
||||
AppsFlyer.AFLog("didReceiveConversionData", conversionData);
|
||||
Dictionary<string, object> conversionDataDictionary = AppsFlyer.CallbackStringToDictionary(conversionData);
|
||||
// add deferred deeplink logic here
|
||||
SuperApplication.Instance.attribution =
|
||||
conversionDataDictionary.GetValueOrDefault("af_status")?.ToString();
|
||||
|
||||
NetworkDispatcher.Instance.Dispatch(NetworkMsg.Login);
|
||||
}
|
||||
|
||||
public void onConversionDataFail(string error)
|
||||
{
|
||||
AppsFlyer.AFLog("didReceiveConversionDataWithError", error);
|
||||
|
||||
NetworkDispatcher.Instance.Dispatch(NetworkMsg.Login);
|
||||
}
|
||||
|
||||
public void onAppOpenAttribution(string attributionData)
|
||||
{
|
||||
AppsFlyer.AFLog("onAppOpenAttribution", attributionData);
|
||||
Dictionary<string, object> attributionDataDictionary = AppsFlyer.CallbackStringToDictionary(attributionData);
|
||||
// add direct deeplink logic here
|
||||
}
|
||||
|
||||
public void onAppOpenAttributionFailure(string error)
|
||||
{
|
||||
AppsFlyer.AFLog("onAppOpenAttributionFailure", error);
|
||||
}
|
||||
}
|
||||
}
|
||||
// using System.Collections;
|
||||
// using UnityEngine;
|
||||
// using AppsFlyerSDK;
|
||||
// using System.Collections.Generic;
|
||||
// using System;
|
||||
// using BallKingdomCrush;
|
||||
// using DG.Tweening;
|
||||
// using SGModule.NetKit;
|
||||
//
|
||||
// namespace DontConfuse
|
||||
// {
|
||||
//
|
||||
//
|
||||
// internal class AppsFlyerObjectScript1 : MonoBehaviour, IAppsFlyerConversionData
|
||||
// {
|
||||
// void Start()
|
||||
// {
|
||||
// AppsFlyer.initSDK("h8pivQvBQbZtoxhkSY7BJ6", null, this);
|
||||
// AppsFlyer.startSDK();
|
||||
//
|
||||
// #if UNITY_EDITOR
|
||||
// NetworkDispatcher.Instance.Dispatch(NetworkMsg.Login);
|
||||
// #endif
|
||||
// }
|
||||
// void Update()
|
||||
// {
|
||||
//
|
||||
// }
|
||||
//
|
||||
// // Mark AppsFlyer CallBacks
|
||||
// public void onConversionDataSuccess(string conversionData)
|
||||
// {
|
||||
// AppsFlyer.AFLog("didReceiveConversionData", conversionData);
|
||||
// Dictionary<string, object> conversionDataDictionary = AppsFlyer.CallbackStringToDictionary(conversionData);
|
||||
// // add deferred deeplink logic here
|
||||
// SuperApplication.Instance.attribution =
|
||||
// conversionDataDictionary.GetValueOrDefault("af_status")?.ToString();
|
||||
//
|
||||
// NetworkDispatcher.Instance.Dispatch(NetworkMsg.Login);
|
||||
// }
|
||||
//
|
||||
// public void onConversionDataFail(string error)
|
||||
// {
|
||||
// AppsFlyer.AFLog("didReceiveConversionDataWithError", error);
|
||||
//
|
||||
// NetworkDispatcher.Instance.Dispatch(NetworkMsg.Login);
|
||||
// }
|
||||
//
|
||||
// public void onAppOpenAttribution(string attributionData)
|
||||
// {
|
||||
// AppsFlyer.AFLog("onAppOpenAttribution", attributionData);
|
||||
// Dictionary<string, object> attributionDataDictionary = AppsFlyer.CallbackStringToDictionary(attributionData);
|
||||
// // add direct deeplink logic here
|
||||
// }
|
||||
//
|
||||
// public void onAppOpenAttributionFailure(string error)
|
||||
// {
|
||||
// AppsFlyer.AFLog("onAppOpenAttributionFailure", error);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
Reference in New Issue
Block a user