Freelancer Community Network
Reminder: Internet Explorer 6 or below are NOT supported.
HomeHome
ForumForum
WikiWiki
DownloadsDownloads
ForgeForge
Multiplayer Connection Tutorial
Collapse/Expand Random Image
Collapse/Expand Login
Username:

Password:

Remember me



Lost Password?

Register now!
Collapse/Expand Chat
Collapse/Expand Who's Online
94 user(s) are online (66 user(s) are browsing Forum)

Members: 0
Guests: 94

more...
Collapse/Expand Donations
Monthly costs: -30€
Income (ads): +5€
Donations (last month): +10€

Current balance: -300€
(last updated 11/2017)

Please make a donation if you want to help keeping The-Starport online:

Bitcoin address:
Thanks!
Collapse/Expand Links
Collapse/Expand Advertisement
There are currently 101 users playing Freelancer on 34 servers.
November. 22, 2017

Browsing this Thread:   1 Anonymous Users



 Bottom   Previous Topic   Next Topic  Register To Post



Update rate fluctuation?
Starport Admin
Joined:
2009/2/21 21:42
Group:
Webmasters
Registered Users
Posts: 3457
Offline
So we've been attempting to debug some issues with varying maneuverability apparently tied to frame rates. Low frame rate (sub-30) makes ships much slower to turn, while very high frame rates (over 90) makes ships faster and also makes them stutter about.

Now, I'm not exactly sure what could be causing this, but one thing I noticed while debugging is that IServer::Update is being called with a varying spacing. In fact, I can get it myself to vary between 15-16 (the expected value) to 31-32 (double that) to even 46-47 and 0.

In windowed mode at 144Hz (framerate varying between 120 and 144), I get 50% of all ticks as 0 spacing and most of the rest at 16 and 15. At 60Hz, 15 and 16 make up well over 90% of all ticks. At 24Hz, it's all over the place, with 31-32 leading, then 46-47, then 0 and 15-16, each making up between 20-40%.

Now, as far as I know, Freelancer expects this to be called 60 times per second flat. If my measurements are correct, this is most certainly not the case.

I'd rather not limit framerate to 60 at all times (though I will if that's necessary), but I'd like to know what in the hell could possibly cause the update calls to change in such a manner because of frame rate differences?

EDIT: Some digging indicates that FL correctly uses the performance counter (that's what the Timing class uses), so the base timer is accurate and reliable enough not to be the cause. This means that the likely source of the problem is the caller for IServer::Update, which appears to be sub_5A89B0 in Freelancer.exe. The logic resembles a standard game loop, but there's a few things I'm not sure about yet.

Posted on: 2015/9/9 7:37

Edited by FriendlyFire on 2015/9/9 19:17:01
Edited by FriendlyFire on 2015/9/9 19:17:22
"Cynicism is not realistic and tough. It's unrealistic and kind of cowardly because it means you don't have to try."
-Peggy Noonan
Top