natiny.animation.get_name
natiny.animation.get_name(animation) -> name
Returns the name the glTF file gave this clip, which is the name
natiny.mesh.find_animation looks up.
Parameters
| Name | Type | Description |
|---|---|---|
animation |
number |
Animation handle from natiny.mesh.get_animation or natiny.mesh.find_animation |
Returns
| Type | Description |
|---|---|
string |
The clip's name, or nil when a stale nonzero handle no longer resolves |
Example
for i = 0, natiny.mesh.get_animation_count(hero_mesh) - 1 do
print(natiny.animation.get_name(natiny.mesh.get_animation(hero_mesh, i)))
end