Methods
addDecayingStructure()
Garrison units in decaying structures to stop their decay
do it only for structures useful for defense, except if we are expanding (justCaptured=true)
in which case we also do it for structures useful for unit trainings (TODO only Barracks are done)
- Source:
cancelGarrison()
Cancel a pre-garrison state
- Source:
garrison()
This is just a pre-garrison state, while the entity walk to the garrison holder
- Source:
leaveGarrison()
This is the end of the pre-garrison state, either because the entity is really garrisoned
or because it has changed its order (i.e. because the garrisonHolder was destroyed)
This function is for internal use inside garrisonManager. From outside, you should also update
the holder and then using cancelGarrison should be the preferred solution
- Source:
numberOfGarrisonedSlots()
TODO should add the units garrisoned inside garrisoned units
- Source:
numberOfGarrisonedUnits()
TODO should add the units garrisoned inside garrisoned units
- Source:
registerHolder()
Add this holder in the list managed by the garrisonManager
- Source: