Hi, In first Sorry for my english

I would like to make points-adding tool (so first tool adds 1point, second tool adds 2points etc.) How much points tool adds it's write in variable "ile". If i activate tool "ile" changes as it should, but game add me +50 points, i don't know why it's happened. Its My script: Tool 1:

local module =  require(script.Parent:WaitForChild("ModuleScript"))
local player = game.Players.LocalPlayer
local mouse = player:GetMouse()

script.Parent.Activated:Connect(function()
	game.Players.LocalPlayer.ile.Value = 1
	module.Lift()
	
end)

tool 2:

local module =  require(script.Parent:WaitForChild("ModuleScript"))
local player = game.Players.LocalPlayer
local mouse = player:GetMouse()

script.Parent.Activated:Connect(function()
	game.Players.LocalPlayer.ile.Value = 2
	module.Lift()
	

end)

And script adding points:

local replicatedStorage = game:GetService("ReplicatedStorage")
local remoteData = game:GetService("ServerStorage"):WaitForChild("RemoteData")

local cooldown = 1


replicatedStorage.Remotes.Lift.OnServerEvent:Connect(function(player)
	
	
	if not remoteData:FindFirstChild(player.Name) then return "No Folder" end
	
	local debounce = remoteData[player.Name].Debounce
	
	
		if not debounce.Value then
		

			debounce.Value = true
			player.leaderstats.BitCoin.Value = player.leaderstats.BitCoin.Value + 			player.ile.Value
			player.leaderstats["Total BitCoins"].Value = player.leaderstats["Total BitCoins"].Value + player.ile.Value
			wait(1)
		
			debounce.Value = false			
		end
	
	
end)

1 comment

0

No alvinbloxx code you know what i'm talking about (his stupid poorly coded simulator game). Its against the rules to post codes that arent yours anyways. free models being an example