Author Topic: Civilian Industries  (Read 35791 times)

Offline StarKeep

  • Jr. Member Mark II
  • **
  • Posts: 79
Re: Civilian Industries
« Reply #30 on: January 28, 2020, 07:12:16 pm »
The command thing is fairly normal. Thats not a per second value, but rather the total number of commands since the save has been loaded (or the game has started, one or the other.) Consider thats the command count for an hour of gametime. Its very high, for sure, but this mod also needs to constantly redirect trade units. Unlike military, they can't simply be left alone upon arriving at a planet with AttackerFull.

The real issue is probably coming from be incorrectly drawing units from a grabbag (what the ai uses to divide its units up). I had, uh. Used the function that failed to replace the items in it.

Fixing it up, won't break your save, but will take a bit to confirm its working before releasing it, as it will cause the raid waves to be... beefier.
« Last Edit: January 28, 2020, 07:48:49 pm by StarKeep »

Offline StarKeep

  • Jr. Member Mark II
  • **
  • Posts: 79
Re: Civilian Industries
« Reply #31 on: January 28, 2020, 07:44:09 pm »
Civilian Industries - V 0.4.1 - Polite Raiding
Save Compatible with 0.4.0 Download In Main Updated

Fixed a bug where every ship used to raid with was semi-permanently removed from the AI as a choice.

Fixed a bug for militia ships where they may fail to find an optimal place to path to for an Outpost location.

Removed a bit of debugging code left in from the fleet-removing overhaul. (I missed one related to trading, whoops.)

Offline StarKeep

  • Jr. Member Mark II
  • **
  • Posts: 79
Re: Civilian Industries
« Reply #32 on: January 30, 2020, 02:11:22 pm »
So the amount of calculations that the mod does every second ended up getting to fairly obscene levels in regards to unit spawning. Every second every single Patrol Post and Outpost had to do the following for EVERY resource they've gotten at least one of:

If they don't have a unit type yet, get one.
Calculate the capacity for the unit type based on its strength, the current AIP, and the faction's Intensity.
Scan adjacent planets for player placed buildings that modify said capacity.
-Due to these being placed by the player, and me not having a way to do something after its been built, the only way was to loop through every special entity on adjacent planets. Not ideal.
Calculate current ship count. (# of entities + # of stacks in each entity)

The swap away from fleets really ended up being the breaking point for this, requiring me to do manual unit counts. Again, not bad individually, but these are done upwards of 12 times per second per planet per resource. Complete insanity. This is on top of having to also process trade requests, and properly route trade ships to answer said trade requests.

As a result, I'm going to be working on converting Patrol Posts and Outposts to dynamically spawn ships based on stored resources in response to threat. Outposts will begin rapidly building turrets when they detect an incoming wave or threat appears. Patrol Posts will do the same, as well as preparing pseudo-waves of ships to attack adjacent planets, instead of their old pathing logic. (Militia HQ will have a slight rework in functionality as a result from these changes, but they will still revolve around Battlestations.)

Another notable improvement for the next version will involve separating Import and Export requests into separate lists, instead of populating the same list with a modifier differentiating them. This will allow me to break off trade request processing far earlier on.

Offline StarKeep

  • Jr. Member Mark II
  • **
  • Posts: 79
Re: Civilian Industries
« Reply #33 on: February 11, 2020, 11:02:55 pm »
Its pretty sad that the main hiccup for this mod so far isn't the trade system, but the simple act of spawning in ships.

Wave-based spawns ended up feeling really, really subpar, so thats out the window. Back to trying to optimize unit spawning.

Offline StarKeep

  • Jr. Member Mark II
  • **
  • Posts: 79
Re: Civilian Industries
« Reply #34 on: February 18, 2020, 04:57:23 pm »
Civilian Industries - V 0.4.2 - Spawn On Time
Save Compatible

Trade Requests
-Optimization in regards to how Import and Export requests are stored and sorted.

Ship/Turret Spawning
-Updated how turret spawn points are chosen to be more optimal.
-Restructured the code in many moderate to major ways, the most notable being moving ship cap calculations to the background thread.
--Initial tests show all functionality is retained with notable performance increases, the struggle continues.

Raids
-Are much more deadly.

Offline StarKeep

  • Jr. Member Mark II
  • **
  • Posts: 79
Re: Civilian Industries
« Reply #35 on: February 21, 2020, 08:25:00 pm »
Civilian Industries - V 0.5.0 - The Protectors
Save Compatible

This is a large update, and includes many new ships. I am but a single person, so my primary goal with ship balance was 'don't one shot entire fleets' and 'be useful.'
If you try this out, please let me know which Protectors, if any, you have an issue with on either side of the power scale.


Protectors
-Added in a new ship class, the Protector. This is the Civilian equivalent of a Dire Guardian, and civilians can only build one per tech type per planet.
-When a planet has all of its Wormholes and Mines covered by buildings, it will than request a construction ship to build an Advanced Civilian Shipyard, which is where these units will be built.
-Requires a large investment of resources to produce.
-Battlestations and Citadels can build Militia Protector Shipyards in order to have Protectors spawn and support it.

The Crackerjack Protector
-Raid Frigate with a damage bonus against all targets that have been on the planet for less than a minute.

The Thunderstrike Protector
-Siege Frigate with vastly increased hit radius and knockback on hit.

The Paladin Protector
-Suppressor with a powerful bubble shield and self sustain.

The Brick Breaker Protector
-Assault Frigate that is an expert at dealing with large, heavily armored, targets.

The Hurricane Protector
-Sniper Frigate that has a large radius Gravity Generator and can hit multiple targets at once.

The Excalibur Protector
-Melee Frigate that has a large number of close ranged tractor beams and takes less damage from distant targets.

The Grim Reaper Protector
-Raid Frigate that is excellent at absorbing the life force from weak ships to power itself.

The Wildfire Protector
-Frigate that fires off slow moving grenades at targets.

The Tangler Protector
-Warbird Frigate that can zip around the battlefield, vaporizing fast moving targets and engine stunning the rest.

The Orchestrator Protector
-Carrier Frigate that spawns decoy drones, grants planet wide Tachyon Coverage, and boosts the speed of all allied ships on its planet.

Bugfixes/Tweaks
-Fixed a bug that caused Battlestation-spawnt units to not follow the Battlestation into hostile space.
-Building Percentages now display 2 decimal points.
-Fixed a bug where ships were getting cheaper over time instead of more expensive.
-Outposts now tech up from Citadel and Military Command Station tech.
-Patrol Posts now tech up from Citadel and Sentries tech.
-Militia HQ now tech up from Citadel and Forcefield tech.
-Grand Staion techs up from Economical, Logistic, and Engineering tech.
-Trade Station/Post techs up from Economical, Logistic, and Metal Generation tech.
--Trade Station/Post gains +1 additional resource generation for every mark.
-Cargo Ships now tech up from Metal Generation and Light tech.
-Militia Construction Ships now tech up from Engineering and Medium tech.
-Many of these tech changes resulted in more being capable of being built.

Offline StarKeep

  • Jr. Member Mark II
  • **
  • Posts: 79
Re: Civilian Industries
« Reply #36 on: February 22, 2020, 01:19:36 am »
Civilian Industries - V 0.5.1 - The Protectors Price Purge
Save Compatible

-Reduced the base cost of Protector class ships by ~50%.

Offline StarKeep

  • Jr. Member Mark II
  • **
  • Posts: 79
Re: Civilian Industries
« Reply #37 on: February 22, 2020, 04:03:15 am »
Civilian Industries - V 0.5.2 - The Performance Protection
Save Compatible

-Fixed a bug that caused the game to slooowly grind to a halt after building your first Battlestation building.
--Retroactively fixes it from prior saves.

Offline StarKeep

  • Jr. Member Mark II
  • **
  • Posts: 79
Re: Civilian Industries
« Reply #38 on: February 22, 2020, 10:24:17 pm »
Civilian Industries - V 0.5.3 - Swapping the Scales
Save Compatible

Updated Turrets to be the same overall stats, but lower capacity. Unlike fleetships, which stack and benefit from swarms for the purpose of feeling like weak little civilian ships, turrets didn't really accomplish that same goal and just ended up being maximum clutter.
Protectors have gotten some various stat changes, the most important ones being increased durability and more immunity to various effects.

-Inverted civilian turrets from half power, double cap, to double power, half cap.
--Smaller units felt fitting for them; but they got to some insane levels of spam in higher intensities and aip.

-Protector stats updated to be immune to many effects such as Zombification
-Protector base durability increased by 100%.
-Increased the scale of some of the smaller Protectors.
-Protector Paladin shield radius doubled.

Offline StarKeep

  • Jr. Member Mark II
  • **
  • Posts: 79
Re: Civilian Industries
« Reply #39 on: February 23, 2020, 09:17:12 pm »
Civilian Industries - V 0.5.4 - The New Pathfinder
Save Compatible

Updated pathfinding logic for threat reaction to help stop ships from dipping in and out of planets, or going into planets alone due to them arriving after the order to retreat was given.
Updated a few movement commands to be assigned in bulk.
Fixed a bug where Protectors were not being considered in strength calculations.

Offline Parch

  • Newbie
  • *
  • Posts: 6
Re: Civilian Industries
« Reply #40 on: February 28, 2020, 05:10:18 pm »
This mod is really awesome. I didn't find out about this mod until someone told me about it. You should promote it more!
« Last Edit: February 29, 2020, 06:08:12 pm by Parch »

Offline StarKeep

  • Jr. Member Mark II
  • **
  • Posts: 79
Re: Civilian Industries
« Reply #41 on: February 28, 2020, 10:23:28 pm »
I appreciate it. I don't want to widely share it however until its in a better state. Its feature rich, and has (fairly good) performance, but there are still the occasional bugs and save-breaking updates. Especially the next one that swaps trade details to xml.

Offline Parch

  • Newbie
  • *
  • Posts: 6
Re: Civilian Industries
« Reply #42 on: February 29, 2020, 05:20:40 pm »
Do you have a roadmap of some sorts for what you plan to add to this mod in the future? I'm curious on what's next!

Offline StarKeep

  • Jr. Member Mark II
  • **
  • Posts: 79
Re: Civilian Industries
« Reply #43 on: February 29, 2020, 06:14:48 pm »
0.6 Will be dedicated to converting trade to being xml defined, so no real new content is planned.

0.7 Will be dedicated to special faction integration; so trading with allied Marauders/Nanocaust/Macropahge. (Think less trade in the case of Nano/Macro, and more 'we're studying them and returning resources to study and reproduce their abilities.)

0.8 and on is not yet decided and is based on the prior. Planning too far ahead on something that I do for fun isn't fun. (;

Offline deadone

  • Newbie Mark II
  • *
  • Posts: 14
Re: Civilian Industries
« Reply #44 on: March 04, 2020, 05:51:00 am »
Nice mod!
The players now has his own automated Wardenfleet 8)

PS: In my logs, i see there were no raids for over 2 hours..
« Last Edit: March 04, 2020, 01:05:15 pm by deadone »