Move Script Wont Work (local)

I have this local script and when the event gets fired, it does the jumpscare after 1.2 seconds but it doesn’t visibly move the npcs position nor moves its oriantation for the lookat thing. Oh yeah and I know this is a horrible script and I’m using a local script on purpose btw.

local player = game.Players.LocalPlayer
local tweenservice = game:GetService("TweenService")

local connection

local remote = workspace.Map.Winner["Among Us vent"]:WaitForChild("Click").ProximityPrompt.Script.RemoteEvent

local potemer = workspace.Map.Winner:WaitForChild("PotemerForReal")

local function jumpscare()
	player.PlayerGui.ScreenGui.jumpscare.Visible = true
	task.delay(3, function()
		player.PlayerGui.ScreenGui.jumpscare.Visible = false
	end)
end

remote.OnClientEvent:Connect(function()
	local character = player.Character

	local humanoid = character:FindFirstChildWhichIsA("Humanoid")

	humanoid.WalkSpeed = 0
	humanoid.JumpHeight = 0

	potemer.PrimaryPart.CFrame = CFrame.lookAt(potemer.PrimaryPart.Position, character.PrimaryPart.Position)

	task.wait(1)

	local goal = {CFrame = character.PrimaryPart.CFrame}
	local tweeninfo = TweenInfo.new(0.2, Enum.EasingStyle.Linear, Enum.EasingDirection.In)
	local tween = tweenservice:Create(potemer.PrimaryPart, tweeninfo, goal)
	tween:Play()

	connection = potemer.PrimaryPart.Touched:Connect(function(hit)
		if hit:IsDescendantOf(character) then
			jumpscare()
			humanoid.Health = 0
			script.Sound:Play()
		end
	end)
end)
1 Like

i would guess its just moving the primary part and not moving the rest of the jumpscare object… Make sure the Primary part is not transparent and see what happens… If that is the case then you want to weld everything to the primary part or if its a humanoid rig avatar thing then use humanoid:MoveTo() or humanoid:PivotTo()

the issue tho is that the model is anchored and i dont wanna unanchor it

Why not just weld all of the parts in the Model to the PrimaryPart, unanchor those parts, then ONLY anchor the primary part?

I just cant unanchor the parts because of something, is there any other way.

Well, the parts would be welded with a WeldConstraint to the Primary one (which IS anchored). So if the parts are welded to an anchored one, then they will still behave like a normally anchored part would. What would be the thing that requires them to be anchored, anyways?

i have the npc posed and to stay posed like that it gotta be anchored