Changes between Initial Version and Version 1 of Ticket #1718, comment 3


Ignore:
Timestamp:
Nov 15, 2012, 9:19:59 PM (11 years ago)
Author:
historic_bruno

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #1718, comment 3

    initial v1  
    1 Actually I was looking into this task a few months ago. I wasn't completely satisfied with where it ended up, but the idea was to have separate entity templates for pack/unpacked units, which are created/destroyed when the transformation finishes. The benefit of that is it means less special cases throughout the simulation code, but also we can have different properties for packed vs. unpacked units, like armor values and vision range, to name a few. The drawback is twice as many siege templates.
     1Actually I was looking into this task a few months ago. I wasn't completely satisfied with where it ended up, but the idea was to have separate entity templates for packed/unpacked units, which are created/destroyed when the transformation finishes. The benefit of that is it means less special cases throughout the simulation code, but also we can have different properties for packed vs. unpacked units, like armor values and vision range, to name a few. The drawback is twice as many siege templates.
    22
    33The hardest part of this task IMO is getting it to work nicely with UnitAI which is tightly coupled with unit movement. So for example, UnitAI does range checks for attack that depend on the pathfinder. I opted to create a non-moving motion component for the case of an unpacked siege unit which does a simple linear distance check for range (the normal pathfinder range is far more complicated). I basically got all of it working except animations (obviously) and making the unit auto-pack if tasked to move/attack out of range.