for some reason does my for loop run twice when it should run once the players steps are = 0 but it runs twice
for count = 0,player.leaderstats.Steps.Value,1 do
print("why")
amountSteps *= 2.3
end
for some reason does my for loop run twice when it should run once the players steps are = 0 but it runs twice
for count = 0,player.leaderstats.Steps.Value,1 do
print("why")
amountSteps *= 2.3
end
print count inside of the loop
it prints one but it goes twice
You have the starting number as 0
, when the for
loop is ran it will start at 0
and continue to 1
and so on.
In this case it will run twice because it starts at 0
and ends at 1
, so you will need it to start and end at 1
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.