PcoWSkbVqDnWTu_dm2ix
We use cookies on this site to enhance your user experience
Collapse Sidebar

GetPoses

This function returns an array containing all Pose|Poses that have been added to a Keyframe.

Returns

Return Type Summary

An array of Poses.


Code Samples


Keyframe Reset Poses

This code sample includes a function to reset the CFrame of the Poses in a Keyframe.

    local function resetPoses(parent)
    	-- both functions are equivalent to GetChildren
    	local poses = parent:IsA("Keyframe") and parent:GetPoses() 
    		or parent:IsA("Pose") and parent:GetSubPoses()
    
    	for _, pose in pairs(poses) do 
    		if pose:IsA("Pose") then
    			pose.CFrame = CFrame.new()
    			-- recurse
    			resetPoses(pose)
    		end
    	end
    end