Really simple - Small in size - The whole demo scene is 200KB.
Very realistic / great looking water prefab ready to use(check the demo).
Many properties to create a very unique water and to achieve the desired quality.
Automatically generates a mesh based on the number of vertices given.
Uses a wave simulator prefab to generate better waves.
The water behaves as any normal mesh would do , therefore you can texture it and add any material to it.
Works on mobile.
Well commented code ready to be easily modified.
1 DrawCall for the water.
UnityScript and C#
And more…
Please report back about how it performed on your mobile, Thanks !
Video :-
New (Not Released yet):-
function to record water.
function to loop the recorder water to give illusion of motion and save lots of peformance .
any one intersted in this function ?
Objects do not float on water because this would need to create another mesh that is changing every frame for the collider which would take more performance than the water mesh alone, but each surface vertex has a game object related to it you can probably add a box collider to each of them. I haven’t tried it but I will and if it looks good I will include it in the next update.
It depends on your device and the number of vertices you used , but I have an Idea which is to use only a bit of water and If the screen is moving you simulate the waves to fake it.
This is what i mean , in this video i enabled the box collider for the springs just for testing
it is also possible to cause effects by calling a splash function in OnCollisionEnter and setting the maximum increase and decrease of the water to avoid continuous collision
The new update is pending verification in the asset store it should take 2-3 days.
New features in the update:-
C# Version added.
Function to raise the height of the water during run time.
I’m very interested in this, but I would like to know some things:
you said objects can’t float on the water, so this scenario is not possible, is it: a little ship, where the MainCharacter is standing on, which is floating over the sea to the end of the level and has to…I don’t know…avoid obstacles or something like that
is it possible to change the colour of the water?
how many DrawCalls are there (for example in your setup) ?
Hi, When i said the objects can’t float on water i meant that there is no collider mesh for the water but instead you can enable collision on the “WaterBlocks” prefabs by disabling the " Is Trigger " then you will have a collider on the surface of the water so then objects can walk on water and will collide with it as the video i uploaded.
2-the water is a normal mesh you can do with it what ever you do with any other mesh , in my video i added a texture.
3-the water has only 1 draw call, but the whole scene with the clouds and ships and stuff had 14 draw calls
It’s better not to use another mesh as a collider for the water, in the new update the surface of the water act as a collider if you uncheck the "is trigger " on the waterblock prefab which is a lot better in performance.