Smooth Water

Blitz3D Forums/Blitz3D Programming/Smooth Water

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

Hello,

I'm trying to make a plane of water move up, then back down, to simulate the waves. I'm not sure if this is how you would normally do it, but I decided it would be the easiest way, and it would still look OK. Here's the water updating code:Function MEDIA_UpdateWater()

If EntityY(water) <= 5
w_move# = 0.002
ElseIf EntityY(water) >= 5.15
w_move# = -0.002
EndIf

TranslateEntity water, 0, w_move#, 0

End Function[/code]

w_move# is initially set to 0. When the program is run, the water plane goes up and down, but it looks so uniform, and not very smooth and water-like. What should I do to fix this?

Thanks,
No Enemies