Realtime water reflection, refraction and physics – Nucleotide | Game development diary #12

Realtime water reflection, refraction and physics – Nucleotide | Game development diary #12

Hello there, Ivan here, bringing you updates on the
Nucleotide game development. From the last development diary,
I’ve improved the water surface shader, or more precisely,
water surface effect. I’m calling it effect because it requires
render-to-texture and some additional C# code, for camera transformations, in order for it
to simulate real-time reflections. This effect also simulates light refraction, which makes everything underneath
the water surface look distorted. It might seem at first that this effect
is visible only around the player, but that isn’t the case. If you look closely,
to any other part of the scene, you can see that the water
isn’t completely still, at any time. I took that feature from Unity’s Water4 example,
and made some modifications, in order for it to work with water surface physics,
that were already in the game. Additionally, I’ve made some changes
to player swimming animation, and speed; When playing with it before, I had a feeling
that the player is struggling with the water, which should not be the case. I want him to dominate his environment in every way. Eventhough this guy looks like a frog, he isn’t. My goal wasn’t to realistically simulate a frog,
nor frogs moves, so all deviations that you see were probably intentional. I also started working on the tongue, again. I can now shoot the tongue
towards nothing grabbable, and it will make a slightly different shape
every time it get’s out. I can also, as before, grab objects
and drag them around, this is obviously far from done, but it does work. I took some time to create a decent
looking scene for this video, it is far from what I want
to achieve in the finished game, but you can definitely see where
the art-style for this game is heading. If you, by any chance, like this video,
you should click the like button And, subscribe, if u’re not subscribed. If you have any questions, comments or suggestions,
you can leave them in the comment section. My name is Ivan Mandić, thank you for watching.
See you soon, bye!

You may also like


  1. Yes I will. All assets on the scene are made by me. (except the ground texture, but that is just a placeholder)

  2. Wow, and I'm thinking of ways to make it more realistic. I'm glad you like it. Thanks for the support!

  3. Very nice! I've been looking at your videos since the water physics with the rubber ducks. This is so far looking to be a very good game that you've created!

  4. It looks more AWESOME than ever. You guys are great and so will be the game. I hope you are thinking of releasing a demo scene, so we can play with the frog too !

  5. Great stuff again! Very nice water effects. Still wishing you would do Q&A about your programming stuff. =)

  6. Great frog…..
    But i have an idea leave Matej to lead development diary for example next 😀
    Will the frog able to dive?
    Will I be able to go to the mainland?
    Will the map be deeper and shallower areas?

  7. Very nice… good progress. But we already know that you work a lot. So, let me, please, give some suggestions. Current water environment is too sterile. Add some leafs to water, some dirt, other underwater fauna & flora, same as you have outside. Some wind or breeze over the water surface would be just awesome and distracting to the player to make it a bit harder as game progresses.

    Other thing is the interaction of main character with the water… it feels too sparse… more like alcohol.

  8. Nisam pogledao jos sve sto ste postali ali jos nisam nasao neki opis igre koju pravite. Trenutno me najvise podsjeca na nesto tipa Gex iz starih ps1 dana. Cemu ce igra biti slicna, na koji nacin ce se igrati ?
    What is the game going to play/feel like ?

  9. This game will be an action adventure, I can't find anything to compare it with. Main character will use his tongue to overcome obstacles, and defeat enemies along the way. That is all I can say about the gameplay at this point 😀

  10. The graphics look pretty good. Maybe you should consider adding some color to the water. In the last video the water had a bit of a blue tint to it and it looked much better. It doesn't have to be a blue color, for this scene brown would fit better. Just a suggestion, try it out.

  11. Fully transparent water was intentional, water color will vary from level, to level. Completely clear water and dark shadows give the feeling of freshness and warmth. (A hot summer day, for example)

  12. Caustics could be simulated, but there will be no need for such effect. (Once you see the next development diary, you will know why). Thanks for your comments, they are always constructive 😀

  13. Bra'o Ivane. Pozdrav iz Bosne. 😉 Mozda bi bilo dobro da pokusas napravit da jezik ne zaokruzuje objekte, vec da se naprosto zalijepi na mjestu pogotka (u jednoj tacki). Imam neki osjecaj da bi efekt bio bolji. Ipak trebas testirat. 😉 Mozes napravit da se jezik na mjestu pogotka malkice razlijepi (ako me kontas). 🙂 To bi se zvukovnim efektom kasnije jos usminkalo. Zvuk bi mogao ovisiti o materijalu objekta, i tu vec dobijas na efektivnosti. Ali, kako rekoh, ipak sve testiraj. 😉

  14. O pa poštovanje 😀
    Omotavanje videa će ti u sljedećim videima biti jasnije…ne radim simulaciju 😀
    Diary #13 će pokazati neke novotarije vezane uz jezik, klikni subscribe ako te zanima. Hvala na javljanju, drago mi je da ima i domaćih ljudi zainteresiranih za ovo 😀

  15. Nice one dude…
    I was wrong in u r previous video, in that because of floor color it is very difficult to notice

  16. He's a member of a made up species in some parallel universe, look at it that way. Eventhough he looks like a frog, and has certain characteristics of a frog, he isn't one!

Leave a Reply

Your email address will not be published. Required fields are marked *