StarMade Dev Update: Infinite Universe

    schema

    Cat God
    Joined
    Feb 17, 2012
    Messages
    1,552
    Reaction score
    2,604
    • Schine
    Hi,
    I just wanted to post a quick update about the development progress of StarMade. As some of you know, I'm currently working on expending the universe, so the player can fly out and visit different systems and locations.

    It's working better than expected so far (I rarely can say that), but there will probably still be a lot of unforeseen barriers, that will have to be overcome. A universe location (Star System, Nebula, Asteroid field, etc...) will be called "Sector" in the game. Sector switching has just been implemented, which is probably the most important aspect of an infinite universe.

    The client will also immediately free the resources (pushing it to disk as a cache) of old sectors to save memory: this will ensure, that the clients will scale very well. The server will check, if there is any activity on an active sector. if there is no player activity for a while, it will push the data back to the disk. Because the universes will be huge, updating for inactive sectors will be disabled: This means, its state will essentially freeze (the bad thing about that is, that for example the recyclers won't be able update during that period, also AI activity will be a problem)

    The first playable version with infinite Universes will hopefully be done by the end of this week. I probably have to deactivate DeathMatch and CoopDeathMatch for a little bit, until I have it adapted to the new universe layout. Also, be sure to save any important ships, before you update, since the update will most likely require a reset of the database.

    Thanks for playing StarMade,
    - schema
     

    schema

    Cat God
    Joined
    Feb 17, 2012
    Messages
    1,552
    Reaction score
    2,604
    • Schine
    First infinite test flight was successful. I almost cannot believe, that it works after only 12 hours of coding. Also the scaling works quite well. the memory use has never gone above 450 MB.


    There are still some issues though like a tiny little bit of lag when changing sectors (only when new Sectors are created (I got to do that slowly as the player approaches a new sector so he won't be bombarded with a lot of new objects at once)).

    I also have to change the players position back in a cycle (since a players position cant be indefinitely high. I'm dealing with this by setting the context for each item individually e.g. snapping them back to 0.123 in the new sector if they leave the old sector by sectorSize + 0.123.