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

[SOLVED]Is there any way to stop TweenService from growing this part both ways?

When I use tween service to grow this part, it grows backwards as well as forwards. I only want it to grow forward, to make it look like the player's arm is expanding. I've tried tweening CFrame and Position but it makes it glitch and wont move it back correctly. Here is an example

Here is the script that I use to tween the part:

local tweenService = game:GetService("TweenService")
local Slasher = script.Parent

local pilInfo = TweenInfo.new(1, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)
local pilProperties = {Size = Vector3.new(1, 50, 1); Transparency = 0--[[;CFrame = Slasher.CFrame*CFrame.new(0,0,-5)]]}
local pillarTween = tweenService:Create(Slasher, pilInfo, pilProperties)
pillarTween:Play()
wait(0.6)
script.Parent:Destroy()

1 comment

0

you should make it change the position while the size grows

1 answer

So basicly you were right with adding a position value, so you want to set Size and Position as a info.

This would look like this

    local TweenService = game:GetService("TweenService")
     
    local part = Instance.new("Part")
    part.Position = Vector3.new(0, 10, 0)
    part.Color = Color3.new(1, 0, 0)
    part.Anchored = true
    part.Parent = game.Workspace
     
    	local goal = {}
    	goal.Position = Vector3.new(10, 10, 0)
	goal.Position =  PUT THE WANTED POSITION HERE (simply drag the part how you 	want it, copy the position cords and you good to go.
     
    local tweenInfo = TweenInfo.new(5)
     
    local tween = TweenService:Create(part, tweenInfo, goal)
     
    tween:Play()

1 comment

0

If that helped you, Take my Answer as accepted

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