Changes between Version 1 and Version 2 of Ticket #1718, comment 11


Ignore:
Timestamp:
Dec 1, 2012, 3:03:15 AM (11 years ago)
Author:
historic_bruno

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #1718, comment 11

    v1 v2  
    77   * But we should at least consider factoring out whatever they share into global helper functions.
    88 * There is also duplication in the siege entity templates, which is mostly unavoidable since the templates don't allow multiple inheritance. For instance, packed entities duplicate the `Attack` stats of their unpacked counterparts because they need to know a.) if they can attack, b.) the target range, etc. If we update one, we have to remember to update the other.
    9   * One slight way of improving this: have a single generic siege template for each type, then have a civ-specific "common" template inherit from that, and then packed/unpacked templates inherit from the common template. Attack stats, etc would go in the common template.
     9  * One slight way of improving this: have a single generic siege template for each type, then have a civ-specific "common" template inherit from that, and then packed/unpacked templates inherit from the common template. Attack stats, etc would go in the common template. Like this:
     10   {{{
     11                                                                                         /-- athen_mechanical_siege_oxybeles_packed
     12      template_unit_mechanical_siege_ballista --> athen_mechanical_siege_oxybeles_common |
     13                                                                                         \-- athen_mechanical_siege_oxybeles_unpacked
     14   }}}