I toyed around with the giant space beasts called The Swarm. But before that, I need to explain another related improvement I made this week first: ownership of a sector depends on who has the most buildings there, except if there’s a military base or shipyard, in that case it’s whoever own the building. Works for every faction (except the pirates). Now you can have sectors controlled by hey, the swarm or other ‘minor’ factions.
I made it so factions now do try to expand and claim solar systems. When two factions have common borders they may plant buildings in each other territory. Also, factions need to build a dock to claim a new sector, the territorial expansion is slower and makes more sense as there’s no claimed but empty systems. It’s possible to peacefully take over sectors, you can even use pirates to help remove a foreign military base in a sector you want. It has other implications I will explain further down.
But, let’s get back to the Swarm now:
Those giant creatures enter the galaxy through one way space rifts. Those rifts open at irregular intervals with different settings and intensity. They are not overtly hostile, as in they won’t go out of their way to destroy your assets but their eating habits make them dangerous.
Queens and Gargants
Queens are battleship sized creatures. They eat asteroids to live, regenerate and hatch smaller swarm creatures like guardians and spores. Well fed swarm queens can also infest ore extraction facilities which become swarm hives.
Gargants are beefier and more hostile than queens, they can’t hatch or convert stations, they do protect swarm owned space. They both drop very expensive loot.
Hives can heal themselves and any swarm creature in range, they shoot at non swarm units. Hive also slowly extract ores and when enough is gathered, it will spawn a swarm queen or a swarm gargant. It can manage up to 2. It also means that mining colonies can be taken over by the swarm.
It has interesting results on the map with remote mining installations sometimes falling under swarm control. When no, or very little opposition is applied, you see queens grow and infest sectors. They can even completely deplete an area and then move to greener pastures. Left unchecked it can be brutal. However, faction AI tend to react accordingly.
I have, of course, full control on how, when and where the swarm invade making it also a good way to keep big factions in check. This is also part of those events I was talking about in the previous devlog. There will be more, some more straightforward than others.
New sector ownership system
Back to sector ownership.
The faction AI needs some tuning so it can decide which sector to “colonize” next better. Right now it’s a bit too slow and wasteful resource wise. Also it doesn’t really try to convert foreign sector by building more docks, but it still does by ‘accident’.
Another thing the diplomatic AI doesn’t really pick up on yet, is that it’s possible for the player to lay waste to foreign sectors, build behind it and control them without declaring war. All the killing does a large reputation hit, that may or may not lead to war but it’s not directly recognized as an act of war (yet, again).
It also means that the gamey “declare independence” button can disappear now. With those new rules, it’s always possible to take over sectors through different methods that may or may not include violence. It’s also a much more logical system than before.
Movement / Hit Detection
I improved the bullet to ship collision detection mechanism, with little CPU cost, it’s easier to hit in general. I am however battling a weird bug that sometimes disable hit detection and other functions on some ships until something enters the current sector. I think I’ve “patched” it but the cause remains kind of mystery, though.
Here is a screenshot with the new Sirak ship and station sprites, all with the same red/black theme. Stations can be animated too now. Well, some are, including the swarm hive. Some other stations have small blinking lights, solar plants are glowing, small things like that.
I also tweaked the nebulae and the background sky generation a bit and removed the annoying blinking stars when the bloom shaders are enabled.
There’s a few other smaller changes and bug fixes too but nothing especially fancy. Hopefully next week, some actual trading stuff will be done if I don’t get too side-tracked into the events and territorial expansion.