游戏已经启动的情况下,从浏览器再次唤起游戏,导致游戏重启

ccc1.3.2 android4.4.2

游戏已经启动的情况下,再次通过浏览器的url打开应用,一操作界面或等个几秒钟就回到了浏览器,再点开游戏,已经重启了。

==============更新=============
新建了一个helloworld项目,重复上面的操作,没有出现这种情况,对比日志发现我的项目onResume后多了如下日志:
D/cocos2d-x: reload all texture D/cocos2d-x: Dirty Uniform and Attributes of GLProgramState A/libc: Fatal signal 11 (SIGSEGV) at 0x00000030 (code=1), thread 16712 (Thread-2011) D/dalvikvm: MakeBoost:0x415ec2c8 to 1 V/HwPolicyFactory: : success to get AllImpl object and return.... V/HwWidgetFactory: : successes to get AllImpl object and return....

将项目的res, src 复制到helloworld会引起重启。所以我不知道我代码里写了什么会导致这种情况。求大神分析下。

跳回浏览器是为什么呢?再切回游戏会重启,应该是操作系统杀掉进程吧?应该是正常的。

正常的? 有没有朋友做过通过微信发链接邀请,在浏览器打开后跳转到游戏的需求?能帮忙测试下有没有问题么?
Android manifest:
`

    <activity
        android:name="org.cocos2dx.javascript.AppActivity"
        android:screenOrientation="sensorLandscape"
        android:configChanges="orientation|keyboardHidden|screenSize"
        android:label="@string/app_name"
        android:theme="@android:style/Theme.NoTitleBar.Fullscreen" >
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
        <intent-filter>
            <action android:name="android.intent.action.VIEW"/>
            <category android:name="android.intent.category.DEFAULT" />
            <category android:name="android.intent.category.BROWSABLE" />
            <data android:scheme="wxde1af3f15f96cd1a"/>
        </intent-filter>
    </activity>
    <activity
        android:name=".wxapi.WXEntryActivity"
        android:label="@string/app_name"
        android:launchMode="singleTop"
        android:theme="@android:style/Theme.Translucent"
        android:exported="true"/>
</application>`

然后先启动游戏, 然后切到浏览器中,通过 wxde1af3f15f96cd1a:// 启动 ,我现在是能正常唤起游戏,但是一操作界面或者不操作等个6~7秒,就黑一下,然后重启了游戏

从描述来看,应该是你在界面的操作导致了游戏的崩溃。看起来是黑了一下,又回到浏览器。实际上游戏已经崩溃了,所以再次点链接启动,游戏就重启了。

不是,不操作也会重启啊,等个几秒,只要不是从浏览器重新调起来,游戏都能正常玩,ios上一切正常

请问这个问题解决了吗

览器返回后会重新创建AppActivity, 导致引擎被重新创建和加载一次,在AppActivity的AndroidManifest里加这条 android:launchMode=“singleTask”,然后重写AppActivity的onNewIntent方法
@Override
protected void onNewIntent(Intent intent) {
super.onNewIntent(intent);
setIntent(intent); // 添加这条
}

你好,请问解决了吗