Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How to keep part's position while tweening?

So I have a part that I want to tween (CanCollide = true), let's call it PartA

The problem is that whenever I tween PartA, and it touches another part (Also CanCollide = true), PartA's position changes. Is there any way I can avoid that?

Here is the script:

local TweenService = game:GetService("TweenService")
local part = script.Parent
 
local tweenInfo = TweenInfo.new(
	1,								
	Enum.EasingStyle.Quad,		
	Enum.EasingDirection.Out,		
	0,								
	false,							
	0							
)
 
local propertyGoals =
{
	Transparency = 0;
	Size = Vector3.new(10,1,10);
}

local tween = TweenService:Create(part,tweenInfo,propertyGoals)
 
tween:Play()

1 answer

Maybe try getting the current position of the part, then in the propertyGoals table, do: Position = (variablenamehere)

Not sure, I have never tested it, can you test?

This discussion is preserved as it was. New answers, comments, and votes are closed.