Formations #2

 

The past week and weekend was spent on formations. Its funny because a while back I was worried about the math (with me not being great in matH0 involved and the specifics of ships forming up, but that aspect turned out to be very easy. The harder aspect became management, leaving a formation, creating a new leader, etc etc.

This aspect became very complicated – because there are many ways that a ship leaves a formation. Though dying, through being promoted to a leader (at which point the ship isn’t [in code] a part of a formation), when a formation “rebalances” itself (meaning that ships re-organize themselves to be closer to proper [nearest] formation positions) ships can leave and then rejoin a formation.  Because the code wasn’t all the way thought out (my bad) this led to infinite loops. A few bits of code later they went away. The GUI and how formations worked on that side also took a bit of thought and doing – but overall things work. What’s left is having formations save/load across games, cleanups and a lot of tests. I’m a bit afraid that Iteration 18 will be fairly buggy.

Now that formations are soon to be mostly completed, this will allow for a across the board AI improvements, since formations are going to be a big part, AI is basically mostly completed as far as major features. The future goal will be to make it more obedient.

Almost forgot – another item added is “SPROG” fire mode – it is an add-on to turret/weapon control in Command mode – with it you can control all turrets in a formation from the lead ship’s Command mode – making an overwhelming amounts of firepower directed at the player’s cursor possible. It is funny because I’m not sure how useful of a feature this is – but I’m sure that its cool and unique.