# Query Animation Length By Identifier

Grammar — Query the length of animation and time remaining for identifier on actor
FlagsNative | Action

Starts a query for the animation length and animation time remaining of the specific animation name for the given actor. Note that the animation length and remaining time may vary from player to player due to different game states or localities. This function will query the maximum length and maximum remaining time of all players when there are different values. Note that you may only do 512 animation length queries maximum in a single game. Use the “Last Animation Query” function to get a handle to this query which can be used to get the information retrieved after the query is complete.

# Arguments

  • actor — Actor
  • string — Identifier
  • bool — Get Scaled Time

Returns — void

native void AnimLengthQueryByName(
	actor a,
	string animName,
	bool scaledTime,
);

Category: Animation / Advanced

# Examples

mods/novastoryassets.sc2modbase2.sc2maps/maps/campaign/nova/nova06.sc2map/MapScript.galaxy:7167

    }

    AnimLengthQueryByName(ActorFromDoodad(DoodadFromId(1667)), "Driveby", true);
    AnimLengthQueryWait();
    lv_carAnimation = AnimLengthQueryLastCreated();

mods/novastoryassets.sc2modbase2.sc2maps/maps/campaign/nova/nova06.sc2map/MapScript.galaxy:7618

    }

    AnimLengthQueryByName(ActorFromDoodad(DoodadFromId(5973)), "Driveby", true);
    AnimLengthQueryWait();
    lv_carAnimation = AnimLengthQueryLastCreated();

mods/novastoryassets.sc2mod/base2.sc2maps/maps/campaign/nova/nova06.sc2mapMapScript.galaxy:7167

    }

    AnimLengthQueryByName(ActorFromDoodad(DoodadFromId(1667)), "Driveby", true);
    AnimLengthQueryWait();
    lv_carAnimation = AnimLengthQueryLastCreated();

mods/novastoryassets.sc2mod/base2.sc2maps/maps/campaign/nova/nova06.sc2mapMapScript.galaxy:7618

    }

    AnimLengthQueryByName(ActorFromDoodad(DoodadFromId(5973)), "Driveby", true);
    AnimLengthQueryWait();
    lv_carAnimation = AnimLengthQueryLastCreated();