Hello, I’m trying to make a gambling game with minesweeper style
What is the issue? Include screenshots / videos if possible!
The money collecting part where the player take out the collected money I fire a remote function that takes in the collected amount of money so the exploiter can simply put instead of collected money an amount that they want. I need another way to save the collected money and add it to money
leaderstats
--An example for my script (Local Script)
local TotalMoney = 0
field.Activated:Connect(funtcion()
TotalMoney += 5
end)
Take.Activated:Connect(function)
setMoneyFunction:InvokeServer(TotalMoney)
end)
--Server Script
setMoneyFunction.OnServerInvoke = function(player,amount)
local leaderstats = player:WaitForChild("leaderstats")
local money = leaderstats:WaitForChild("Money")
money.Value += math.round(amount)
end
What solutions have you tried so far? Did you look for solutions on the Developer Hub?
I tried to find something about firing the remote function on the DevForum but it didn’t help.
You can try creating a function for when a player joins and cloning the gui into the player’s playerGui, and you can check server-side what they are pressing, and it is not exploitable at all!
Let me know if I was right.
Ok guys, I got the answer to my question which is basically I have to do it on Server Script
Thank you so much, but I’ll stop there. @changeno you said that I can get banned for the game. I will be happy if you explain why, Gambling? copyright? so I can be more careful. I just don’t want any problem.
Probably gambling. Make sure to put a disclaimer that it is fake cash in the game’s description aswell as when you join the game to minimize your risk of getting a termination.