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

Do I need to have a mousebutton1click function in a local script inside the button?

So I want to teleport and change the health of the player when they click a button, but I don't want to do this through a local script. Is there any possibility a server script in the server script service would be able to have a mousebutton1click function to the button? If not, how can I change the health of a player in a local script with FE enabled?

1 answer

✓ Accepted answer

You will need to use a localscript when using MouseButton1Click in a GUI button. Also I think you can change the player’s health with a localscript by doing something like this :

game.Players.LocalPlayer.Character.Humanoid.Health = (PutNumberHere)

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