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

Why isn't my character select script not working in game but works in Studio?

Asked by
rexpex 45
8 years ago

My script works in Roblox Studios but not in game. The script is suppose to open a invisible GUI that lets you select a certain character named "StarterCharacter1" and rename it to "StarterCharacter" so you will become it but the button wont even open in-game. Here is the script.


local Menu = script.Parent.Parent.Parent script.Parent.MouseButton1Click:connect(function() Menu.Visible = not Menu.Visible game.Players.LocalPlayer.Character.Humanoid.Health = 0 game.StarterPlayer.StarterCharacter1.Name = "StarterCharacter" end)

1 answer

Log in to vote
0
Answered by 5 years ago

U got to do this on the second line

scriptParent.MouseButton1Click:connect(function()Menu.Visible = true

Ad

Answer this question