Hello, I need help, I need to use math.random() in my script and to make it easier to customize, I made the lowest and highest number a number value, but it doesnt work, is there any reason why?
return function() while true do wait(script.Parent.Parent.WaitDelay.Value) local lowest = script.Parent.Parent.LowestSpeed.Value local highest = script.Parent.Parent.HighestSpeed.Value local speed = math.random(lowest,highest) script.Parent.CylindricalConstraint.AngularVelocity = speed end end
Thanks.
Make sure they both arent 0 or the same number.