Deferred SignalBehavior 'breaks' IKControl behavior

Currently, Deferred SignalBehavior prevents .Stepped from running inbetween stepAnimation and stepIK.

You need to intercede between stepAnimation in order to easily update your IK Solver props with results from just your avatar’s animation, ex:

--In Immediate: .Stepped runs after stepAnimation but before stepIK
--This allows devs to modify the IK targets before IK is solved
--Using the .Transform of your animations -> adjust IK -> it solves
RunService.Stepped:Connect(function(dt)
	--Footplanting example, we rely on the fact that only animation .Transform is present
	local direction = endEffector.TransformedWorldCFrame.Position - chainRoot.TransformedWorldCFrame.Position
	local raycastResult = workspace:Raycast(chainRoot.TransformedWorldCFrame.Position, direction*1.01, rayParams)
	if raycastResult then
		target.WorldCFrame = CFrame.new(raycastResult.Position)
		IKControl.Enabled = true
	else
		IKControl.Enabled = false
	end
end)


RunService.PreSimulation:Connect(function(dt)
	--Not directly related but
	--Also in immediate, this for some reason runs after stepIK.
	--Since PreSimulation is supposed to be a Replacement for Stepped this is odd
	--I.e if a dev remakes roblox's demo/tries to do animation blended footplanting with Stepped it will work
	--But not if they use PreSimulation
end)

The layout can be seen in the microprofiler for immediate here:

In comparison, deferred removes any resumption point inbetween stepAnimation and stepIK:

This problem can be reproduced with many examples, but a good one is via the attached devforum resource where a user provides others with a simple guide on how to recreate roblox’s own IKControl demo:

This is a problem because deferred events and IKControls are both released features and Roblox even sets your signalbehavior to Deferred when you make new places. However, for developers trying to create footplanting akin to Roblox’s demo, they are effectively forced to change SignalBehavior.

This is also a decently subtle interaction, especially from a developer perspective since it’s unexpected that defaulted features would have an interaction like this, especially considering Roblox features their own demo video with adapative footplanting.

1 Like

You think this issue could be causing this bug?

When replacing with custom animation code or deleting the Animate script the IKControler starts jittering.

This specific bug report is purely in reference to how deferred events prevent reading .Transforms from just the result of the stepAnimator operation.
I recommend the attached community resource in my post as a quick reference for R15 footplanting (although obviously make sure signalbehavior is set to immediate, as this post references how setting that to deferred breaks that solution).
We’ve generally avoided using poles so far as they haven’t been necessary, but they can definitely be a footgun. We’ve preferred the strategy of setting constraints instead as it’s more predictable, but our model is also a cat and iirc roblox has good default support when using IKControls with default R15s.

Is this a recent change or has it been this way for some time?

It has seemingly been this way for some time, because we’ve unknowingly had broken behavior in our test place with deferred on for a few months now and never understood why.