Refactor and move random template composition triggerscript code used for gaia attack...
commit85bee9c8e3e287aed8048e44107d9a0dd5e8b789
authorelexis <elexis@3db68df2-c116-0410-a063-a993310a9797>
Tue, 6 Mar 2018 13:31:34 +0000 (6 13:31 +0000)
committerelexis <elexis@3db68df2-c116-0410-a063-a993310a9797>
Tue, 6 Mar 2018 13:31:34 +0000 (6 13:31 +0000)
tree6cc22b36c0a351ca1ce017e239dc11d6db3a024a
parent558c86f19b6b2e304d2e2a631e2bbdc2910cd5bd
Refactor and move random template composition triggerscript code used for gaia attacker waves from Danubius (rP19434 / D204) and Survival Of The Fittest (rP19359 / D145) to the TriggerHelper.

Eases implementation of new maps with diverse scripted attackers, refs #5040, D11 and  map difficulties, refs #4963, D1189.
Replaces hardcoded templatenames with calls to a new TriggerHelper function to query template names, given Classes, Civ, Rank or Packed state.
Removes the duplicated template counting logic, that was intertwined with map specific unit classes balancing logic, refs #4805.

Use mimos garrison function from rP20659 / D1146 to support doubleclicking on garrisoned gaia heroes on Danubius, fixing the bug described in comment:10 of #4291.
Fix wrong (Trigger) prototype reference in rP21416.

git-svn-id: https://svn.wildfiregames.com/public/ps/trunk@21445 3db68df2-c116-0410-a063-a993310a9797
binaries/data/mods/public/maps/random/danubius_triggers.js
binaries/data/mods/public/maps/random/elephantine_triggers.js
binaries/data/mods/public/maps/random/survivalofthefittest_triggers.js
binaries/data/mods/public/maps/scripts/TriggerHelper.js