Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

What is wrong with this script?

local intermission = script.Parent.intermission
local val = Instance.new('StringValue')
val.Parent = game.ReplicatedStorage
val.Name = 'intermission'
val.Value = 30
while true do
	if val.Value == 30 then
		val.Value = val.Value - 1
		repeat until val.Value == 0
	end
end

this script wont do anything and it does not show any errors in output

2 comments

0

Well.. what is it supposed to do?

0

the admins are pis s ing me off! there was something wrong with this script so i put the question as what is wrong with this script? and the fu ck ing admin said make the question title relevant to my question. it is fu cki ng relevant to my question.

1 answer

✓ Accepted answer

Try using a NumberValue rather then a StringValue. It might not be seeing the StringValue as a Number so it won't subtract anything from it.

2 comments

0

And then use tonumber on the string value to make it a number.

0

thanks that was not the problem but i figured out the problem but thanks for your help

This discussion is preserved as it was. New answers, comments, and votes are closed.