Commit 643c3b87 authored by 王雪伟's avatar 王雪伟

修改穿山甲开屏加载超时问题

parent 360e4375
......@@ -242,8 +242,10 @@ public class AdManager
if (adList == null || adList.Count == 0)
{
Debug.unityLogger.Log(ZXADConfig.ADManagerTAG, "Splash没有广告数据");
listener.onLastError();
return;
}
List<AdEntity> totalEntityList = adList;
AdEntity entity = totalEntityList[0];
entity.actionName = "开屏";
......
......@@ -174,6 +174,14 @@ public class CSJSplshADUtils
#endif
}
public void onTimeout()
{
EventUtils.onEventPullFail(entity, "-1", "网络超时");
listener.onError("CSJ SplshAd code -1 message 网络超时");
Debug.Log("splash load Onerror: -1 : 网络超时");
callback(false);
}
private sealed class SplashAdInteractionListener : ISplashAdInteractionListener
{
......
......@@ -1640,6 +1640,10 @@ public sealed class Example : MonoBehaviour
#endif
}
public void onTimeout()
{
}
private sealed class SplashAdInteractionListener : ISplashAdInteractionListener
{
......@@ -1750,7 +1754,12 @@ private sealed class ExpressSplashAdListener : ISplashAdListener
}
#endif
}
}
public void onTimeout()
{
}
}
private sealed class ExpressSplashAdInteractionListener : ISplashAdInteractionListener
{
......
......@@ -330,7 +330,11 @@ namespace ByteDance.Union
UnityDispatcher.PostTask(
() => this.listener.OnError(code, message));
}
public void onTimeout()
{
UnityDispatcher.PostTask(
() => this.listener.onTimeout());
}
public void onSplashAdLoad(AndroidJavaObject handle)
{
var ad = new BUSplashAd(handle);
......
......@@ -16,7 +16,7 @@ namespace ByteDance.Union
/// Invoke when load Ad error.
/// </summary>
void OnError(int code, string message);
void onTimeout();
/// <summary>
/// Invoke when the Ad load success.
/// </summary>
......
fileFormatVersion: 2
guid: 6915fe3cccc9344909d4516bf2cd6714
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
......@@ -132,7 +132,7 @@ public class AdDemo : MonoBehaviour
public void onLastError()
{
Debug.unityLogger.Log("开屏2Error");
Debug.unityLogger.Log("开屏onLastError");
}
}
......
......@@ -60,8 +60,8 @@ public class EventUtils
map["code_id"] = entity.codeId;
map["reqId"] = entity.reqId;
map["slot"] = entity.actionName;
map["errorMsg"] = code;
map["errorCode"] = msg;
map["errorMsg"] = msg;
map["errorCode"] = code;
EventHttp.Instance._PostEvent(JsonMapper.ToJson(map));
if (entity.pullfail_tracking != null && entity.pullfail_tracking.Count > 0)
......
......@@ -131,7 +131,7 @@ PlayerSettings:
16:10: 1
16:9: 1
Others: 1
bundleVersion: 1.0.0
bundleVersion: 1.0.5
preloadedAssets: []
metroInputSource: 0
wsaTransparentSwapchain: 0
......@@ -175,7 +175,7 @@ PlayerSettings:
androidSupportedAspectRatio: 1
androidMaxAspectRatio: 2.1
applicationIdentifier:
Android: com.ym.chxxx
Android: com.ym.cscmnq
Lumin: com.DefaultCompany.com.unity.template.mobile2D
Standalone: com.DefaultCompany.com.unity.template.mobile2D
iPhone: com.ym.iosawpdd
......@@ -184,7 +184,7 @@ PlayerSettings:
Standalone: 0
iPhone: 0
tvOS: 0
AndroidBundleVersionCode: 1
AndroidBundleVersionCode: 6
AndroidMinSdkVersion: 21
AndroidTargetSdkVersion: 0
AndroidPreferredInstallLocation: 1
......@@ -655,7 +655,7 @@ PlayerSettings:
scriptingDefineSymbols: {}
platformArchitecture: {}
scriptingBackend:
Android: 1
Android: 0
il2cppCompilerConfiguration: {}
managedStrippingLevel: {}
incrementalIl2cppBuild: {}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment