Expand description
Types for working with Anim data in .nuanmb files.
§Examples
Animation data is stored in a hierarchy. Values for each frame are stored at the TrackData level.
use ssbh_data::prelude::*;
let anim = AnimData::from_file("model.nuanmb")?;
for group in anim.groups {
for node in group.nodes {
for track in node.tracks {
println!("Frame Count: {}", track.values.len());
}
}
}
§File Differences
Unmodified files are not guaranteed to be binary identical after saving. Compressed animations use lossy compression for all data types except TrackValues::Boolean. When converting to Anim, compression is enabled for a track if compression would save space. This may produce differences with the original due to compression differences. These errors are small in practice but may cause gameplay differences such as online desyncs.
Modules§
Structs§
- Data associated with an Anim file. Supported versions are 2.0 and 2.1.
- Data associated with a Group.
- Data associated with a Node.
- The data associated with a TrackV2.
- A decomposed 3D transformation consisting of a scale, rotation, and translation.
- A decomposed 2D transformation for texture coordinates.
Enums§
- Determines the usage for a Group.
- A value collection with an element for each frame of the animation.