Realtime water-effects?

I once found a Blender demo-file which contained a flag (a plane with a few subdivides), and it “waved in the wind”. It was done with a python script and worked similar to the “wave” animation-effect.

There was only one difference: the wave started from the centerpoint of the mesh (the purple dot). If anyone who know python knows how that was done, is there anyway to nake the wave start from a different point?

Example: a plane with 6 subdivides. A cube collides with it. Can you calculate where the cube collided with the plane´s mesh (in X-Y-Z coordinates)? Also, can you shift the wave effect to that point? Furthermore, can you have multpile wave-effects on one mesh?

I once found a Blender demo-file which contained a flag (a plane with a few subdivides), and it “waved in the wind”. It was done with a python script and worked similar to the “wave” animation-effect.

Hm… yes I rember that demo…its fairly straight forward
http://webpages.charter.net/nikolatesla20/flagcode.zip

There was only one difference: the wave started from the centerpoint of the mesh (the purple dot). If anyone who know python knows how that was done, is there anyway to nake the wave start from a different point?

There are a few eqautions out there for wave motion formulas. The only reason his has a saarting pint is becuase equation he used… A place I love togo for most of the eqations I use is here:

http://scienceworld.wolfram.com/physics/
Wavemotion:
http://scienceworld.wolfram.com/physics/topics/WaveMotion.html

Example: a plane with 6 subdivides. A cube collides with it. Can you calculate where the cube collided with the plane´s mesh (in X-Y-Z coordinates)? Also, can you shift the wave effect to that point? Furthermore, can you have multpile wave-effects on one mesh?

Although you can write up your own collision lib in python for the game engine I would doubt you want to becuase its not the simplest thing todo, plus I am probably guessing it would be vary fast…

even if you still want to do this here is a nice link to help you on your way:

http://www.peroxide.dk/download/tutorials/tut10/pxdtut10.html

simplest thing to do is move the dot. :wink:

just position the 3D cursor where you want to dot (the objects origin) to be, then click on ‘Center Cursor’ in the edit buttons. :slight_smile:

Keith. 8)

just to tell you that there is a demo that has water ripling effect in it. the demo is called “squish the bunny” it’s in the blender game kit and i bet with a bit of searching you could find it somewhere