统一5.0应用程序在退出Android版 [英] Unity 5.0 Application Quit in Android

查看:340
本文介绍了统一5.0应用程序在退出Android版的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

最近,我在我的Andr​​oid游戏升级从Unity 4.6至5.0。它运行在编辑器没有问题。当我把它放在任何Android手机,它会显示以下错误消息:

Recently I upgrade my android game from Unity 4.6 to 5.0. It runs no problem in editor. When I put it in any android mobile, it will show the following error message:

E /统一(23691):渲染纹理警告:销毁活动的渲染纹理。切换到主背景。

E/Unity (23691): RenderTexture warning: Destroying active render texture. Switching to main context.

我怎么能灭所有活动的渲染纹理?任何帮助吗?

How can I destroy all active render texture? Any help?

推荐答案

您可能需要进行更改插件/ Android的/ AndroidManifest.xml中。

You probably need to make changes to the Plugins/Android/AndroidManifest.xml.

删除以下内容:

<activity android:name="com.unity3d.player.UnityPlayerProxyActivity" android:label="@string/app_name" android:configChanges="fontScale|keyboard|keyboardHidden|locale|mnc|mcc|navigation|orientation|screenLayout|screenSize|smallestScreenSize|uiMode|touchscreen" >
<meta-data android:name="unityplayer.ForwardNativeEventsToDalvik" android:value="true" />
  <intent-filter>
    <action android:name="android.intent.action.MAIN" />
    <category android:name="android.intent.category.LAUNCHER" />
  </intent-filter>
</activity>

但是复制整个意向滤波部分到名为UnityPlayerActivity的活动是这样的:

But copy the entire intent-filter section into the activity called UnityPlayerActivity to look like this:

<activity android:name="com.unity3d.player.UnityPlayerActivity" android:label="@string/app_name" android:configChanges="fontScale|keyboard|keyboardHidden|locale|mnc|mcc|navigation|orientation|screenLayout|screenSize|smallestScreenSize|uiMode|touchscreen" >
  <intent-filter>
    <action android:name="android.intent.action.MAIN" />
    <category android:name="android.intent.category.LAUNCHER" />
  </intent-filter>
</activity>

该解决方案为我工作,并在这个线程从theprisoner6拍摄:

This solution worked for me and was taken from theprisoner6 in this thread:

<一个href=\"http://stackoverflow.com/questions/28888679/mobile-game-restarts-when-using-application-quit\">Mobile比赛重新开始使用Application.Quit 时

这篇关于统一5.0应用程序在退出Android版的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆