Tween Forward Help

You can write your topic however you want, but you need to answer these questions:

  1. I want to make a part tween forward without any other sides changing.

2.It instead tweens to my hand instead of FROM my hand.

  1. I’ve tried going to devfourm looking for topics about this but decide to make my own
game.Players.PlayerAdded:Connect(function(player)
	player.CharacterAdded:Connect(function(character)
		local Animator = Instance.new("Animator")
		Animator.Parent = character:WaitForChild("Humanoid")
	end)
end)



game.ReplicatedStorage.RemoteEvent.OnServerEvent:Connect(function(Player , Cero, PlayCero)
	local CeroServerSide = game.ReplicatedStorage.Part:Clone()
	local Beam = game.ReplicatedStorage.Void:Clone()
	Beam.Parent = workspace
	CeroServerSide.Name = "Cero"
	CeroServerSide.Size = Vector3.new(0,0,0)
	print(Cero)
	CeroServerSide.Parent = workspace
	local partweld = Instance.new("Weld", Player.Character)
	partweld.Part0 = Player.Character["Left Arm"]
	partweld.Part1 = CeroServerSide
	partweld.C0 = CFrame.new(0, -2, 0)
	partweld.C1 = CFrame.Angles(math.rad(90), 0, 0)

	local Tweenservice = game:GetService("TweenService")
	
	local BeamWeld = Instance.new("Weld", Player.Character)
	BeamWeld.Part0 = Player.Character["Left Arm"]
	BeamWeld.Part1 = Beam
	BeamWeld.C0 = CFrame.new(0, -25, 0)
	BeamWeld.C1 = CFrame.Angles(math.rad(90), 0, 0)

	local Info = TweenInfo.new(6, Enum.EasingStyle.Quad, Enum.EasingDirection.Out, 0, false, 0)
	local tableInfo = {Size = Cero}
	local Play_Tween = Tweenservice:Create(CeroServerSide, Info, tableInfo)
	Play_Tween:Play()

	local SecondInfo = TweenInfo.new(3, Enum.EasingStyle.Quad, Enum.EasingDirection.Out, 0, false, 0)
	local SecondTable = {Size = Vector3.new(10.836, 9.473, 54.379), CFrame = Beam.CFrame * CFrame.new((Vector3.new(.569, 7.311, 49.679) - Beam.Size)/2)}
	local Play_Second = Tweenservice:Create(Beam, SecondInfo, SecondTable)
	Play_Second:Play()


	Play_Tween.Completed:Wait() 
	Play_Second:Play()
	print("Completed")


	Play_Second.Completed:Wait() 
	print("Completed ALso")
	game.ReplicatedStorage.RemoteEvent:FireClient(Player)
end)

Could it be because you’re immediately playing the Second tween after the first tween? You create Play_tween and playing it, and making Play_Second and immediately playing it as well? Maybe remove the Play_Second:Play()?

1 Like

One small mistake I see, just reading your code:

game.ReplicatedStorage.RemoteEvent:FireClient(Player)

Should be kept outside your event function. It will never get used, unless its outside the event function you wish to fire. I’d just put it on the line right after the function, outside of it. Hope that helps.

The arguments only determine the goal of the tween (where the part should move to), if you want to change the origin of the tween, first set the CFrame of the part to the origin position you want, then change the values to where you want the part to tween to.

Also you’re playing the same tween twice.

it did get used I just never added it back into the function,I fired client outside of to make the animation stop.

I already removed that from my script just forgot to show / update it.

but the thing is I want the tween to move forward and only forward, not both sides to be tween only one.

Then set the goal position like this to make it only move in one side, for example:
OriginPosition + Vector3.new(0,0,15)
This would make it move only in the Z axis