Part=script.Parent.Parent.Parent.Parent.Parent.Parent
Pa=Part.PA
Pb=Part.PB
Pc=Part.PC
enabled=true
Multiplier=10 --Charles if you want to change the outcome of the credits just change this variable
script.Parent.MouseButton1Down:connect(function(OMG) --Tried using a parameter to find who is trying to click it
print("Function worked")
local Wint=script.Parent.Parent.Parent.Parent.Parent.Parent.Winorlose.SurfaceGui.TextLabel
if enabled==false then return end
enabled=false
local Spending=script.Parent.Parent.CreditsToSpend.Value
local ValueCheck=game.Players.LocalPlayer.Credits.Value --Also tried a local value, which also didnt work as its not in their playergui.
local CredstoGive4Winning = script.Parent.Parent.CreditsToSpend.Value * Multiplier
print(ValueCheck)
print(Spending)
print(CredstoGive4Winning)
How can I get the player without LocalPlayer? Yes I tried by putting the surface gui inside the StarterGui and setting the Adornee, I found it to be very glitchy for the Slot Machine I am doing as I am using script.Parent.Parent a lot, and I also change a part that everyone can see.
