Alright so my script is supposed to make the player sit when it comes into contact with the left leg via animation but it doesn't work. My script so far:
function onTouched (hit)
player.character.humanoid.sit = true
h = hit.Parent:findFirstChild("Humanoid")
end
if h ~= nil then
h.Sit = true
end
script.Parent.Touched:connect(onTouched)
function onTouched (hit)
script.Parent = character("Left Leg")
script.Parent:findFirstChild("Humanoid")
end
if script.Parent ~= nil then
h.Sit = true
end

1 comment
Thank you! It works now!