I honestly have no clue how to script, this was just an attempt. I am trying to change the width of a beam, this is my script.
while true do wait() script.Parent.Width0 = math.random()*15 script.Parent.Width1 = math.random()*15 script.Parent.Transparency = NumberSequence.new(1,1) script.Parent.Enabled = true end
I may be wrong but I believe that it's because there is nothing in the math.random().
Normally, it's
math.random(0,5)
for example.
The first number is the minimum amount and the second number is the max, but these can't be interchanged otherwise it doesn't work.
Also, instead of while true do, try while wait() do, as it's similar to while true do but instead of looping code, it waits before looping, then once the script inside is done, it waits again and repeats.
You should also remove the wait() since it probably won't work there.
If none of this worked, try checked output.