#leaderboards
69 messages · Page 1 of 1 (latest)
when you add the leaderstats you can add to it using
leaderstats.Speed.Value += 1
ok ty
where do i add it this is what my script looks like rn
take a look at this
tutorial how to make a loop
"Making the Script Wait" is the section you want
you basically need to use wait(1) or task.wait(1) to wait a second in a loop
and in the loop you can use for loops to loop thru players and add coins to their leaderstats
the for loop for players isn't documented so let me show you how to do it
no so basically my game is where every second your speed increases +1 im tryna figure out how to make the leaderboard add +1 speed every time the players speed increases
so you have the speed increase but you don't know how to implement so it adds to stat?
yea pretty much
could you show me the speed increase part?
the speed increase script?
yes
after setting the currentSpeed on the server do:
player:WaitForChild("leaderstats").speed.Value = currentSpeed
so do i add that under this
?
no
in the while loop
you could also do math.floor(currentSpeed)
instead of just currentSpeed
im new to scripting how do i do that
player:WaitForChild("leaderstats").speed.Value = math.floor(currentSpeed)
where does it go im so confused sorry
under currentSpeed = currentSpeed + speedIncrease
yes but without the Z on the end
oh yea ok now what do i do?
that's all
where is this script?
and what kind of script is it?
the leaderboard script
.Parent is lowercase on speed.parent
is that why it aint working
probably not but still that's a mistake
did you remove the Z from the end?
ye
** You are now Level 4! **
any errors in the output?
is there no error about the script?
not sure can you double check
this is the leaderboard one
and the two speed increase scripts
@merry ermine
idk