I haven’t yet but I did notice some objects floating in front of the crests, such as the Buoy mesh I have in the video posted earlier. I thought that having the separate test points each providing their own force would be enough to counteract that behavior, but doesn’t seem to be in some cases. Thank you for mentioning I completely overlooked that part, but it explains a lot, I will work on getting that fixed!
Yes I have seen that one, and have played with it a bit over on ShaderToy.com. It is a really cool method of creating waves, but as you can see from the video it is way too slow to be used in a game. It could possibly work if it was optimized and used with a dynamic LOD system to reduce the complexity, but it is not something I plan to integrate into project. Also the code is Copyright protected, not sure what licence it is under but the author would need to give you permission to use it in the engine.
@:
Yes that is no problem! Feel free to create videos showing how it all works and any changes you make to it, it is a free project so no worries there. I added the request for a link back to site for a specific situation that came up, but also wan’t the viewers to get the latest version of the project, and/or get tech support on it.
I’ll leave it up to you whether to add it or not. It’s not really a requirement, just more of a request really.
Would be if you can leave a link to your video here as well, would love to see it! And if you are able to add to the project that would be as well! Look forward to seeing what you come up with
Alright, Ill be sure to let you know how it goes, I’m hoping that a vector movement with gravity is all I need, but I’m sure 's buoyancy should do the trick, if not going to have to alter some settings.
Have you downloaded the latest version of project? It includes 's code for the BuoyancyMovementComponent and has Buoyancy working correctly. If you haven’t already downloaded it, give it a try, and/or compare it with yours.
It doesn’t have his older .h and .cpp, but I’m glad that you have advanced it so much. will take me a while to configure everything. Good news is that I was able to merge my progress over to your demo. I have flying AI moving over the water patrolling and shooting at me. Now I just need to spend some time in Maya and make some warships to get the effect I want.
OK got it floating now, you can see the patrolling ai in the back of the picture, now I just need to get it moving. will probably take a while bear with me.
I have been working on a senior project for college with an Aquarium. The work you have done is great, and I was wondering if you would be interested in my fish flocking c++ code as a contribution to project. Over the last week I have implemented boids flocking into our team’s ue4 project. My current code creates semi-realistic fish school behaviors. The code also allows you to create a “predator” fish, so the fish not only school, but are apprehended by predators and flee and re-group in a semi-realistic manner. I’ll post a video showing my current progress tomorrow if I have time. If would interest you at all let me know, I would love to be a contributor and further the ue4 community!
Here’s my initial flocking implementation for your enjoyment, the video quality is ****, and the playback freaks out when I go above the water, but you get the gist of the flocking:
Whoops… Didn’t realize there were so many new posts, sorry for the delay !
[QUOTE=;217737]
It doesn’t have his older .h and .cpp, but I’m glad that you have advanced it so much. will take me a while to configure everything. Good news is that I was able to merge my progress over to your demo. I have flying AI moving over the water patrolling and shooting at me. Now I just need to spend some time in Maya and make some warships to get the effect I want.
Oh here is my Channel, its a work in progress :)sUjgiNXWAEA[/QUOTE]
Yeah sorry about that, but I don’t have a copy of the original code. I use the structure of it and then add in a couple of Structs to hold variables to allow the individual Gerster waves to be modified more easily from a blueprint, otherwise the basic setup can all be seen in 's video. He doesn’t show the .h file but the OceanManager.h in the latest download can be modified to change it back to his original code pretty easily. The OceanManager code will not provide buoyancy on it’s own though, you will need to setup a blueprint to handle the calculations. I have a nearly complete version of it in the original download, called BP_OceanManager, but it is not fully working.
At some point in the future I will see about making a blueprint only version. It can be done, but will likely be much slower than the code version. I have managed to get the code working as a plugin now, so hopefully that eliminates the current issues when trying to migrate the content out to another project.
Looking good ! Let me know if you run into any issues with the buoyancy part.
Hey there, as far as I know it is not possible to output the calculation from the material. I have instead been looking into possibly calculating the waves in code and passing the end result to the material through a Material Parameter, but the other way around is not currently possible.
Take a look at the BP_OceanManager blueprint from the original download (on the first page of thread), it has nearly everything needed to do exactly what you are looking for, except it goes going from blueprint to material through a MaterialParameterCollection. I never got working properly, but it is something I will look into further in the future. If you are able to get it working I would love to hear about it!!
I definitely have seen these videos! I am pretty sure I have seen pretty much all of the UE4 videos out there, I wanted to see how else put it together so I have (and still do) look for them. The method he is using for the shore is a depth fade, which I use as well and could configure it to look very similar, plus removing the current shore foam. is an area where the material has improved recently, hope to have it out shortly.
Hey ,
That looks really cool, I would love to add it to the project!
I am currently working with two separate projects. One is mainly for above the surface with buoyancy, and the other is all of the above plus an underwater area where a character could swim, or go diving etc. So that would fit really well with the second version.
So absolutely it would be great if you can provide it as well! The underwater part is rather boring at the moment… no plant, fish or anything. Just trying to get the look and the physics right currently, but I will need fish!
Thanks for offering! I think that would make a great addition.
EDIT: Have you been able to figure out why everything goes crazy out of water? If is being caused by project please let me know if I can help in any way. It looks almost like the turtle is leaving the water and the calculation is stalling, but I can’t make out the red error text from the video. Again, let me know if I can help!
Hey ,
The craziness when out of the water is due to the video recording software I used, so don’t worry about it ;). Next time I’ll try to use a better screen capture. The above water looks fine, and hopefully it shows up better next time I record. The red output is just “eating” when a shark eats a fish. It was used for debugging is all.
Vodoo,
Thanks for the compliment! Hopefully I’ll be able to give you all the c++ files and a short tutorial on how to implement the flocking in your own ue4 scenes!
Hehe looks like water is getting quite popular in 2015 if it ever stopped being popular…
Great to hear it, can’t wait for an update… Feel really bad because I can’t contribute anything, is way out of my current league, but still like playing with it…
Curious about one thing - sound. How can that be handled in more realistic manner? Sure, slapping “” sound would work, but is it possible to like get multiple sound files, ie:
sound1 - when the is calm
sound2 - when the wave breaks
sound3 - when the wave is reaching its peak
sound4 - when the wave is “losing” its altitude/power
Then, to somehow wire it up so particular sound fires off when some condition happens. For example when each wave hits and breaks (don’t know the correct terminology, sorry all) on the beach it should fire the sound2, when wave reaches its peak, sound3 fires off… And all sounds fires for each individual wave based on certain radius from the player (so it doesn’t take much of the performance)… then if player was to fly over the , the sounds should be as realistic as possible because each sounds particularly describes each wave that’s in proximity…
Could be an overkill, just saying and wondering
EDIT: Actually that seems like OVERKILL, now that I think about it… Totally unnecessary, forget I mentioned it…
Actually we could make a simple blueprint that plays sound whenever a wave passes over it. Just place the blueprint higher than the water plane and have it monitor water height at it’s point. Placing one of these on a beach would give you the trigger you need for a wave hitting the shore.
But a general ambient sound matching the wind conditions would be enough and for the beach just having a periodic should of a series of wave crashing would also do.
Now that probe I mentionned would be very useful near rock formations as you can have it trigger a particle spray at the same time a wave hits. way you get to see and hear crashing waves.
Great news, I have combined predator and flocking fish into one c++ file. Now flocks can pursue other flocks :). I will try to give out my initial code weekend and post another video. I finally was able to get everything into the c++ file, so there is no need for any blueprint gobbledygook. It is easy as parenting a blueprint to the “fishflock” class I have made, and giving it the attributes you desire: enemy types, prey types, neighbor type, speed, turnSpeed, distanceFromLeader (min, max) , (boolean) isLeader, pursueDistance, fleeDistance, pursueSpeedMultiplier, fleeSpeedMultiplier, distanceFromNeighbors, max/min vector of underwater box, and a few others I may have forgot to mention.
There are still many issues that I want to clear up in the next few months, but since our project team only has 7 weeks to complete a game, I wont be able to work more on for the next 3 weeks. Some of the current issues I want to fix/add: avoidance behavior when the fish sees a mesh, better steering when near top of water/sea floor, better spawning, better flock v. flock behavior, and smoother movement.
I’m new to unreal engine and looks amazing could you explain how I would add to my project in unreal engine in other words where do i put the files i download any tips would be greatly appreciated!!
answered already with an ideal solution, so I will add the info to my todo list on the Trello board. Thanks for the suggestion, and thanks for the explanation !
Sounds good man! Take your time, it’s no rush. Look forward to seeing what you come up with!
Hi there! Welcome to the
The download is actually a complete project you can open by double clicking the “OceanDemo.uproject” file from the OceanDemo folder after you extract the zip file. The latest download is for UE4 version 4.6.1.
Right now it is a huge pain to transfer out the files to another project, but I will have that fixed for the next version using a plugin instead. Let me know if you need some more info!