Need a standalone server!

Place them in different positions on the BGE server. Problem solved.

Interactions are still happening on the server side, but are calculated in global space. In the BGE, that would imply doing physics calculations with floats and objects scaled down 10^15 times at least!

The game simulates seamless travel through the galaxy, I need at least 64bit physics accuracy to run stuff on a beefy server on a BGE server. At least I think so!
No. You can simulate two areas that are light years apart, only a few blender units away from each other:


 BGE Server
 +-------------------------------------------------------+
 |                                                       |
 |                                                       |
 |                                                       |
 |        Planet A                   Planet B            |
 |        +------------+             +------------+      |
 |        |            |             |            |      |
 |        |            |             |            |      |
 |  100 bu|            |    Origin   |            |      |
 |        |            |<-----+----->|            |      |
 |        |            |             |            |      |
 |        |            |             |            |      |
 |        +------------+             +------------+      |
 |             100 bu                                    |
 |                                                       |
 |                                                       |
 +-------------------------------------------------------+

It’s called segmentation - local BGE space that simulates small chunks of user populated global space.

Actually, the logic tick rate is just a cap, which can be changed, but I wouldn’t recommend it; there’s no need to waste processing time in that fashion - if the time required to process all the logic overshoots the cap, blender won’t wait to start the next iteration.

So, it won’t hurt you under stressful conditions, and it will only help you otherwise.

The various other calculations that the BGE does can be a potential issue, but even with those inefficiencies, it’s still quite a bit faster than any kind of “external” python server setup, which introduces new layers of unnecessary overhead by relegating state management to clients.

If you need any clarification on ideas pm me. I could recommend my multipy library - http://code.google.com/p/multipy which handles all the connections, though it is only a dumb repeater that may not suit the style requirements of your game
Thanks, but I don’t need a dumb repeater.

I’m more interested in intelligent systems.

Place them in different positions on the BGE server. Problem solved.

Not quite!
If the team is spread across the planet section, that will be the limit of the BGE tolerance space 100.000 BU, remember that its a space game, player will use ships and travel quickly across the planet side. And that is just the example of 2 team, there might be hundreds of teams spread across the galaxy some on asteroid fields or moons, NPC, Buildings, etc. There’s a limit to use segments, even if scaled down. Besides, all segments would need to spawn a terrain mesh, and will need to simulate the planet’s gravity, that’s a lot of stress over the BGE, even for a few objects in the scene.
Even with a collision mask system, I’d still have all these objects colliding and not colliding, with the objects on other planets.
Even if all player could fit in a BGE server, the physics engine wouldn’t be able to calculate collisions happening in such a scale.
That’s why I mentioned before, that it’s impossible to reproduce the world in the server side.
Besides, for now, I just need a stand alone server to register, log in and spawn avatars.
What I have in mind is to use a main server to control to whom the player will send their info. The server receives position/orientation from the clients, then make a list of the closest objects then the client will send/receive commands from them. Each client has server capabilities, in other words, some sort of P2P hybrid.

No, you wouldn’t have to load in a big terrain mesh, only the small segment of the area where the players are actually present - you don’t have to worry about visual details on the server, you just need to resolve basic collision, physics and logic in that small area.

Even if all player could fit in a BGE server, the physics engine wouldn’t be able to calculate collisions happening in such a scale.
Yes, it would, because you won’t simulate areas of the universe that players are not interacting with - those segments don’t exist until they actually need to, and they can be very small, because you don’t have to produce a pretty picture on the server.

That’s why I mentioned before, that it’s impossible to reproduce the world in the server side.
No, it’s possible, and it’s also a much more effective system for consistent shared state, but you should try your “P2P hybrid” idea, just to see how it breaks down.

PS:

When I say “Server”, I don’t necessarily mean “your own dedicated machine/s that run an instance of blender” - that would be ideal if you want to ensure that people can’t cheat, but if you don’t really care about that, you can make certain clients into servers, and they could simulate a segment of the greater universe for the people in the same area.

As long as you avoid ridiculous “P2P” schemes that let each client generate his/her own state, that would work just as well.

No, you wouldn’t have to load in a big terrain mesh, only the small segment of the area where the players are actually present - you don’t have to worry about visual details on the server, you just need to resolve basic collision, physics and logic in that small area.

Exactly, if they are scattered, I’ll have to load the terrain map they are on, each one of them. The close up terrains are small, but have details like rocks and sometimes trees, buildings, NPC. I quickly adds up for 100 players, even on the same planet.

Yes, it would, because you won’t simulate areas of the universe that players are not interacting with - those segments don’t exist until they actually need to, and they can be very small, because you don’t have to produce a pretty picture on the server.

I’m not even thinking about rendering, if that were to happen, first, the planet’s surface would be mostly flat, that was the idea a while ago, so that the terrain patch would just have a radius, a cubes would represent obstacles. It’s really the physics part I’m worried about. Just having a few dynamic objects moving in a basic scene is dangerous. If distances and collisions(bullet hit) were to be calculated as well and other physical interactions, the game would be limited to 500 to 1000 users top.

Yes, it would, because you won’t simulate areas of the universe that players are not interacting with - those segments don’t exist until they actually need to, and they can be very small, because you don’t have to produce a pretty picture on the server.

I was even thinking of using various servers for different sectors of the galaxy, and as explained above, the empty spaces don’t even matter, even if the whole galaxy with planets and rocks could fit in a BGE scene, it’s the physical objects I’m worried about. The server would have to do lots of physics calculations, since all objects will be performing some sort of action, including NPC. Most games have planar based levels. In mine, they are spherical so, there the spherical gravity that has to be applied differently on every terrain section!

No, it’s possible, and it’s also a much more effective system for consistent shared state, but you should try your “P2P hybrid” idea, just to see how it breaks down.

True! And I wish it was really possible (I’m not ignoring all the arguments presented here) for this scale, I’ll study more on how Infinity will be doing it!

Actually far below that number - the bandwidth would likley be too high

Indeed! I wasn’t even mentioning the bandwidth yet! Just having 300 dynamic objects is a logic stress, add to that network stress!
If the game gets fun, more might want to join, so a P2P solution is more flexible.
I’m not too worried about cheating because, the game is more Player vs NPC. Well, nothing actually prevents player from turning against each other! So what are the cheating possibilities and its dangers?
What can cause lag?

I have to identify the lag in my setup. Im not yet sure if it is the networking code or the plugin code, but I think that it is probably the latter. If you have a custom implementation of data handling you should be fine. If you wait a day or so I will be updating my server so that you can use it for more than just one application.

The lag might be caused by the BGE!
In version 4 of the WSAG setup, we had a 1/10th of a sec delay no matter what the connection conditions. Earlier versions had even longer delays.

If you wait a day or so I will be updating my server so that you can use it for more than just one application.

That’s great (whatever you mean with that)! Err… do you mean your network setup or your physical server?
So, I still can’t run the python server! Is there a line I need to use to keep it alive? Or it just needs to be error free?

What i experience is drastic slowdown with > 4 clients. I firmly believe that this is solveable.
however, in terms of server; i’d like to offer my library. As soon as it’s done, it wiill be designed as a base class.
It’s basically a python server - but it is easy to use. I’ll post a link when done.

Well, check if the slowdown is Logical or network. I could share WSAG4 with you, if you like, even if it’s a WIP,… I don’t know you might learn something with it. I think Oldjim solved the slowdown problem!
I’d like to see you server, thank you very much!

It’s logical, but it may be caused between sending and receiving packets, and not interpreting them.