Auto Adjusting Net_Lag Mod (Testing Purposes)

Everything about mods can be found here.

Moderator: Morax

Auto Adjusting Net_Lag Mod (Testing Purposes)

Postby Duck_42 » 18 Jun 2013, 03:58

Yesterday, Zock asked me to look into coding something that would automatically reduce the net_lag value in FA games based on in-game pings. It seemed like an interesting concept to me, so I took a quick look at it and threw this together.

:!: WARNING :!:
This is a test version of this mod. It may not work right, so use it at your own risk.

Auto-Adjust-NetLag v0.3.zip
Auto Adjust NetLag v0.3
(4.37 KiB) Downloaded 213 times


Please post feedback and report any bugs on this thread.


The end goal is to incorporate this into FAF. The standalone version is merely for testing purposes and will not be needed after the change is added into FAF (unless you want to play vanilla FA with your friends in your own little corner of the Internet).
Last edited by Duck_42 on 27 Jul 2013, 17:28, edited 2 times in total.
User avatar
Duck_42
Avatar-of-War
 
Posts: 237
Joined: 29 May 2012, 03:16
Has liked: 5 times
Been liked: 18 times
FAF User Name: Duck_42

Re: Auto Adjusting Net_Lag Mod (Testing Purposes)

Postby Ze_PilOt » 18 Jun 2013, 08:00

Be careful that everyone has to use the same value. So you need to put the highest ping in the sync table so each client use the same highest one every XX seconds.

Decreasing it requires more bandwidth (as more command are handled per second) and so can lead to shuttering rather quickly on 4v4 and more. So you need a way to detect shuttering to re-increase it when it happen.

One way to detect it is to check the in game time and the real time : if it lower while the sim still run at +0, you shutter. But it can be induced by pausing the game, ... so ... I don't know, but it's more complicated than it seems.
Nossa wrote:I've never played GPG or even heard of FA until FAF started blowing up.
User avatar
Ze_PilOt
Supreme Commander
 
Posts: 8985
Joined: 24 Aug 2011, 18:41
Location: fafland
Has liked: 18 times
Been liked: 376 times
FAF User Name: Ze_PilOt

Re: Auto Adjusting Net_Lag Mod (Testing Purposes)

Postby Zock » 18 Jun 2013, 10:10

:)

do all players need the mod or only one?
gg no re

ohh! what a pretty shining link! https://www.youtube.com/c/Zockyzock
User avatar
Zock
Supreme Commander
 
Posts: 1395
Joined: 31 Aug 2011, 22:44
Has liked: 173 times
Been liked: 397 times
FAF User Name: Zock

Re: Auto Adjusting Net_Lag Mod (Testing Purposes)

Postby Ze_PilOt » 18 Jun 2013, 10:39

All players need it because all players need to use the same value (don't ask what happen if they don't).
Nossa wrote:I've never played GPG or even heard of FA until FAF started blowing up.
User avatar
Ze_PilOt
Supreme Commander
 
Posts: 8985
Joined: 24 Aug 2011, 18:41
Location: fafland
Has liked: 18 times
Been liked: 376 times
FAF User Name: Ze_PilOt

Re: Auto Adjusting Net_Lag Mod (Testing Purposes)

Postby Ze_PilOt » 09 Jul 2013, 11:16

I guess nobody tested it?
Nossa wrote:I've never played GPG or even heard of FA until FAF started blowing up.
User avatar
Ze_PilOt
Supreme Commander
 
Posts: 8985
Joined: 24 Aug 2011, 18:41
Location: fafland
Has liked: 18 times
Been liked: 376 times
FAF User Name: Ze_PilOt

Re: Auto Adjusting Net_Lag Mod (Testing Purposes)

Postby Zock » 09 Jul 2013, 12:06

When i tested with crazed, he got a blackscreen each time the mod was enabled. Everything fine for me though.
gg no re

ohh! what a pretty shining link! https://www.youtube.com/c/Zockyzock
User avatar
Zock
Supreme Commander
 
Posts: 1395
Joined: 31 Aug 2011, 22:44
Has liked: 173 times
Been liked: 397 times
FAF User Name: Zock

Re: Auto Adjusting Net_Lag Mod (Testing Purposes)

Postby Ze_PilOt » 09 Jul 2013, 12:18

Logs?
Nossa wrote:I've never played GPG or even heard of FA until FAF started blowing up.
User avatar
Ze_PilOt
Supreme Commander
 
Posts: 8985
Joined: 24 Aug 2011, 18:41
Location: fafland
Has liked: 18 times
Been liked: 376 times
FAF User Name: Ze_PilOt

Re: Auto Adjusting Net_Lag Mod (Testing Purposes)

Postby Zock » 09 Jul 2013, 14:36

D3z4rC:
warning: Error running '/lua/ui/game/gamemain.lua:OnBeat': ...ed alliance\gamedata\lua.scd\lua\ui\game\avatars.lua(1029): attempt to call method `Hide' (a nil value)
D3z4rC:
stack traceback:
D3z4rC:
this is the error

does that help?
gg no re

ohh! what a pretty shining link! https://www.youtube.com/c/Zockyzock
User avatar
Zock
Supreme Commander
 
Posts: 1395
Joined: 31 Aug 2011, 22:44
Has liked: 173 times
Been liked: 397 times
FAF User Name: Zock

Re: Auto Adjusting Net_Lag Mod (Testing Purposes)

Postby Ze_PilOt » 09 Jul 2013, 14:37

A complete log would be better.
Nossa wrote:I've never played GPG or even heard of FA until FAF started blowing up.
User avatar
Ze_PilOt
Supreme Commander
 
Posts: 8985
Joined: 24 Aug 2011, 18:41
Location: fafland
Has liked: 18 times
Been liked: 376 times
FAF User Name: Ze_PilOt

Re: Auto Adjusting Net_Lag Mod (Testing Purposes)

Postby CrazedChariot » 09 Jul 2013, 14:39

Logs
Attachments
game.log
(167.8 KiB) Downloaded 140 times
User avatar
CrazedChariot
Contributor
 
Posts: 141
Joined: 02 Sep 2011, 13:13
Has liked: 0 time
Been liked: 32 times
FAF User Name: CrazedChariot

Next

Return to Mods & Tools

Who is online

Users browsing this forum: No registered users and 1 guest