[Android] Game is not paused on Hold/Standby mode.

Get help using Construct 2

Post » Mon May 27, 2013 4:10 pm

Hi C2 Developers, i have a problem with exported game for Android using CocoonJS by @ludei

My Problem:
Game is not paused when my Android device on Hold/Standby Mode.

Here is the video demo: (tested on Samsung Galaxy S4)
http://www.youtube.com/watch?v=9iRXcDbJ81E

Expected Result:
The application should be paused on Hold/Standby mode.

How must i do to fix this?
Is there any condition for Hold/Standby mode on mobile device (Android)?

Thanks for your reply :)

kenli2013-05-27 16:10:55
Enlik Tjioe
Hobbyist Game Developer
Technology, Travelling, and Video Games Enthusiast
www.enliktjioe.com
B
47
S
11
G
7
Posts: 176
Reputation: 7,858

Post » Mon May 27, 2013 5:53 pm

Did you add Browser plugin, an event "On Suspended" ?
B
99
S
35
G
29
Posts: 3,139
Reputation: 28,426

Post » Tue May 28, 2013 11:21 am

[QUOTE=Joannesalfa] Did you add Browser plugin, an event "On Suspended" ?[/QUOTE]

Yes @Joannesalfa, i've added the Browser plugin with "On Suspended" event.


It works on Desktop browser and Android browser (tested on Chrome, Firefox Beta, Opera).

But when i'm compiled it with CocoonJS and make it native games (.APK), the game is not paused when my Android device in hold mode, and this plugin event "On Suspended" is not work as usual.kenli2013-05-28 11:22:19
Enlik Tjioe
Hobbyist Game Developer
Technology, Travelling, and Video Games Enthusiast
www.enliktjioe.com
B
47
S
11
G
7
Posts: 176
Reputation: 7,858

Post » Tue May 28, 2013 11:48 am

It's Ludei's problem, you should report to Ludei's team.
B
99
S
35
G
29
Posts: 3,139
Reputation: 28,426

Post » Tue May 28, 2013 1:46 pm

@kenli
it might have to do with cocoonjs wakelock issue.

I have been told they are fixing this in release 1.4 which should be out soon
If you are looking for solutions and workarounds to the Windows 10 C2 performance issues feel free to reach out to me.

Following rexrainbow's lead - Goodbye.
B
50
S
24
G
14
Posts: 632
Reputation: 12,505

Post » Tue May 28, 2013 1:59 pm

Construct 2 automatically pauses the game (or it should do anyway) when it goes in to the background. We listen to CocoonJS's suspend and resume events and handle them accordingly. It looks like CocoonJS isn't calling the suspend and resume events appropriately, so you should probably contact Ludei about the issue.
Scirra Founder
B
414
S
245
G
92
Posts: 25,205
Reputation: 200,351

Post » Tue May 28, 2013 6:18 pm

Thanks @Joannesalfa @humanescape @Ashely for your reply, i'll contact @ludei now.

Hopefully this problem solved and i'll share it here :)
Enlik Tjioe
Hobbyist Game Developer
Technology, Travelling, and Video Games Enthusiast
www.enliktjioe.com
B
47
S
11
G
7
Posts: 176
Reputation: 7,858


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 4 guests