Shield Generators


Adds turret shields and shield generators for civil structures.

Content
a month ago
1.1 - 2.0
29.9K
Combat

b Horrendous UPS

3 years ago

When you build a new base using bots, so say 50 turrets all in a short time, the UPS drop is really bad. It's such a shame as I loved the idea of this mod, but feels unusable with that sort of lag. I usually get about 50-60 UPS, but it drops to 10-15 while the battery and then shield charge. It's fine for a small number, but when you do a big build, it lags.. I don't know what happens if I get a base hit by crawlies yet, still to be seen,
As I said, real shame as I've been using Kings Turrets and really prefer this way of doing things, but if I can't play....

3 years ago

Nothing much can be done about it, when entities are built code iterate over all regular shield generators (not turret ones) to see if they are within shield generator or not, and if there are a lot of shield generators it can get very taxing.

The only solution here is to get a faster code execution environment from Wube, which is either LuaJIT or providing completely new one like .NET (C#) OR JDK

3 years ago

yeah, I understand. I wonder if rather than iterating round multiple times you're able to build a one-time table and then just working with that. I know that if you have a large number of objects created (especially with blueprint build), then you're going to have a problem. Another suggestion, can you maybe have a phased process, so if you build 50 objects, it processes them in batches so it charges the first 10, and then looks for the next 10 to charge ?
Just a thought.. It's a great mod, and reducing the UPS impact would make it even better

3 years ago

Unfortunately, I'm getting the same issue. I loaded it into my game and was getting 6 ups. Never even built a shield generator or researched it before I had to uninstall. I do have a particularly large map though.

New response