Hey so I’m working on a local selling script it keeps saying expected end to close function I’m still new to this so any help would be appreciated here is the script
local Machine = game.Workspace.Sell
local PP = Machine.ProximityPrompt
PP.Triggered:Connect(function(player)
local stat = player.Stats
if stat.Paper.Value < 1 then
end
elseif stat.Paper.Value > 1 then
stat.Paper.Value = stat.Paper.Value - 1
stat.Coins.Value = stat.Coins.Value + 1
end
end)
local Machine = game.Workspace.Sell
local PP = Machine.ProximityPrompt
PP.Triggered:Connect(function(player)
local stat = player.Stats
if stat.Paper.Value < 1 then
return
elseif stat.Paper.Value > 1 then
stat.Paper.Value = stat.Paper.Value - 1
stat.Coins.Value = stat.Coins.Value + 1
end
end)