So i’ve been trying to freeze a player in place when they touch a part, then unfreeze, the first part works fine, the player is frozen in place and their skin color is changed to have the frozen look, the problem lands when i try to “defrost” the player, by just unanchoring their limbs, wich although it does work, for one, the skin color change is not applied, and two, the character is technically anchored, but their limbs still move doing the walk animation, and THEN it is unchanchored, so although it works, i want to find a way that - changes the skin color to the color i want it to be - the character stays in place without moving their limbs from their walk animation or any animation in general, just completely static -
i can’t record, but i provided these images to show how it works
-
first image is the script without task.wait(1) limb.anchored = false, it works perfectly fine
-
second image is the same script but with task.wait(1) limb.anchored = false
-
third image is the continuation of the second image, it applies the skin color change and after a few seconds the animations start bugging all over the place
Here is my code:
local part = script.Parent
part.Touched:Connect(function(hit)
local player = hit.Parent
if player and player:IsA("Model") then
local humanoid = player:FindFirstChildOfClass("Humanoid")
if humanoid then
humanoid:TakeDamage(10)
for i, limb in player:GetChildren() do
if limb:IsA("BasePart") then
limb.Anchored = true
limb.Color = Color3.fromRGB(116, 255, 227)
-- task.wait(1)
-- limb.Anchored = false
end
end
end
end
end)
Thanks in advance for the help!