Patch memory leak?

Got a problem with TTDPatch? Get help here.

Moderator: TTDPatch Moderators

Post Reply
User avatar
krtaylor
Tycoon
Tycoon
Posts: 11784
Joined: 07 Feb 2003 01:58
Location: Texas, USA
Contact:

Patch memory leak?

Post by krtaylor »

I've played with Windows TTD and the Patch for a long time, and often use the normal Windows ability to Alt-Tab out of TTD and go do something else, before returning to the game. The game just says minimized on the taskbar like any other program would, and when you click on it, it goes back to fullscreen. It'll even play that way if you forget to pause first.

Since installing a45, I've had problems with doing this. I can minimize a game and do other things, but the computer seems to be VERY VERY SLOW, particularly with things that I am accessing across the network - both Internet browsing, and network file accesses. Some things won't work at all - CuteFTP often jams up saying all connections are in use. So I think there's something wrong in the Patch somewhere. Has somebody been working on multiplayer? Naturally I'd like to see multiplayer working properly. That's the only thing I can think of in TTD which might affect the network.

I've got plenty of memory and haven't changed things recently. I know TTD is the problem because when I quit the game properly, everything starts working at its usual speed again.
Development Projects Site:
http://www.as-st.com/ttd
Japan, American Transition, Planeset, and Project Generic Stations available there
Patchman
Tycoon
Tycoon
Posts: 7575
Joined: 02 Oct 2002 18:57
Location: Ithaca, New York
Contact:

Post by Patchman »

Have you checked the task list to see how much memory the game is using?

In principle, the game should not allocate any additional memory when it's gotten to the point that it can display the title menu. At that point, all the memory that will ever be used has been allocated.
Josef Drexler

TTDPatch main | alpha/beta | nightly | manual | FAQ | tracker
No private messages please, you'll only get the answering machine there. Send email instead.
User avatar
wallyweb
Tycoon
Tycoon
Posts: 6102
Joined: 27 Nov 2004 15:05
Location: Canada

Post by wallyweb »

Did you try turning off all the network items in the patch? I don't play network games so I have the network items set to off and I don't have any speed issues until I reach about 150 vehicles on my 300Mhz 192MB Windows 98 PC. If setting the network stuff to off and your game improves then I think you'll have nailed it.
User avatar
krtaylor
Tycoon
Tycoon
Posts: 11784
Joined: 07 Feb 2003 01:58
Location: Texas, USA
Contact:

Post by krtaylor »

Maybe I wasn't being clear. The game plays fine. The problem is everything else in the computer when the game is minimized. Particularly other things pertaining to the network.

How do I turn off the network elements of TTD? Multiplayer doesn't work at all anyway so I might as well. (At least it doesn't work at all for me.)

I'll look and see what it's using for memory, but I don't think that's necessarily the problem, as I have loads. The network is behaving like it has a major latency delay, which wouldn't necessarily be memory related.
Development Projects Site:
http://www.as-st.com/ttd
Japan, American Transition, Planeset, and Project Generic Stations available there
Patchman
Tycoon
Tycoon
Posts: 7575
Joined: 02 Oct 2002 18:57
Location: Ithaca, New York
Contact:

Post by Patchman »

krtaylor wrote:I'll look and see what it's using for memory, but I don't think that's necessarily the problem, as I have loads. The network is behaving like it has a major latency delay, which wouldn't necessarily be memory related.
Then I suggest you should've picked a different topic title ;)

Anyway, I very much doubt the network code is doing anything if you're not playing a network game. But do check the CPU and memory usage with TTD minimized.
Josef Drexler

TTDPatch main | alpha/beta | nightly | manual | FAQ | tracker
No private messages please, you'll only get the answering machine there. Send email instead.
User avatar
krtaylor
Tycoon
Tycoon
Posts: 11784
Joined: 07 Feb 2003 01:58
Location: Texas, USA
Contact:

Post by krtaylor »

Well, I did a little more playing after I first posted the problem...

So nobody else has seen anything odd? Interesting. I'll take a look at the CPU and memory next time I play.
Development Projects Site:
http://www.as-st.com/ttd
Japan, American Transition, Planeset, and Project Generic Stations available there
User avatar
krtaylor
Tycoon
Tycoon
Posts: 11784
Joined: 07 Feb 2003 01:58
Location: Texas, USA
Contact:

Post by krtaylor »

OHO. When TTD is running, but paused, and minimized, then my CPU usage is...

100%.

Memory usage is 377MB.

I can watch the little CPU usage graph. When I switch back into TTD, the CPU usage goes down to maybe 80%, then when I switch back it goes back up to 100%. It doesn't seem to matter whether TTD is paused or not.

When I quit TTD, the CPU usage goes down to a more normal 1% - 35%, depending on what I'm doing.

So there are three interesting things here:

1. Why does TTD take so much of the CPU?

2. Why does TTD take so much of the CPU when it's minimized?

3. Why does TTD take so much of the CPU when it's paused?

I can understand that it's CPU intensive when it's running. But when it's paused, it shouldn't be, and when it's minimized when not paused, at least it doesn't have to display the graphics, so should need less.
Development Projects Site:
http://www.as-st.com/ttd
Japan, American Transition, Planeset, and Project Generic Stations available there
Patchman
Tycoon
Tycoon
Posts: 7575
Joined: 02 Oct 2002 18:57
Location: Ithaca, New York
Contact:

Post by Patchman »

What's your miscmods.notimegiveaway setting (bit 13)? Try setting miscmods.notimegiveaway off to make sure the game does not use the CPU when it's idle.
Josef Drexler

TTDPatch main | alpha/beta | nightly | manual | FAQ | tracker
No private messages please, you'll only get the answering machine there. Send email instead.
User avatar
krtaylor
Tycoon
Tycoon
Posts: 11784
Joined: 07 Feb 2003 01:58
Location: Texas, USA
Contact:

Post by krtaylor »

Is it possible to use miscmods settings without having the Configurator screw up, like happened when I tried to turn town sizes on?
Development Projects Site:
http://www.as-st.com/ttd
Japan, American Transition, Planeset, and Project Generic Stations available there
Prof. Frink
Tycoon
Tycoon
Posts: 3849
Joined: 20 Jan 2003 14:51
Location: Broadstone, Dorset
Contact:

Post by Prof. Frink »

<Standard response>
Don't use the configurator
</Standard response>
User avatar
krtaylor
Tycoon
Tycoon
Posts: 11784
Joined: 07 Feb 2003 01:58
Location: Texas, USA
Contact:

Post by krtaylor »

<Standard response>
Pfui.

Fix the Configurator, maybe.
</Standard response>
Development Projects Site:
http://www.as-st.com/ttd
Japan, American Transition, Planeset, and Project Generic Stations available there
Patchman
Tycoon
Tycoon
Posts: 7575
Joined: 02 Oct 2002 18:57
Location: Ithaca, New York
Contact:

Post by Patchman »

Well, the configurator will certainly support that particular bit, and since it's only for testing, why don't you make a backup of your ttdpatch.cfg and try it out...
Josef Drexler

TTDPatch main | alpha/beta | nightly | manual | FAQ | tracker
No private messages please, you'll only get the answering machine there. Send email instead.
DaleStan
TTDPatch Developer
TTDPatch Developer
Posts: 10285
Joined: 18 Feb 2004 03:06
Contact:

Post by DaleStan »

krtaylor wrote:Pfui.

Fix the Configurator, maybe.
Well yeah. That's what I keep telling Andrex.

I'd probably do it myself if it were GPLed -- Oh wait. No I wouldn't. Someone else already would have.
To get a good answer, ask a Smart Question. Similarly, if you want a bug fixed, write a Useful Bug Report. No TTDPatch crashlog? Then follow directions.
Projects: NFORenum (download) | PlaneSet (Website) | grfcodec (download) | grfdebug.log parser
User avatar
krtaylor
Tycoon
Tycoon
Posts: 11784
Joined: 07 Feb 2003 01:58
Location: Texas, USA
Contact:

Post by krtaylor »

How can I tell if the miscmods parameter is working? It didn't appear to have any effect.

I'm actually quite confused about how to use those parameters. If I enter them in the Configurator with a space, the configurator automatically replaces the space with an equals = . At one time, you said the Patch wouldn't recognize them that way, but now it does? Because that time I tried to manually enter the command in the CFG file with a space, and no equals, my CFG file was destroyed.

So really I do not know how to use those parameters properly, with or without the configurator. All I've tried is entering it in the Configurator, which at least doesn't destroy the CFG, but I have no confidence that that particular parameter is actually working.
Development Projects Site:
http://www.as-st.com/ttd
Japan, American Transition, Planeset, and Project Generic Stations available there
User avatar
krtaylor
Tycoon
Tycoon
Posts: 11784
Joined: 07 Feb 2003 01:58
Location: Texas, USA
Contact:

Post by krtaylor »

Not to be a pest but I'd like to get to the bottom of this. I put the switch in, but it had no effect, and I'd like to know if there's a way to know it's working. Listing the parameters at the beginning doesn't give miscmods details.
Development Projects Site:
http://www.as-st.com/ttd
Japan, American Transition, Planeset, and Project Generic Stations available there
Patchman
Tycoon
Tycoon
Posts: 7575
Joined: 02 Oct 2002 18:57
Location: Ithaca, New York
Contact:

Post by Patchman »

It will show that in a46.
Josef Drexler

TTDPatch main | alpha/beta | nightly | manual | FAQ | tracker
No private messages please, you'll only get the answering machine there. Send email instead.
User avatar
krtaylor
Tycoon
Tycoon
Posts: 11784
Joined: 07 Feb 2003 01:58
Location: Texas, USA
Contact:

Post by krtaylor »

OK, I'll wait for a46 and test it some more then. That will also work with both = and space, right? So we'll eliminate both potential problems and figure out why I'm at 100% CPU even while paused. I take it that nobody else has noticed this? I know it wasn't like that in previous alphas, it must be a new issue. Hopefully it isn't caused by the larger graphics capabilities.
Development Projects Site:
http://www.as-st.com/ttd
Japan, American Transition, Planeset, and Project Generic Stations available there
Post Reply

Return to “Problems with TTDPatch”

Who is online

Users browsing this forum: No registered users and 22 guests