0
我已經實施Chartboost到我的遊戲。 廣告顯示,如果我關閉它,沒有問題。 如果我按下後退按鈕也沒問題。 如果我按廣告並按下後退按鈕,或者回到應用程序,屏幕會變黑。我可以聽到背景音樂正在播放,我仍然可以播放遊戲,但顯示屏完全是黑色的。Unity 5 Chartboost黑屏
我用:團結5.0.2f1(64位)CBUnityPlugin_5_5_3
我測試它在Android 5.0.2手機和平板電腦4.4.4的 結果是一樣的。
bool shouldDisplayInterstitial(CBLocation location)
{
return true;
}
void didDisplayInterstitial(CBLocation location)
{}
void didCacheInterstitial(CBLocation location)
{}
void didFailToLoadInterstitial(CBLocation location, CBImpressionError error)
{}
void didDismissInterstitial(CBLocation location)
{}
void didCloseInterstitial(CBLocation location)
{}
void didClickInterstitial(CBLocation location)
{
Application.LoadLevel("Main_Menu");
}
void OnDisable()
{
Chartboost.didFailToLoadInterstitial -= didFailToLoadInterstitial;
Chartboost.didDismissInterstitial -= didDismissInterstitial;
Chartboost.didCloseInterstitial -= didCloseInterstitial;
Chartboost.didClickInterstitial -= didClickInterstitial;
Chartboost.didCacheInterstitial -= didCacheInterstitial;
Chartboost.shouldDisplayInterstitial -= shouldDisplayInterstitial;
Chartboost.didDisplayInterstitial -= didDisplayInterstitial;
}
void OnEnable()
{
Chartboost.didFailToLoadInterstitial += didFailToLoadInterstitial;
Chartboost.didDismissInterstitial += didDismissInterstitial;
Chartboost.didCloseInterstitial += didCloseInterstitial;
Chartboost.didClickInterstitial += didClickInterstitial;
Chartboost.didCacheInterstitial += didCacheInterstitial;
Chartboost.shouldDisplayInterstitial += shouldDisplayInterstitial;
Chartboost.didDisplayInterstitial += didDisplayInterstitial;
}
,並在我的更新循環
if (adcall)
{
variable.dieInc();
if (variable.getDie() == 3)
{
if (Chartboost.hasInterstitial(CBLocation.Default))
{
Chartboost.showInterstitial (CBLocation.Default);
}
variable.resetDie();
}
adcall = false;
}
是任何人都具有同樣的效果?
期待你的答案
你有沒有找到任何解決方案。有幾乎相同的問題,但不是黑屏,界面不響應觸摸,但統一活動確實響應android後退按鈕,顯示退出彈出 –