Changes between Initial Version and Version 4 of Ticket #4420


Ignore:
Timestamp:
Feb 3, 2017, 11:15:50 AM (7 years ago)
Author:
Imarok
Comment:

review is taking place on Phabricator: https://code.wildfiregames.com/D13

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #4420

    • Property Keywords rfc removed
  • Ticket #4420 – Description

    initial v4  
    11UnitMotion has always been quite annoying to change, and full of a variety of complicated bugs. Its ties with unitAI are also quite annoying.
    22I have rewritten it.
    3 
    43"Big" changes:
    54-Dumped the m_State/m_PathState variables, and generally streamlined the unitMotion logic, implemented an easier way to wait some turns when paths fail and react accordingly (should reduce units getting stuck and the number of potential bugs in general).
    65-Let UnitMotion handle the move animations instead of hacking it with unitAI. This means that ultimately we could have "walk-attack", "run-gather" animations. But for now we don't really support that.
    76-Changed speed to just walk speed, and use a ratio to change it instead of an absolute value. Ultimately, I plan te delete run speeds, but haven't gotten around to it yet.
    8 
    97In some finer points, I dump the "longPath"/"shortPath" split to just be a simple "Path", so that if we remove the short pathfinder someday that will be easier, and it just makes the whole thing nicer.
    10 
    118I also have a test map, available on my github branches:
    129-Working branch: https://github.com/wraitii/0ad/tree/UnitMotionRewrite
    1310-"Cleaned up" branch: https://github.com/wraitii/0ad/tree/UMRewrite_Clean
    14 
    1511Cleaned up branch might be slightly easier to review. Attached unified diff (sans map) below.