Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Why does this Tween Position script not work I have tried multiple things?

Asked by
uhTeddy 101
7 years ago
script.Parent.MouseButton1Down:connect(function()
    script.Parent.Parent:TweenPosition(UDim2.new(-0.9,0,0.377,0), 'Out', 'Sine', .5)
end)

2 answers

Log in to vote
0
Answered by
glinary 19
7 years ago

Just tryin

--USE IN LOCALSCRIPT THEN PUT UNDER THE PART

local player = game.Players.LocalPlayer
local Mouse = player:GetMouse()

Mouse.Button1Down:connect(function()
   script.Parent.Parent:TweenPosition(UDim2.new(-0.9,0,0.377,0), 'Out', 'Sine', .5)
end)
0
That did't work uhTeddy 101 — 7y
0
How could that possibly make a difference? the only think is you added two variables but the variables dont go to anything uhTeddy 101 — 7y
Ad
Log in to vote
0
Answered by
uhTeddy 101
7 years ago

Okay so I found out myself and I got it

--USE IN LOCALSCRIPT THEN PUT UNDER THE PART

script.Parent.MouseButton1Down:connect(function()
   script.Parent.Parent:TweenPosition(UDim2.new(-0.9,0,0.377,0), 'Out', 'Sine', .5)
end)
0
What changed? Tesouro 407 — 7y

Answer this question