Ai Jumpscare help

hello, i have a AI and im trying to make a jumpscare where the Ai picks u up then jumpscares u then u die, i have the part where he jumpscares u but cant get the part where he picks u up, i tried making it where the Ai does his animation of grabing and make it .Stopped:wait() so the Ai script pauses, but before it pauses i make the player teleport to a attachment in the ai where he needs to be placed when getting grabbed then i add a weldconstraint so the player sticks to the ai, also i make the player uncollideable, then after the animation.stopped is finished i play the jumpscare animation, but the grabbing animation doesnt work at all, any help?

				if (DamagePart.Position - Target.PrimaryPart.Position).Magnitude <= AttackRange then
					
					if DealingDamage then
						
						RunAnimation:Stop()
						WalkingAnimation:Stop()
						Grab:Play()
						Target.LowerTorso.CFrame = script.Parent.HumanoidRootPart.GrabTP.CFrame
						script.Parent.GrabWeld.Part1 = Target.LowerTorso
						Target.HumanoidRootPart.Anchored = 	false
						for _, object in ipairs(Target:GetChildren())  do
							if object:IsA("MeshPart") or object:IsA("Part") then
								object.CanCollide = false
			
						Grab.Stopped:Wait()
						script.Parent.GrabWeld.Part1 = nil
						Grab:Stop()
						
						wait(3)
					Target.Humanoid.Health = Target.Humanoid.Health - Damage
					if Target.Humanoid.Health < 1 then
						JumpscareRemote:FireClient(Player)
						WalkingAnimation:Stop()
						JumpScareAnimation:Play()
						script.Parent.JumpScareBlock.PointLight.Enabled = true
						script.Parent.HumanoidRootPart["Nightmare Yelling Bursts Of Distorted Scream (SFX)"]:Play()
						JumpScareAnimation.Stopped:Wait()
						script.Parent.JumpScareBlock.PointLight.Enabled = false
						hasTarget = false
						WalkingAnimation:Play()

You must do the grab from the client side, since the client owns the physics of the player’s character. This is probably why it’s not working.

1 Like