By the way, why is it that the .lua files in BA's units directory actually seem to have nothing to do with the UnitDefs that actually reside in-game? Am I missing something?
The files in in the units\ folder define the ingame units,.. BUT:
One confusing thing is that the properties (sometimes called "tags") sometimes have different names in game files and ingame-UnitDef.
eg for hitpoints, in the unitdef file there is "maxDamage" but later in the ingame-UnitDef it is called "health."
Some tags might just be leftovers from TA that do nothing, though I think BA devs cleaned that up a bit. Still the "hitdensity"-tag in the wreckage defs is such a thing that does nothing.
Other ingame-UnitDef tags are not actually in the files but set by the engine on loading: eg a unit is given isTransport=true
if its unitDef file contains all the tags needed for a transporter to work.
Same with isFactory, isBuilding
Which has led to much more intelligent attack targetting that ruthlessly destroys metal mines and power plants.
That's cool. Maybe you want to document and post your experiments somewhere (here or in wiki) so others can learn from it. There are always people asking how/if Shard can do that and this but examples of working stuff seem rare. You might think "but I only want to publish it if everything is working!"
, but if people only posted 100% complete things then this forum would be very empty.