so i wanna know if a value is inbetween 2 other numbers for ex if 1 value is inbetween 4000 and 5000, how do i do that?
my attempt:
if script.Parent.Values.RPM.Value <= 5000 and script.Parent.Values.RPM.Value >= 4000 then
print("f")
end
so i wanna know if a value is inbetween 2 other numbers for ex if 1 value is inbetween 4000 and 5000, how do i do that?
my attempt:
if script.Parent.Values.RPM.Value <= 5000 and script.Parent.Values.RPM.Value >= 4000 then
print("f")
end
This discussion is preserved as it was. New answers, comments, and votes are closed.
4 comments
There doesn't seem to be anything wrong with this. Are you getting an error or does nothing print? Is script.Parent.Values.RPM.Value a valid pathway?
What exactly is RPM. If it's a stringValue the for loop won't be true. You're going to have to convert it to a number using tonumber().
its a numbervalue, yes its a valid pathway and im getting no error and no print
ok i fixed it i didnt realize it but i didnt make it so it runs it when the value was changed thx for yall help yes