Announcement

Collapse
No announcement yet.

Water

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Water

    Right now Source engine has better water than UDK, cause UDK supplies you with virtually nothing.. I don't consider "fluid surface actor" when the only interaction is physx waves.

    So I'm assuming there is no stock setup for water you can perhaps, swim in? Or that has buoyancy? Lets just cut to the chase here.

    I'm obviously going to have to go into the programming level to get standard water that every other engine has.

    So, is it even possible? Cause I don't want to dedicate to this whole engine if I don't even have the ability to do what I want.

    Is Unreal Script enough? Is there enough freedom to create water EXACTLY like in Source engine, or CryEngine 2...

    OR

    Do you need source code access? Cause if that is the case, doing anything with UDK is worthless for me. My game relies heavily on the presence of water.

    #2
    There is no ready to use water in udk, but there are some ways to make nice water.

    fluid surface actor is rather for ponds and some decoration water/liquid.

    there is water volume, but blurr and color change i hardly call underwater effect, to do this you need to code your own postprocess shader with underwater wavy effect.

    making realistic water surface is doable in udk material editor, however its interaction with dynamic actors would be pain

    Comment


      #3
      For the record, Crysis' water also stays completely flat. It's just a material effect that they use, and can be replicated in Unreal. However, water effects that comprehensive are very difficult to implement in any engine.

      Comment


        #4
        Material editor produces shaders, you can use textures/vertex color for vertex animation and such.

        But somehow you need to update that texture with information about what is going in game, ie. somebody run in water or something splash in. This means you need to paint that texture in realtime. And doing it in script could be slow. "fluid surface actor" is just that kind of stuff hardcoded, but it has limitations you do not like.

        So you can easily make transparent water surface that looks even better than in crysis, a bit harder is to make underwater effect that is more than DOF blurr and color.

        Making interaction for player character only, is also not hard. But making water that reacts to other characters, physx and maybe scripted events is hard to do.

        I did not look what crysis or source games can do with water, so it would help if you wrote what kind of effects or interaction you need.

        Comment


          #5
          You should be able to produce decent shore effects in the material editor. If you're trying to get actual waves on a beach, well, no game has this.

          Comment


            #6
            Originally posted by ambershee View Post
            You should be able to produce decent shore effects in the material editor. If you're trying to get actual waves on a beach, well, no game has this.
            Yes use loft with some flat or a bit curvy surface, this way you get nice uvs along shore line. Then all you need is nicely panned material.

            As for not scripted buoyancy, this makes several problems. You probably can fake it with modified physics volumes, k-actor joints, or even invisible cloth surface. But making ai paths or ai navigation on movable objects is borderline impossible in udk. So if those items float in one spot, or you do not need AI, its doable.

            Comment


              #7
              Originally posted by DIFTOW
              Have you played Half-Life 2 at all? I gave a clear example, the Source engine.
              Uhm, relevance to the post you quoted?
              These people are trying to help you.

              (Also the source engine doesn't have dynamic water...?)

              Comment


                #8
                Originally posted by ambershee View Post
                For the record, Crysis' water also stays completely flat. It's just a material effect that they use, and can be replicated in Unreal. However, water effects that comprehensive are very difficult to implement in any engine.
                Water in Crysis is tesselated. Not much but it's far from being flat ;p.

                Comment


                  #9
                  For someone asking questions, you might try to 1) research and 2) be nicer to people answering your questions:

                  1: waves are ridiculously easy to make via the material editor, it's a simple, simple vertex shader. See here for an example: http://www.youtube.com/watch?v=cfTzUwDeUbM. For more simple ripples see here: http://www.daveprout.com/hack-this/2...ave-water.html

                  2: Yes, you can do a foam effect purely through the material editor, there's many, many ways. Frankly you could also easily fake it just by making a mesh that follows the shore line with a foam material if you weren't very advanced with shaders. You can also manually paint on the foam with mesh/vertex painting, example here: http://www.youtube.com/watch?v=7UNpT...eature=related

                  3: You could implement buoyancy through unrealscript, there's no need for "source code" access to implement it. Since you don't seem to know much about the unreal engine, yes, there already exists a "water volume", that forces players into a "swimming" mode, but no, it does not automatically support buoyancy. As already suggested, you can also fake it through a physics volume (which can coexist with your water volume).

                  If you think the grass is much greener in other pastures, by all means, knock yourself out.

                  Comment


                    #10
                    Originally posted by danimal' View Post
                    For someone asking questions, you might try to 1) research and 2) be nicer to people answering your questions:

                    1: waves are ridiculously easy to make via the material editor, it's a simple, simple vertex shader. See here for an example: http://www.youtube.com/watch?v=cfTzUwDeUbM. For more simple ripples see here: http://www.daveprout.com/hack-this/2...ave-water.html

                    2: Yes, you can do a foam effect purely through the material editor, there's many, many ways. Frankly you could also easily fake it just by making a mesh that follows the shore line with a foam material if you weren't very advanced with shaders. You can also manually paint on the foam with mesh/vertex painting, example here: http://www.youtube.com/watch?v=7UNpT...eature=related

                    3: You could implement buoyancy through unrealscript, there's no need for "source code" access to implement it. Since you don't seem to know much about the unreal engine, yes, there already exists a "water volume", that forces players into a "swimming" mode, but no, it does not automatically support buoyancy. As already suggested, you can also fake it through a physics volume (which can coexist with your water volume).

                    If you think the grass is much greener in other pastures, by all means, knock yourself out.
                    Now that is helpful information and exactly what I wanted to know. Thank you

                    Comment


                      #11
                      Originally posted by DIFTOW View Post
                      Now that is helpful information and exactly what I wanted to know. Thank you
                      No problem, I understand that answers people offer can be opaque, but less demandy, more polite asky You'll find a pretty low tolerance for it here, even if you don't intend to come across as a bit harsh, blame the endless Unity folks and Cryfanboys ("can ur engine make my pwn gamez for me?")

                      It's a full featured, AAA game engine, it can do whatever you want if you're good/knowledgeable enough. The only real exception is source code, and that's *mostly* a question of speed, unrealscript can do 98% of what you need, C++ is just faster (but I apply forces in realtime via unrealscript and there's no "slowness" about it).

                      Comment


                        #12
                        You'll find that the material editor is very powerful.
                        Here's what my water texture looks like:
                        [SHOT]http://i596.photobucket.com/albums/tt46/Wyldhunt/UDK/UDKWaveControl.jpg[/SHOT]
                        It's only the material of course, so it has no effects on the underwater physics, but...
                        It has 4 layers of current. The 2 largest waves are part of the primary Tidal effect that moves in and out on a cycle for large water bodies. The size of these waves are determined by the depth of the water. The deeper the water, the larger the waves. At the shore line, they are much smaller.
                        The 2 smaller currents are directly controlled by the wind actor. They take their direction and size from the direction and speed of the wind. These crash against the shore with full force.
                        There is no actual tessellation. It all works via normals and specularity. I would need better control of the World Position Offset before I could create real 3d waves that tracked my panning waves. You could create tessellated non-panning waves in the mat editor using World Position Offset and Vert colors connected to a Sine.
                        You could add the frothing shoreline wave effect with an inverted Depth Biased Alpha. That way, your texture and normals for it would fade in as it came close to shore. Just pan it with your main wave texture so that they line up.
                        If you want the foam to stay behind and fade out, you'd need a particle effect.
                        EDIT:
                        After thinking more on this, you could probably have your extra foam that sits on the shore and fades out in your material by having it connected to a very strict inverted Depth Biased Alpha so that it only showed up in very shallow water. Then connect its remaining opacity to a sine so that it would seem to fade out and in. You'd have to time the sine to match the waves, and do some fancy tricks to make it jump to its fullest opacity when a wave hit. Then fade out. It should be doable though.
                        You could also add a BumpOffset to add parallax height to the waves, although I decided that I wasn't fond of the effect.

                        Comment


                          #13
                          That is absolutely wonderful! Thank you

                          Comment


                            #14
                            The tutorials that I began with were really good. I just built on top of them.
                            Here are some links to tutorial sites with everything you need to get good water materials:
                            http://www.chrisalbeluhn.com/3D_Tutorials.html
                            http://www.hourences.com/book/tutorialsindex.htm

                            Comment


                              #15
                              this is almost precisely what i need to know!

                              i do have a few other related water questions so i'll post here first rather than start a new topic.

                              1) i need aestheticly pleasing water to flow down a sloped street and i'm hoping it's as easy as modifying the advice given above or is there a better way to give the effect of water flowing downhill?

                              2) the water is shallow and the player and npc's walk through it. obviously i'll have to modify the character movement and animation but will i have to add a particle effect for the water hitting the characters legs or is there a fluid dynamic that could work better or perhaps some other way?

                              thanks in advance,

                              vin

                              Comment

                              Working...
                              X