Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
1

How do I fix WaterWaveSize not changing sizes in my script?

Asked by 3 years ago

I am attempting to change the size of the waves, but when they are tested nothing happens.

while true do
print ("Weather: Neutral")
script.Parent.Terrain.WaterWaveSize = 0.15
    wait (15)
    print ("Weather: Wave Size: 1")
script.Parent.AlarmSFX:Play()
script.Parent.Terrain.WaterWaveSize = 1
wait (30)
end

It remains the same size. I have checked output for any errors, but nothing happens.

1 answer

Log in to vote
0
Answered by 3 years ago

I'm assuming your script is located inside of Workspace. I don't really see an error with your script, aside from incorrect indentation. Try this:

while true do
    print("Weather: Neutral")
    script.Parent.Terrain.WaterWaveSize = 0.15
    wait(15)
    print("Weather: Wave Size: 1")
    script.Parent.AlarmSFX:Play()
    script.Parent.Terrain.WaterWaveSize = 1
    wait(30)
end

Also, please remove the spaces between your wait and print statements, it's quite messy and confusing (e.g wait (30) is wrong, however wait(30) is correct)

Have a nice day!

Ad

Answer this question