Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / Multisync Issues - Not Receiving Data Correctly

Author
Message
Bio Fox
19
Years of Service
User Offline
Joined: 11th Nov 2004
Location: The BioFox Bunker
Posted: 10th Jul 2016 01:41
Hey, so I've been working with multisync for about two weeks now and it's been a smooth ride. However, I currently have a problem where Player One (who also hosts the server through a second program on same computer) doesn't receive a second player's name who joins the server. The server sees everyone connected and everyone's name AND when player two joins they receive player one's name. I just can't seem to figure this one out.

By the way, I connect with Net Connect 127.0.0.1 for Player One and use a 192.168.1.X for all other players.

Can anyone take a look at this code and tell me what I'm doing wrong. I think the messages are sending incorrectly or I'm canceling out a variable somewhere. It's maddening because the server receives all the information but players aren't getting it all.

Server code:


Lobby code (all players):


Any tips for multisync? Am I not sending data correctly?
BioFox Games
Ortu
DBPro Master
16
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 12th Jul 2016 03:49


why not just do "net send all" ?
Bio Fox
19
Years of Service
User Offline
Joined: 11th Nov 2004
Location: The BioFox Bunker
Posted: 17th Jul 2016 23:11
Yea, I use send all, what I was doing there was testing to make sure it works.

So I actually figured out my issue. My server was sending and receiving several different sets of messages. After looking at the Multisync code some more I realized that each player should only send one message set to the server.

In short, Player Message (number and name) => Server => Each Other Player Receives.

For some reason this simplified things and now all players receive notice when another player joins. Hope this helps other people in the future!
BioFox Games

Login to post a reply

Server time is: 2024-04-26 12:48:31
Your offset time is: 2024-04-26 12:48:31