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

Gaining strenght isnt working. Is my script correct? [closed]

Asked by 5 years ago

Doing strenght game. Script is below.

0
Alvinbloxx codes User#24403 69 — 5y

Closed as Not Constructive by User#24403

This question has been closed because it is not constructive to others or the asker. Most commonly, questions that are requests with no attempt from the asker to solve their problem will fall into this category.

Why was this question closed?

1 answer

Log in to vote
0
Answered by 5 years ago

local replicatedStorage = game:GetService("ReplicatedStorage")

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

local cooldown = 1

replicatedStorage.Remotes.Lift.OnServerEvent:Connect(function(player)

print("Fired")

if not remoteData:FindFirstChild(player.Name) then return "NoFolder" end

local debounce = remoteData[player.Name].Debounce

if not debounce.Value then

print("Got past the Debounce if statement")

debounce.Value = true

player.leaderstats.Strength.Value = player.leaderstats.Strength.Value + 25 * (player.leaderstats.Rebirths.Value + 1)

wait(cooldown)

debounce.Value = false

end

end)

0
what's the error? XviperIink 428 — 5y
0
I already told you to do (player.leaderstats.Strength.Value + 25) * (player.leaderstats.Rebirths.Value + 1). DeceptiveCaster 3761 — 5y
Ad