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.

Author
Message
Lucka
21
Years of Service
User Offline
Joined: 1st Oct 2004
Location:
Posted: 10th Sep 2014 21:23
Hello, i am writing a TWO player game using Multisync.

It works properly, everithing's fine.
I will show it in WIP asap.

But..

I get a "spike" lag during game, something like SOMETIMES data sending/receiving is interrupted for a couple of seconds (every 40/50 seconds).

There's a way to properly send/receive, or a better setup, or a GURU of Multisync, somewhere in this forum?

Some suggestion?

Lucka - gawteam coder - www.gawgames.com
Rudolpho
20
Years of Service
User Offline
Joined: 28th Dec 2005
Location: Sweden
Posted: 11th Sep 2014 01:56
It is hard to say what might cause that. Perhaps you have a memory leak in a buffer somewhere and it needs to reallocate resources behind the scenes causing some network stalling? If possible I would probably start by debugging things like that.
You probably should show your networking code, or at least the section that seemingly causes the trouble, though. Otherwise there's really no way to do more than guess at what the problem might be; I don't think it is anything inherent in MultiSync itself.


"Why do programmers get Halloween and Christmas mixed up?"
Ortu
DBPro Master
18
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 11th Sep 2014 03:16
If you are using timer based movement / updates, you should be able to handle small lag spikes gracefully with interpolation and client side prediction. In quick, general terms, each player should have the data needed to predict where everyone will be in the next second or two, like speed and direction, and when this prediction differs from the official positions coming from host or server, it can gradually correct to match over a couple of loops so there is less pausing, snapping, and rubber banding.

Lucka
21
Years of Service
User Offline
Joined: 1st Oct 2004
Location:
Posted: 11th Sep 2014 22:12
Code is actually send stuf like this:



i didn't wrote NOTHING at all about "synchronization"
just GET and PUT..

i am a TOTAL NOOB about TCP and all that stuff, it works for 30 seconds, than LAG then again working for 30 or 40 seconds..

i think that MAYBE GET this amount of "float" is too much, i wanna try to make the "weight" a little bit more light using INT instead of FLOATs..

how Multisync make the "sync" between GET and PUT?

I am a total noob

Lucka - gawteam coder - www.gawgames.com
Green Gandalf
VIP Member
21
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 11th Sep 2014 23:02
Quote: "I am a total noob"


Ten years is a long time to be in that state.



Powered by Free Banners
Lucka
21
Years of Service
User Offline
Joined: 1st Oct 2004
Location:
Posted: 12th Sep 2014 15:21
about TCP

Lucka - gawteam coder - www.gawgames.com

Login to post a reply

Server time is: 2026-07-18 09:24:52
Your offset time is: 2026-07-18 09:24:52