Changes between Version 7 and Version 8 of Formations


Ignore:
Timestamp:
Apr 24, 2020, 3:48:23 PM (4 years ago)
Author:
Silier
Comment:

rP22442

Legend:

Unmodified
Added
Removed
Modified
  • Formations

    v7 v8  
    4545
    4646=== Animations ===
    47 The formation component can also replace animations (currently movement animations, but later also attack and idle animations). This is an example of animation-replacement code. This is an example:
     47The formation component can also set animation variants, that will be used by formation members. This is an example of animation-replacement code. This is an example:
    4848
    4949{{{
    5050<Animations>
    51   <walk>
    52     1..1,1..-1: walk_syntagma_row1;
    53     2..2,1..-1: walk_syntagma_row2
    54   </walk>
    55   <run>
    56     1..1,1..-1: walk_syntagma_row1;
    57     2..2,1..-1: walk_syntagma_row2
    58   </run>
    59 </Animations>
     51      1..2,1..-1: syntagma_front;
     52      3..3,1..-1: syntagma_01;
     53      4..4,1..-1: syntagma_02;
     54      5..5,1..-1: syntagma_03;
     55      6..6,1..-1: syntagma_04;
     56      7...-1,1..-1: syntagma_back
     57</Animations> 
    6058}}}
    61 The above example schema replaces the walk and run animations for row1 and 2. The indices you see denote a rectangle with the following parameters: ''rowStart..rowEnd,columnStart..columnEnd''. You can use negative indices to denote the last row/column, second to last, etc. Then after the ":", the name of the replacement animation is given. That name needs to be present in the actor file. Else the animation will fall back to "idle", as for all missing animations. The different rectangle definitions need to be separated by a ";" character. Indices that fall out of all rectangle definitions will keep using the default animation (in this case, the "walk" and "run" animation).
     59The above example schema replaces animation variant with ''syntagma_front'' for row 1 and 2. The indices you see denote a rectangle with the following parameters: ''rowStart..rowEnd,columnStart..columnEnd''. You can use negative indices to denote the last row/column, second to last, etc. Then after the ":", the name of the animation variant replacement is given. That name needs to be present in the actor file. Else the animations will fall back to animation variant with highest frequency as for all missing animations. The different rectangle definitions need to be separated by a ";" character. Indices that fall out of all rectangle definitions will keep using the default animation variants.
     60
     61Current UnitAI implementation will apply this variant if present for combat, idling, walking and running.