How do I handle the pause on unfocus in a multiplayer game ?

Get help using Construct 2

Post » Wed Jan 11, 2017 1:30 am

Hello,

I'm currently making a realtime topdown shooter. The project is pretty well advanced, but here are my "issue" :

Right now, I'm using the NW.js export with an updater to distrube my game. It's good, but I'd like to be abble to play it in my browser. But...
If I switch tab in a browser, the game pauses (obviously that's normal and can't be turned off for performance issues) but this mess up my realtime game timers.

Do you have any tips to handle this ?

Thank you :)

Here is the game if you want to check it out : https://www.dropbox.com/s/p0brxh4pnqftfuv/BRikette_Setup.exe?dl=1
B
9
S
4
G
1
Posts: 2
Reputation: 1,244

Post » Sun Jan 15, 2017 11:22 pm

This is not really a solution since as you said c2's functionalities can't really help you, but have you considered a "kick" from the current session ? Or maybe another less aggressive solution would be once each 10-20 mins for example, to place the player in a safespot until he comes back, so if they abuse it and do it more than 1 time each x minutes, they get somekind of penality the more they do it, or they may get kicked or instakilled, you choose. This way you also trigger the penality if they don't move for x minutes to prevent afk players.
Image
B
21
S
7
G
3
Posts: 32
Reputation: 2,982

Post » Fri Feb 03, 2017 4:48 am

Would just getting the difference between your time and another player's time and adjusting the timers based on that work?
If adjusting timers won't work or is too much trouble maybe you could increase time scale to some high number until current time matches other players.
B
17
S
6
G
1
Posts: 41
Reputation: 1,725


Return to How do I....?

Who is online

Users browsing this forum: Sirvoid and 8 guests