Skip to main content

AnimationTrackUtils

Utility functions for animations

Functions

loadAnimationFromId

AnimationTrackUtils.loadAnimationFromId(
animatorOrHumanoidHumanoid | Animator,
animationIdstring
) → Animation

Loads an animation from the animation id

setWeightTargetIfNotSet

AnimationTrackUtils.setWeightTargetIfNotSet(
weightnumber,
fadeTimenumber
) → Animation

Sets the weight target if not set

Show raw api
{
    "functions": [
        {
            "name": "loadAnimationFromId",
            "desc": "Loads an animation from the animation id",
            "params": [
                {
                    "name": "animatorOrHumanoid",
                    "desc": "",
                    "lua_type": "Humanoid | Animator"
                },
                {
                    "name": "animationId",
                    "desc": "",
                    "lua_type": "string"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "Animation"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 14,
                "path": "src/animationtrackutils/src/Shared/AnimationTrackUtils.lua"
            }
        },
        {
            "name": "setWeightTargetIfNotSet",
            "desc": "Sets the weight target if not set",
            "params": [
                {
                    "name": "track",
                    "desc": "",
                    "lua_type": "AnimationTrack"
                },
                {
                    "name": "weight",
                    "desc": "",
                    "lua_type": "number"
                },
                {
                    "name": "fadeTime",
                    "desc": "",
                    "lua_type": "number"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "Animation"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 27,
                "path": "src/animationtrackutils/src/Shared/AnimationTrackUtils.lua"
            }
        }
    ],
    "properties": [],
    "types": [],
    "name": "AnimationTrackUtils",
    "desc": "Utility functions for animations",
    "source": {
        "line": 5,
        "path": "src/animationtrackutils/src/Shared/AnimationTrackUtils.lua"
    }
}