At the end of 2019, Unreal Engine 4 is one of the most popular game engines for indie developers. Due to the incredible popularity of Fortnite, Epic Games has earned a lot of money, and now their game engine has improved much more often. However, in the engine there are a number of things that are difficult to implement with ready-made tools. One such thing is real-time fluid simulation. We’ll talk about it in more detail.
My need for fluid simulations came about when creating a Ranch Simulator. We had the idea to interact with the fluids in the game, so that it would be much more interesting to pour water to the cattle or milk the cows. Exploring the Internet, I was able to find only one technology with which you can create a similar simulation, and it is called Nvidia Flex.
Despite the fact that the technology was created by Nvidia, it works on the latest generations of graphics cards from AMD as well. There is a separate plugin for the Unity engine to help add flex to the project. However, for Unreal Engine it is necessary to make a lot more effort to get the flex to work – you need to assemble the engine from the source on the github.
However, the official version of the engine with the integrated flex is 4.19.2, and the latest version of the engine itself is already 4.24.
In version 4.22 and larger, the engine has been greatly changed, and it’s no longer possible to transfer flex to the new version of the engine, and developers from Nvidia will no longer be able to release updates with a 99% probability, since now they are all interested only in their RTX technology.
There are also enthusiasts who are trying to update Flex on their own for the new versions of the engine (The official forum of Nvidia Gameworks for Unreal Engine 4). Thus, the latest version of the engine, on which it is possible to use Flex – 4.21(Thanks to Olento). Since then, changes in the rendering and physics of the engine have become so significant that it is already impossible to compile the project without corrections in the engine itself.
In our case, we had to abandon the use of Flex, because we needed the latest engine version, since 4.21 is not the most stable version. Thus, one of the very promising and cool technologies from Nvidia was forgotten by its creators themselves, in order to support RTX technology.