power supply beams

    Joined
    Jun 15, 2014
    Messages
    914
    Reaction score
    77
    • Legacy Citizen
    What is the best set up for power supply beams that doesn't' cause a lot of lag because it seems like power supply beams stop getting better at a certain point.
     
    Joined
    Jun 19, 2014
    Messages
    1,756
    Reaction score
    162
    • Purchased!
    • Top Forum Contributor
    • Legacy Citizen
    Salvage slave effects are going to be fixed. Don't know if any progress is being made with the other non-damage beams.
     
    Joined
    Aug 23, 2013
    Messages
    379
    Reaction score
    65
    What is the best set up for power supply beams that doesn't' cause a lot of lag because it seems like power supply beams stop getting better at a certain point.
    The most efficient way (for "power per block") is to design power cells to generate about 1 million e/sec (and make them long and thin) so you get the most out of the "XYZ frame bonus". Once you go above that and aren't getting the"XYZ frame bonus", then you're better off just putting the power reactor blocks on the mothership instead. This means that if you want (e.g.) an additional 50 million e/sec from power cells, then you're going to need 50 power cells to do it.

    Also note that you need space between the lines of power reactor blocks (so they don't touch), and can fill that empty space with shield regenerators and slap a shield supply beam on the power cell too. This only sort of works a little; because when the shield supply beam fires the cell decides it's "under fire" and its shield regen drops to between 5% to 10% of what it would've been; so you only get a small amount of shields to inject into the mothership (e.g. I got about 5 thousand s/sec from each of my power cells, in addition to the 1 million e/sec).

    However; for server load, the more power cells you've got running the more server load you're causing. My experimentation showed that the majority of the server lag is caused by the beams themselves.

    I had 36 power cells, each with 2 power supply beams and one shield supply beam (and a logic clock built into the cell to keep the beams firing). That's 36*3 = 108 beams. The end result was the server updates the sector about 10 times per second and complains about "sector update taking 50 ms+" each time (and the red "server no responding" warning popping up in the client constantly). If you do the math that's half a second of processing time every second. My power cells have a button on the front to turn the logic clock and beams on/off. Turning them all off (and changing nothing else) fixed the server lag completely, so I know the lag had nothing to do with the number of docked ships/cells or anything like that.

    I changed to 24 power cells with one power supply and one shield supply beam for each cell (or, 24*2 = 48 beams). That significantly reduced the load on my server.

    Note: Server is on my LAN (not on the internet) and is not doing anything else (I use a different computer for the game's client), and should be overkill (12 GiB of RAM, 16 CPUs, gigabit ethernet connection to client).
    Based on the above; for beams, I'd estimate that StarMade's code is at least 100 times slower than it should be.

    What this mostly means is that (for single player) you never want to go above about 50 beams total. For multi-player servers on the internet (where there's more people playing and more server load) you probably shouldn't go above 20 beams total on a good server (e.g. maybe 10 cells with power and shield beams; or 20 cells with power beam only). For cheap StarMade game servers (e.g. where a physical server is running multiple virtual machines, and Starmade is running on one of them and only getting part of the real server) you probably shouldn't use more than 10 beams total.
     
    Joined
    Sep 15, 2013
    Messages
    267
    Reaction score
    63
    You need about 4000 power supply beams (no slave weapons) to transfer 1 mil e/sec

    *edit*
    4000 beam blocks on a single beam*