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

GUI tweening script will only work in studio and not in game?

script.Parent.MouseButton1Click:connect(function()
  local e = script.Parent.Parent.Parent.Parent.Options
  local f = script.Parent.Parent.Parent
	f:TweenPosition(UDim2.new(1, 0, 0, 0), "In", "Quart", 2.35)
	e:TweenPosition(UDim2.new(0, 0, 0, 0), "In", "Quart", 2.35)
	wait(2.35)
end)

This is a script to move a GUI off screen and another on however it only works in studio and there is no errors in the output in-game?

1 answer

If it only works in Solo mode (studio), it's probably because you are not using LocalScripts, as these kind of events can only be detected by clients. It works fine in studio because there is no server, it's a local run.

3 comments

0

Or something like that... forgive my client/server explanation.

0

tl;dr Using Scripts instead of localscripts is a bad idea for PlayerGuis

0

yeah

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