Multiplayer : Not Working On Layout Restart

0 favourites
  • 8 posts
From the Asset Store
2D fighting template based in the game that defined the fighting games genre.
  • Hi,

    I have a game that uses multiplayer, it works but sometimes it doesn't go beyond the point of joining a room ie. it seems after "auto-join the room" it does not allow other peer to join.

    To troubleshoot i made a list of all multiplayer variables related like this:

    And i observed this:

    Now i am confused as how is it possible that it has the current instance name... "Short"; room name ..."Quick"; but have "0" room count and "0" current peers ?

    Also when it works, all the counts show correctly.

    Any clue of what could be going wrong?

    Note : It mostly happens when the layout restarts.

  • In my practice, if I do a "PeerCount" check immediately after the "On signalling joined room" trigger, then it correctly identifies two players (host + one player), but if a third one connects, it also shows two players. And you need to set a delay about 2 seconds before "PeerCount" for it to show 3 players on the server

  • Hi q3olegka

    But in my case, the feed gets updated every 1 sec.,

    i am pretty sure its about something wrong in my code, but its a messy one and i wanted some clue of where to start looking... As why this happens at all.

  • I think i found the problem,

    It happens when we restart the layout or leave the layout and come back to it.

    Here i have modified the "Multiplayer Chat Example File" with two buttons : Restart and GoBack

    When i click "Restart", it gets stuck to "logging in....."

    when i click "GoBack" and Login Again it gets stuck to "joining room..."

    I am not sure its a bug or the code problem, i have added just three events in "Chat Room Event Sheet":

    Here is the link to C3p : https://drive.google.com/open?id=1JYCSZiUGFROxN1bnM11npB214F9w9jKu

  • Anyone from scirra team to look this up? I need to fix a game...

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Bump!?

    Am i making some obvious mistake here?

    If not i need to file a bug report asap, can someone with multiplayer experience please confirm this?

  • I updated event 28 and 29 ...

    You need to disconnect and wait a bit ... its networking, not everything is instant.

    1drv.ms/u/s!Atd4bP2W1lworhxxSiw38moOtZ_L

  • Thanks lennaert It worked :)

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)