40 players, why and how.

Discussion in 'Planetary Annihilation General Discussion' started by Kola2, May 18, 2014.

  1. tylerseacrest

    tylerseacrest Member

    Messages:
    56
    Likes Received:
    19
    From my understanding this isn't quite correct. The simulation side is designed to be multi-threaded and uses the OS to que up tasks to send to the CPU. So allthough they have 8 games on an 8 core machine, they are all using all the cores, just not at the same time. Large player games didn't slow down as much as the other smaller games on the server because they simply send more tasks to the CPU so more cores were dedicated to the large player games.

    Example: Lets assume that each player create one task per tick. This is of course inaccuate but works as an example. Lets also assume that the server has 8 cores and two games, one with 14 players, game a, and one with 2 players, game b. If we further assume that all tasks take the same time to generate then the first tick the task list will look something like this: a, b, a, b, a, a, a, a, a, a, a, a, a, a, a, a. The first tick, the first 8 tasks will be completed and game b will be informed that a full tick has been completed and can add new tasks. So the task list now looks something like a, a, a, a, a, a, a, a, b, b. On the next tick, all the cores will be devoted to game a as it has the next 8 tasks in queue and game b dosn't get any prossesing power at all. This only gets worse as we add more players and more games.

    tl;dr: the sim is allready multi-threaded. In fact it is multi-threaded so well that entirely different sims can be running on the same comp without assigning them cores.
  2. planktum

    planktum Post Master General

    Messages:
    1,060
    Likes Received:
    510
    I don't see why we would want 40 player games when even 2 player games lag...
    bradaz85 and PhoneySpring646 like this.
  3. mered4

    mered4 Post Master General

    Messages:
    4,083
    Likes Received:
    3,149
    Because, AWESOME!
    stuart98 likes this.
  4. squishypon3

    squishypon3 Post Master General

    Messages:
    7,971
    Likes Received:
    4,357
    The most insane turtle fest of them all? ;)
  5. brianpurkiss

    brianpurkiss Post Master General

    Messages:
    7,879
    Likes Received:
    7,438
    Nah, once we get our proper invasion tools it'll be epic.
  6. cdrkf

    cdrkf Post Master General

    Messages:
    5,721
    Likes Received:
    4,793
    Source? What you're describing sound like standard os core management. The simulation needs to be able to spawn multiple threads and utilise multiple cores fully to be truly multi threaded and I've seen no evidence of that- I'm happy to be proven wrong though!
  7. SXX

    SXX Post Master General

    Messages:
    6,896
    Likes Received:
    1,812
    If I understand it correctly each planet can be easily simulated with own thread and this is main advantage of PA game design which make extremely large games possible. E.g you don't need to care to sync this stuff between CPU cores because units on different planets can't interact. Probably somebody from Uber talked about that, but I didn't remember where it's was.

    Though I didn't remember anything about actual per planet multi-threading and I suppose some tasks just can't be paralleled. Though it's should be easy to MT some specific tasks which not depend on game state: some physics, flocking, possible path finding.
    tatsujb and cdrkf like this.
  8. cwarner7264

    cwarner7264 Moderator Alumni

    Messages:
    4,460
    Likes Received:
    5,390
    I'm looking forward to the colossal 'drop-in, drop-out' games once the multiplayer Galactic War gets going.

    This thread was a nice read. Got me dreaming about the bright future this game has once its full potential is realised.
  9. brianpurkiss

    brianpurkiss Post Master General

    Messages:
    7,879
    Likes Received:
    7,438
    Yeah, the clan wars are gonna be pretty awesome.
    Kola2 likes this.

Share This Page