Howto:Animate models: Difference between revisions

Jump to navigation Jump to search
m
documented 2020.4 tags for axis objects
No edit summary
m (documented 2020.4 tags for axis objects)
Line 118: Line 118:


If the <code><axis>...</axis></code> section is omitted entirely, <code>{object-name}-axis</code> will be used by default, where <code>{object-name}</code> is the name of the object being animated (if we are animating more than one object, the first object is used). In the earlier example this would be <code>Rudder-axis</code>.
If the <code><axis>...</axis></code> section is omitted entirely, <code>{object-name}-axis</code> will be used by default, where <code>{object-name}</code> is the name of the object being animated (if we are animating more than one object, the first object is used). In the earlier example this would be <code>Rudder-axis</code>.
With FG <= 2023.3 the order of the points in the vertex will be sorted based on their X coordinate and when the X coordinate is equal the order will be that of the vertices in the model. Since 2020.4 it has been possible to add the tag <code><order-by-xyz/></code> to the <code><axis></code> element to specify that all axes are used to sort which produces consistent results. This behaviour can be specified for an entire model by including the tag
<code><axis-animation-vertex-order-xyz/></code> usually in the top level model.xml; although it can be specified in any model XML and will affect that XML and any children that don't explicitly set the order. Generally I would consider it better practice to only set this once. It is also possible to use the tag <code><axis-animation-vertex-order-x/></code> and this might be useful where a particular model requires this.


In the '''.ac''' file, specify a SURF with type (bottom 4 bits, 0=polygon, 1=closedline, 2=line) set to 2, and two vertices that define the axis. For example:
In the '''.ac''' file, specify a SURF with type (bottom 4 bits, 0=polygon, 1=closedline, 2=line) set to 2, and two vertices that define the axis. For example:
308

edits

Navigation menu