This property exposes the internal CFrame that is manipulated by Animations when a Motor6D is being animated.
Using this property it is possible to blend Roblox Animations with custom animations in Lua. This property should be read from and updated when the Stepped signal fires as this signal is fired immediately following animations being updated.
Here is some example code of how this property can be used:
local PlayersService = game:GetService("Players")
local RunService = game:GetService("RunService")
local LocalPlayer = PlayersService.LocalPlayer
-- Rotate left shoulder joint by 90 degrees
-- in addition to the current animation being applied
RunService.Stepped:connect(function()
local character = LocalPlayer.Character
if character then
character.LeftUpperArm.LeftShoulder.Transform = character.LeftUpperArm.LeftShoulder.Transform * CFrame.Angles(math.rad(90), 0, 0)
end
end)
-- Overwrite current animation for the right arm
RunService.Stepped:connect(function()
local character = LocalPlayer.Character
if character then
character.RightUpperArm.RightShoulder.Transform = CFrame.Angles(math.rad(90), 0, 0)
character.RightLowerArm.RightElbow.Transform = CFrame.new()
character.RightHand.RightWrist.Transform = CFrame.new()
end
end)
This property is scriptable only, it can’t be set in the studio properties widget and it doesn’t serialize. For performance reasons this property won’t fire the Changed signal and it doesn’t replicate.