[Community Project] WIP Weather & Water Shader

That is the behavior of our current gerstner wave implementation. Some spots of the will end up having multiple waves overlapping which causes the amplitude to multiply (or end up with spots with not many waves overlapping… whichever it is :stuck_out_tongue: I’m not sure).
It’s not really a random , even if it might look at it :p… the same waves will go over the same spot over and over again.

I can see how can be a bit of a problem but the player will be moving all the time anyway plus you should have multiple test points around the player… so if for example your threshold for playing a sound is 300 then eventually the player will be at a spot where the wave goes over 300.

Don’t let it confuse you, the mesh is only a visual representation of the :stuck_out_tongue: you will get a wave height value everywhere. Also buoyancy works everywhere currently.

If you want to detect if you are on land or detect depth then you can do a trace.

Anyone know a tutorial or how to make swimable?

You can add a physics volume in the level then enable the Water Volume variable.

I believe both the and TK branch already have swimable volume in the example map, the thirdperson char in the TK branch also has correct character swim control (all missing is some swim animations :p)

I was wondering if it is possible to use depthfade to flatten the water under small vessels like rafts and canoes? or maybe there is another way to do that?

With depth fade no… there are other ways but you will probably have to mathematically define the shape and location of the flat area.

However since there is no array support or for-loops in the material editor (seriously guys, start bugging Epic about that :p) it means you are limited to a pre-defined number of “flat locations” that can work simultaneously (which you would have to manually pass into the material instance via parameters).

If we are talking about a single raft which could be easily defined as a rectangle then it can be done though.

Me again :slight_smile:

Small problem - I’m creating an infinite loop. I’m not sure how to control the whileloop. The UE4 documentation suggest using an iterator but I don’t see that node :frowning:

is still a bit bare bones:

Also, as is really a general query about blueprints and not specifically linked to the project, let me know if it’s best to ask outside of thread - I don’t want to pester you when there are others out there who will, I’m sure, also have suggestions :slight_smile:

The attachments you posted are not working for me :stuck_out_tongue:

If it’s not specifically linked to the project, feel free to send me a PM or make a thread in the blueprint section of the forum :slight_smile:

Hello and work :slight_smile:
I was wondering if there is a way to make the plane be affected by a “nav mesh bound volume” to enable the use of AI/bots?
Unless there is another way to move, say a boat around to specific coordinates/waypoints, have tried “set location” hooked up to a timeline and a lerp but it makes my pawn jump and act unnatural and it jump around at the target location.

I don’t know if is some windows visual c++ compiler vs clang on thing but I get error trying to compile the branch.

From what I can see, CustomZSeekMax is not supposed to be a pointer so I don’t understand why you would use NULL there instead of 0.0 or some other constant.

Thats odd becuase im getting :

I looked into it and it looks like Actor was removed in the FDestructibleChunkInfo. Anyone have any ideas on any other ways to grab the Rigid Dynamic?

I get that once I change them from NULL to 0.0, I tried looking for an example but I could not find one.

I got it to compile, by using the following code. Who knows if it actually works but it complied.

Are you guys trying to compile using 4.8 preview? (there is no 4.8 version of the plugin yet :p).

Yes we are, i know their is no 4.8 version but i needed to move our project to 4.8 for some things. I got the plugin running in 4.8 with no issues so far.

change line #49 in file Plugins/OceanPlugin/Source/OceanPlugin/Private/BuoyantDestructible.cpp from:

physx::PxRigidDynamic* Chunk = Each.Actor;

to:

physx::PxRigidDynamic* Chunk = Each.OwningComponent->ApexDestructibleActor->getChunkPhysXActor(Each.ChunkIndex);

That may or may not work, but it compiles.

There are more issues getting it to work with 4.8 though, all I did was click play and it CTD.

Try

works even when playing for me.

For me, with your method, it crashed at line #584 in file >> Unreal Root Dir <</Engine/Source/Runtime/Engine/Private/Components/SkinnedMeshComponent.cpp

Full function:

Are you on windows and/or which branch are you building with? I am trying to build with 4.8 from .

when I tried my previous method it crashed in void ABuoyantDestructible::Tick(float DeltaTime) on line #93 in file Plugins/OceanPlugin/Source/OceanPlugin/Private/BuoyantDestructible.cpp

Yes i am on windows, i am using the branch from .

Here is the commit where they made the change.

!!EDIT!!

Here is my complete terminal output.