Skip to content

Function; getAnimLength

thomcomstock edited this page Mar 19, 2023 · 10 revisions

getAnimLength(<sShipName>, <sAnimName>)

Description

Queries the total time of the animation.
Returns float Time (seconds).

Example

 if (isAnimRunning(ship, "turnEnd") ~= 0) then  
      startTime = **getAnimLength(ship, "turnEnd")** - getTime(ship, "turnEnd")  
      stopAnim(ship, "turnEnd")  
 end  

Arguments

<sShipname>: the name of the ship file (minus the extension).
<sAnimName>: string Name of mesh animation from ".mad" file.

Scope

[Madstate](https://github.com/HWRM/KarosGraveyard/wiki/Scope;-Madstate)

Related Pages

Function Reference

HW2_MadState.pdf

Clone this wiki locally