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

How to change values in the server side from StarterGui?

Asked by 5 years ago
Edited 5 years ago

So I have a couple of values in workspace, I have a script in StarterGui that when you right click, the value changes. However, my value does not change. Am I doing something wrong? The weld break code works.

Code in starter:

local player = game.Players.LocalPlayer

local mouse = player:GetMouse()





mouse.Button2Down:Connect(function()

    if game.workspace.Values.have.Value == 1 then

        game.workspace.Values.have.Value = 0




        player.Character.Weld:Destroy()

    end


end)

Is there anything wrong??

0
You can use RemoteEvents. DeceptiveCaster 3761 — 5y
0
How?? User#25281 0 — 5y
0
Thanks!! Now I am happy. User#25281 0 — 5y

1 answer

Log in to vote
1
Answered by 5 years ago
Edited 5 years ago

You need to use remote event!

Instance.new("RemoteEvent")

this should help you get started!

1
Thanks!! User#25281 0 — 5y
Ad

Answer this question