I need help with tweening

im trying to tween a group of parts that all have the same name in a folder with a local script, but they wont move and i have no idea why

local tweenservice = game:GetService("TweenService")
local killparts = game.Workspace.killparts:GetChildren()
local tweeninfo = TweenInfo.new(2,Enum.EasingStyle.Linear,Enum.EasingDirection.InOut,-1,true,2)

for i,part in pairs(killparts) do
	if part.Name == "fireball" then
		local goal = {Position = part.Position + Vector3.new(-16.5,0,0)}
		tweenservice:Create(part,tweeninfo,goal):Play()
	end
end
1 Like

Use a server script instead of a local script. If you want to use a local script, I recommend putting the script in PlayerServiceScripts.

1 Like