How do I "Force" multiplayer.myID? SOLVED

Get help using Construct 2

Post » Mon Mar 07, 2016 10:40 pm

Hello!

I am having a big problem on my multiplayer project: https://www.scirra.com/arcade/multiplay ... team6-5795

For what ever reason game instance for Peer doesn`t set peers multiplayer ID correctly. It some times leaves it complately unassigned and sometimes it sets same multiplayer for peer and host. It used to work fine. I set peerid`s the same way that they are set in multiplayer real time game example.

Has anyone run to this kind of problem or knows a work around? Maybe something like "forcing" game instance to set multiplayerID?

I don`t know what broke it, only guess I have is that when you have enough events in your multiplayer project events does not fire of correctly for everything to be set in the right way when connection is established or something... Does this make any sense?

I know that without posting capx its difficult to give me a specific answer, but I mostly asking if anyone has pumped in to this problem before.
Last edited by Virpoja on Tue Mar 08, 2016 4:41 pm, edited 1 time in total.
B
30
S
7
G
4
Posts: 31
Reputation: 4,913

Post » Mon Mar 07, 2016 10:46 pm

Also I forgot to ad. When the problem occurs, on the peer game instance both peer and host are shown in the same position. (because of identical multiplayerID). However when you refresh the browser window and log in again, everything works. It works like this every time.

Whats the difference between first & second peer login? Maybe this helps...
B
30
S
7
G
4
Posts: 31
Reputation: 4,913

Post » Tue Mar 08, 2016 4:46 pm

ISSUE SOLVED!

Basically problem / bug was something completely different. (one event was missing peer.peerid = multiplayer.myID)
- This caused peer and host to overlap positions on the peer side.

Reason why I thought the problem was multiplayer ID, because i had set text string to show Id in the wrong way... (showed host id for everyone)

So.... completely irrelevant "HOW DO I" post... Sorry about that
B
30
S
7
G
4
Posts: 31
Reputation: 4,913


Return to How do I....?

Who is online

Users browsing this forum: 8tomo8, Baidu [Spider], brunopalermo and 10 guests