Game Development Community

Client Connection And Server RAM

by Scott Doerrfeld · in Torque Game Engine · 05/08/2007 (5:44 pm) · 2 replies

I've been tracking the amount of memory taken up on the dedicated server by each client connection. The memory goes up anywhere from 0MB to about 2MB per each client connection. It's strange to me how variable it can be - one time it'll go up 124kB and another time it'll go up 1116kB, both from the same client machine. I thought it would be more consistent. Can anyone tell me the reason for this? Is there a way to simulate a high number of client logins without having to physically login from several different machines?

#1
05/09/2007 (12:52 pm)
What exactly is being stored server side for each login that takes up this memory?
#2
05/09/2007 (1:06 pm)
One possible explanation for the discrepencies that you are seeing is that each client is going to have different objects in the world ghosted to them depending on where they are located and the server has to keep track of these for each client.

For example, a client who spawns way out in the middle of no where and is facing away from everything else in the mission is only going to have the Terrain, the Interiors, the Water, and maybe whatever Items/ShapebaseImages he is carrying on his person. So his memory footprint at that point is going to be lower. As soon as he moves closer to "town" he then starts receiving ghosts for the other ghostable items in the world like ammo packs, health packs, other players, ai bots, RigidShapes, StaticShapes, and so on. His memory footprint will then begin to grow quite a bit.

Likewise, if you have a client spawn in "town" then he will start with a much larger memory footprint than a client who spawns far away from everything.