Performance issue

Got a problem with OpenTTD? Find some help here.

Moderator: OpenTTD Developers

Post Reply
tnck
Engineer
Engineer
Posts: 1
Joined: 08 Aug 2023 11:22

Performance issue

Post by tnck »

Hello,
do you have any significant solution for performance issue with openTTD ?
I run it on i7 older series 3.6gHz and my best frame rate is about 6.9 now.
And yes, there 5k trains size 20-30 tiles. (and I want more...)
OpenTTd_frame.jpg
OpenTTd_frame.jpg (25.89 KiB) Viewed 2819 times
Thanks!

tnck
_dp_
Transport Coordinator
Transport Coordinator
Posts: 278
Joined: 18 Dec 2013 12:32

Re: Performance issue

Post by _dp_ »

For 5k trains this looks about right, especially, if those are newgrf ones. OpenTTD isn't particularly performant.
Eddi
Tycoon
Tycoon
Posts: 8272
Joined: 17 Jan 2007 00:14

Re: Performance issue

Post by Eddi »

"not particularly performant"?? ever tried to run 5000 trains in transport fever? or simutrans?

or 5000 cities in civ6? 5000 inhabited planets in stellaris?
_dp_
Transport Coordinator
Transport Coordinator
Posts: 278
Joined: 18 Dec 2013 12:32

Re: Performance issue

Post by _dp_ »

I don't care about those games. What I care is that on a server with 10 good players games starts lagging after a few hours of gameplay.
Eddi
Tycoon
Tycoon
Posts: 8272
Joined: 17 Jan 2007 00:14

Re: Performance issue

Post by Eddi »

And i can't hear it anymore... "this game isn't optimized"... people say that about every game. and it's almost never true. what people mean is "this game doesn't let me go infinitely megalomanic"... which is an intrinsic problem of computers.
_dp_
Transport Coordinator
Transport Coordinator
Posts: 278
Joined: 18 Dec 2013 12:32

Re: Performance issue

Post by _dp_ »

There is nothing megalomaniac in playing the game for several hours. Also, JGRPP runs like 2-3 times faster than vanilla.
User avatar
odisseus
Director
Director
Posts: 568
Joined: 01 Nov 2017 21:19

Re: Performance issue

Post by odisseus »

Welp, this game is all about indulging in your megalomaniac urges. With all respect to the developers, I perfectly understand those people who complain about unbearable lag after having spent weeks to build an insane system with thousands of trains.
User avatar
Redirect Left
Tycoon
Tycoon
Posts: 7249
Joined: 22 Jan 2005 19:31
Location: Wakefield, West Yorkshire

Re: Performance issue

Post by Redirect Left »

odisseus wrote: 09 Aug 2023 19:47 I perfectly understand those people who complain about unbearable lag after having spent weeks to build an insane system with thousands of trains.
My guess is, the pathfinding gets pretty tiresome, and unfortunately pathfinding is one of the great CPU killers even today. I have experience with pathfinding in open world 3D games, and whilst OTTD has the benefit of not needing to check every direction possible (except for ships & aircraft, who can actually go in any direction, most are tracked and limited to where the track or road takes them), it'll still be a chore, especially given the single-threaded nature of OpenTTD. Even my i9-12900k gets slightly upset beyond around 6000, it can render out entire videos or compile code super fast, but it doesn't like keeping track of 6000 trains as it turns out.
Whilst its possible the pathfinders aren't coded 100% perfectly (honestly, the majority of code is rarely precisely perfect, even software on things you'd think is perfect like trains...), even if it was you're pushing the limit of a single core on any CPU after a while. I'm also unfamiliar with OpenTTD pathfinder code, its never come up in any of the bits of code I've needed to look at, so it may be the preferred pathfinder (there's more than one, though i presume the default selected is the best overall for nearly all use cases if not all) is still capable of being pushed a little further should anyone delve deep enough into it, should they be motivated to do so anyway. Either way, even a perfect one will struggle eventually on slower and/or older processors, and its possible the pathfinder(s) have already reached the point of effort vs benefit in terms of speeding them up all that much.

Unfortunately Chris Sawyer putting "will satisfy the megalomaniac in everyone" on the TTD box is far from the truth, I doubt he actually asked anyone if it did indeed satisfy their tendencies even on 1990s processors, turns out you can say basically anything on those things and to sell your stuff, look at Peter Molyneux's career...
Image
Need some good tested AI? - Unofficial AI Tester, list of good stuff & thread is here.
User avatar
kamnet
Moderator
Moderator
Posts: 8594
Joined: 28 Sep 2009 17:15
Location: Eastern KY
Contact:

Re: Performance issue

Post by kamnet »

odisseus wrote: 09 Aug 2023 19:47 Welp, this game is all about indulging in your megalomaniac urges. With all respect to the developers, I perfectly understand those people who complain about unbearable lag after having spent weeks to build an insane system with thousands of trains.
Keep in mind that OpenTTD already pushes the limits of the original game WELL beyond what was intended by Chris Sawyer. At some point we have to accept that we are but mere mortals and the game has limits on our capabilities. :)
User avatar
jfs
Tycoon
Tycoon
Posts: 1764
Joined: 08 Jan 2003 23:09
Location: Denmark

Re: Performance issue

Post by jfs »

Redirect Left wrote: 09 Aug 2023 20:43 Unfortunately Chris Sawyer putting "will satisfy the megalomaniac in everyone" on the TTD box is far from the truth, I doubt he actually asked anyone if it did indeed satisfy their tendencies even on 1990s processors, turns out you can say basically anything on those things and to sell your stuff, look at Peter Molyneux's career...
Transport Tycoon also did not have the tools to easily build gigantic networks with hundreds of trains, and did not have gigantic maps. On the computers of the day, the world and what you could fill into it already felt very large scale, in part because of the screen resolution of 640x480 limiting how much you could view at a time, meaning a distance of 60 tiles felt very long (and is indeed a quarter across the map.)
Eddi
Tycoon
Tycoon
Posts: 8272
Joined: 17 Jan 2007 00:14

Re: Performance issue

Post by Eddi »

i can tell you that my 1990s PC back then had 1 frame about every 2 seconds when i maxed out the 80 trains, busses, etc. the game would let me.

but the real problem is, no matter how "performant" the game is, there will always be a limit where the performance degrades. and people will always push up to and beyond that limit
Argus
Tycoon
Tycoon
Posts: 1204
Joined: 16 Oct 2018 08:31
Location: Heart of the Highlands. Not Scottish. Czech.

Re: Performance issue

Post by Argus »

The old Tycoon reliably destroyed mouse buttons, there was no click and drag to build a road or tracks across half the map, you had to click square by square.
Building a gigantic transportation network is much easier today, back then you could immediately buy a new mouse after playing a few maps.
Eddi
Tycoon
Tycoon
Posts: 8272
Joined: 17 Jan 2007 00:14

Re: Performance issue

Post by Eddi »

what? of course orignial TT had click&drag...
User avatar
jfs
Tycoon
Tycoon
Posts: 1764
Joined: 08 Jan 2003 23:09
Location: Denmark

Re: Performance issue

Post by jfs »

You could click and drag straight track, but not diagonal track. You also had to place every single individually. And there was no shared orders, no copying orders, and no copying consists.
Post Reply

Return to “OpenTTD Problems”

Who is online

Users browsing this forum: Bing [Bot] and 25 guests