This was resulting in non-intuitive and surprising behaviour when queuing
commands. Removing this system results in Megaglest behaving more like
other RTS games.
For instance, the following are now possible and weren't previously:
- Queuing multiple attack ground commands to move along a specific path
attacking all enemies on the way.
- Queuing attack ground followed by hold position, which is a sensible
thing to do if you want a unit to guard a specific area.
- Queuing a move command followed by a produce command, if you want to
have your summoner summon a daemon at a specific location.
The behaviour of queuing the stop command is unchanged, and commands that
must be the last in the queue, such as morphing, are still properly replaced when something
else is queued.
* Allow a selected group to have the attack command even if some units don't have it
* Add getUnitFromCC function
* return NULL if getFirstCtOfClass founds no unit
* Search for the unit containing the attack command in a non uniform selection
Co-authored-by: Rampoina <Rampoina@protonmail.com>
maxHP cannot been boosted anymore( just upgrades!). this has too many
side effects.
maxHP upgrades were calculated based on units current HP which doesn't
make sense.
maxEP cannot been boosted anymore( just upgrades!). this has too many
side effects.
Code is much cleaner and smaller now
Added uniform selection of units.
Uniform means you can select multiple units, but only of the same type.
To make a unit uniform-selectable you need to add
```<uniform-selection value="true"/>```
to the ```<parameters>``` tag of a unit.
Previously the Hp and Ep regeneration was only shown if hp and ep
were also affected by the AttackBoost.
In addition I changed the way the regeneration is shown:
Old: ->EP +10 [10]
New: ->EP +10 (Regeneration: +10)
In the faction.xml you can set teh following now:
<flat-particle-positions value="true"/>
By this the positions of the particle systems ( attack and unit particles )
can be done based of the units centered ground position and
by this height independend.