Features
- Realtime shallow water simulation – fluid data modifiers, wave generator, and extendable interface
- Fluid surface rendering – caustics, wetness, underwater, waterline, advected foam, advected waves, blending with the ocean, dynamic audio detection.
- Fluid Interaction – simple cheap ripple solver moving with character, optimized to an absolute minimum
- Ocean wave blending – rendering tillable ocean heightmap texture in a single pass
- Niagara environment interaction – High-quality effects, bouncy plants, character swimming, boats,
- Clean, efficient, GPU-friendly implementation, interface designed with the KISS (Keep It Simple, Stupid) rule in mind
- Tool for generating ultra-fast static meshes with flow maps baked into vertex color and uv.
- Advanced fluid state management and loading state in gameplay.
- Niagara fluid async readback system for sampling height and fluid flow in blueprints.
- Dynamic audio analyzer. The sound source is positioned based on fluid movement.
- Velocity-based fluid flow advection method for foam caustics and waves
Limitations
With great power comes great responsibility. I am committed to being a reliable marketplace creator, so I must communicate the limitations and disadvantages of using simulations. The Fluid Flux system is somewhat overhyped, so please read the description below and ensure that everything aligns with your expectations and requirements before purchasing. Ensuring that is crucial for the Refund Policy
- While Fluid Flux represents a significant advancement for the game industry, it also introduces additional challenges. Controlling and adjusting simulations can be demanding; sometimes, a single parameter change can alter the fluid flow across an entire map.
- The Fluid Flux simulation is based on the Shallow Water Equations (SWE). It is calculated in 2D on a heightfield mesh, meaning all obstacles are rendered to a heightmap using top-down projection. Fluid can not be simulated in caves. However, the algorithm can ignore particular objects, such as bridges, so they do not interfere with the simulation.
- Scalability is a real problem.
The simulation domain requires allocating floating-point render targets and updating every frame, which may cost a lot.
The size of domains can be increased by changing the precision of details per simulation cell. Ocean setup does not require allocating memory, but rendering water is limited by floating-point calculations. You may encourage many unpredictable behaviors like disappearing post-process and surface far from the center of the map; 20 km in every axis is the limit.Domain Resolution Precision
Maximum domain size
Simulation up to 1024 x 1024 up to 100 cm per pixel 1km x 1km Coastline (island) up to 2048 x 2048 up to 1000 cm per pixel 20 km x 20 km (pixel size 500 cm) Ocean n/a n/a 40 km x 40 km (limit of floating point) - Efficiency may sometimes be a problem. I recommend avoiding the use of resolutions larger than 1024×1024 in games. The calculation of a large-scale simulation often requires a substantial number of computations. I suggest utilizing the lowest feasible resolution for the simulation. For example, the maximum resolution in the example demos I provide is 1024×256 (BeachMap). The simulation frame can be baked into data assets and rendered without the additional cost of updating the simulation, which is incredibly efficient and valuable for rivers. You can also lower memory consumption by additional compression.
- Multiplayer is not supported for dynamic simulation because synchronization of render targets is limited. However, the system can be used in a multiplayer game if your gameplay is not dependent on fluid simulation results.
- Statically generated mesh of water can be inconsistent with waterline post-process. This issue will be addressed in the future.
- Water Plugin is not supported in the current version. Combining my water material with the water plugin mesh is possible but not officially supported.
- Niagara fluid readback used for buoyancy and fluid detection returns results with (at least) one frame delay. It’s good enough for most features like swimming fluid detection but not 100% reliable. Trace hits with dynamic fluids are not supported now.
- The system is advanced and complicated, so it may be overwhelming for beginners. The code is clean and elegant, but blueprint reading skills and example code analysis are required.
- The simulation area can’t be rotated. The product supports only axis-aligned rectangular volume.
- The simulation area can’t be moved in runtime. Movable volume is one of the most important features for future updates.
- The simulation domain does not support the wave break effect because the fluid approximation does not contain the needed data to render it.
- Underwater glass, holes, and the submarine view/glass are not supported yet.
- I always answer support questions, but my availability is limited due to the many requests. I am concurrently working on updates to improve quality and efficiency. If there is no response, ping me again after a few days.
- The weakest point of this product is its documentation, which may be incomplete in some areas. I may not excel at explaining things, but if you have any issues, I will try to resolve them. Please don’t hesitate to ask.
Known issues
- Ground capture cannot cache dithering-based meshes. There is a workaround for this problem, and more information is available in chapters related to ground capture.
- “Real-Time” render mode is required to simulate in the editor. Otherwise, the view will not refresh after each frame. Plants also will not load properly on the map if you are not in “Real-Time” render mode in the editor. Its limitation of blueprints: I don’t have any event that could be executed after loading and adjusting Niagara effects.
- Rendering underwater translucent mesh is a challenging problem to solve. Single-layer water materials do not support translucency, so translucents are invisible when watching surfaces from above water. The Fluid Flux mesh-based post-process material implementation is more functional because it can be overlayed before translucent meshes.
- Shadows on water may look a bit blocky. This is a limitation of the single-layer water material in Unreal. Epic improved it in version UE5.3, and it should look better.
You will have to enable Virtual ShadowMaps, and you will also add those lines to your DefaultEngine.ini:r.Water.SingleLayer.DepthPrepass=1
r.Water.SingleLayer.ShadersSupportVSMFiltering=1
r.Water.SingleLayer.VSMFiltering=1 - The maximum heightmap range is 32000 units. This limitation was introduced with Unreal Engine. The problem is related to rendering clamped colors to render targets for unexplained reasons.
- Single-layer water material mode is not properly supported on mobile. It’s an engine limitation that should be solved on the Epic Games site. Generally, this material mode does not support the absorption coefficient on mobile so that water will look differently.
- Strata/Substrate material mode is not supported.
- Path tracing is not supported because Single Layer Water mode does not work.
- The PS5/Xbox shader compiler defaults to 16bits float per channel, which means you will have to lower the precession settings in the simulation domain to make it work on console platforms. Unfortunately, this change may cause water loss, as 16bit is not precise enough to simulate conservative water flow in the long term. Please pay attention when your gameplay depends on simulation results.
- The underwater post-process effects in VR mode only work when Project Settings > VR > (enable) Instanced Stereo = false. This rendering mode breaks rendering the translucent meshes and should be disabled.
Good and bad practices
- Avoid using a large simulation resolution because you will quickly run out of memory; 1024×1024 seems like a good compromise.
- Don’t make your gameplay rely on fluid simulation in multiplayer because it can’t be synchronized.
- Avoid using Fluid Flux on flat surfaces; subtle slopes are always better.
- Avoid hard-edged geometry (boxes). It can be approximated wrongly in height maps, and steep slopes sometimes look terrible.
- Try not to overestimate this system. If I haven’t prepared the ocean with ships and a vast island covered by rivers and simulated lakes, there is probably a reason for that.
- Try not to update the simulation ground in every frame. It may cost you a lot of performance.
- Meshes using the materials with “PixelDepthOffset” active may not render appropriately into a ground height map. A simple workaround is described in the chapter Ground Capture->Solving issues.
Questions & Answers
- How it works?
The Fluid Flux simulation implementation is based on the Shallow Water Equations (SWE) solver. The algorithm was published by Matthias Müller in “Real-time Simulation of Large Bodies of Water with Small Scale Details”. Simulation is calculated on heightfield mesh, meaning all obstacles are rendered to heightmap using top-down projection. Fluid flows in X and Y directions between cells of the grid that describes the volume of water. Forces that move fluid are calculated based on the difference in ground + water height in neighboring cells. The coastline system uses the signed distance field to describe the edge intersection of water with the ground and renders animated wave profiles based on wave movement. - Can I use Fluid Flux in my game if I purchase it?
Take a look into the general unreal marketplace license. You can use it in your projects/games and release it in-store. However, you are not allowed to publish/sell the source code of the product. If the Unreal Engine licensing model does not fit you, contact support so we can create a custom license to match your unique and specific requirements. - Is Unreal Engine 5 supported?
Yes. The Fluid Flux was initially developed and tested on Unreal Engine 4.26. While it can be used with the latest version of Unreal Engine 5, please note that Unreal Engine 5 is still in the early stage of development. New engine features, like Lumen, may not be fully supported.
As a result, I cannot provide support for engine-related bugs or address all differences between UE4 and UE5. Please refer to the’ Known Issues’ chapter to ensure you are aware of the most common issues that may arise. - Why is the price so high? Can you offer any promotions or discounts?
- Creating a Fluid Flux required over three years of research and development. Typically, a system of this nature would cost the company at least $350 000. The current price makes it a significant time and cost-saving solution for everyone.
- The price of the Fluid Flux pack includes a subscription for all future updates and my support. This kind of system requires a lot of support, especially with ongoing engine updates. Since I have other products on my marketplace profile, my time is currently limited. I have already quit my regular job to focus entirely on developing and improving products.
- The asset combines several significant features designed to work together, making your development process more accessible seamlessly. You no longer need to purchase multiple separate products and spend time integrating them. It includes a ripple solver simulation, shallow water fluid simulation, water surface rendering, ocean wave generator, buoyancy support, waterline effects, post-processing capabilities, coastline rendering, and even support for Niagara particles. I have handled all these aspects, so you don’t have to worry about them.
- Please check my marketplace profile to confirm that I am a trustworthy creator with hundreds of positive reviews. The price of my products is always determined based on the work and time required to develop them. Eventually, you will realize that time is a genuine currency with significant value.
- There will be a promotional sale, but first, I must feel ready to support more customers. If you are not in a rush, add my product to the wishlist and wait patiently. If you want to be notified a few days earlier about a promotional sale, join my Discord server.
- I’m not forcing anyone to buy my product. There are alternatives like Niagara Fluids and Water Plugin. You can try them for free and compare the results with my demo. Maybe you don’t even need the Fluid Flux. Choose wisely.
- Can I use it in my open-world game?
The true open-world setup has not been tested. The demo examples show how the system can be used. I can’t promise anything more at this point of development. Just assume that you get what you see in my videos, no more, no less. - Does it support multiplayer/replication?
Unfortunately, multiplayer is not supported. The Fluid Flux can be used in multiplayer games only as a visual addition and should not affect gameplay. There are many reasons:- Technical limitations. Fluid Flux uses Niagara readback to sample water data (the only way to read from GPU). Niagara is not working on the server.
- Bandwidth limitations. Too much data changes dynamically, so simulation can’t be synchronized over the internet. Everything would break quickly without correcting the differences between a server and a client.
- Human limitations. I am not a multiplayer programmer, so jumping into it and finding reasonable workarounds is challenging.
- External packs integrations ALS/UDS/Fluid Ninja
I plan to work on some integrations in the future. If you have a specific pack in mind, let me know. - Can I use it with Voxel Plugin?
Yes, you can use Fluid Flux with Voxel Plugin, but it is also limited to heightfield projection, so caves and planets are unsupported.
Use Simulation.RuntimeCaptureDelay = 1.0 to force simulation to wait for the voxel plugin map to generate mesh before rendering it to the height map.
The heightmap in this presentation is updated every frame using CaptureGroundHeightmap. It is inefficient and should probably be optimized only to update the area around the brush when something changes on the map. The UpdateGroundMap(Position, Size) function would be a better choice. - What about VR and mobile?
I currently do not support VR devices and mobiles.
Dynamic fluid simulations with high precision can’t be calculated on mobile, so only baked meshes/states can be used on this platform. I am planning to add VR and mobile support in future updates. The pack will receive a cheap surface material mode similar to the solution presented in Aquatic Surface. One user notified me that my demo maps are working without issues on Oculus Quest 2, but I have not tested it yet, so I can’t confirm it. - How to add swimming to ALS? Can you show me?
This task heavily depends on the character implementation, so I can’t provide an implementation for ALS. The Fluid Flux BP_FluxDataComponent delivers all the data you need to implement swimming. I’ve also prepared an example swimming implementation (BP_FluxSwimmingComponent) for the default engine mannequin so you can check it and learn. - Should I switch to Fluid Flux? Is it better than WaterPlugin/Oceanology or Aquatic Surface?
It depends on your specific requirements. The Fluid Flux excels at creating dynamic river simulations on heightfields and interactive scenes but doesn’t scale very well. If you only need a background ocean without detailed simulations, you might not want to go through the trouble of using simulations. However, Fluid Flux 2.0 introduces a new coastline domain system that can handle landscapes of up to 10km x 10km and provides an infinite ocean. I recommend playing the Fluid Flux demo to understand better whether it aligns with what you’re looking for.
- Why blueprints? Is Fluid Flux slow because of that?
This system is fully implemented in blueprints but relies mainly on GPU (shaders/render targets). Yes, it might be faster in C++, but it would also stretch the development time. The cost of blueprint code will be reduced using Niagara in the future, making it work even better. - Is Fluid Flux calculated deterministically?
If you simulate on the same machine, it is deterministic (constant delta time is used). Still, there are probably differences between floating-point operations on different GPUs, so it can’t be fully deterministic. In the case of multiplayer games, the biggest problem is the synchronization of state when someone joins the game and when the player loses some frames because of spikes and the simulation can’t work it off – I’ve decided to limit the number of accumulated iterations per frame in this case. - Do I need this pack? You probably don’t need the Fluid Flux if you can’t see why. I’ve prepared a simple comparison of the Fluid Flux and my other product, Aquatic Surface, that visualizes the difference:
That does not mean Aquatic Surface is bad. It’s a great product with a completely different feature list. You have to choose a product that fits your requirements. - Is it efficient?
It depends on the GPU, resolution, etc. You can download the demo and try it yourself:
GPU Resolution River map Island map RTX 3080 2560×1440 320-380 FPS 260-310 FPS RTX 2080 2560×1440 160-200 FPS 110-160 FPS GTX 860M in 8 years old notebook Lenovo Y50 1920×1080 25-30 FPS 20-25 FPS - What about the future of this project?
Numerous updates are planned, but I don’t have a specific timeframe. It’s essential to base your purchasing decisions on the product demonstrated in the demo rather than relying solely on my promises. You can keep track of the current progress of improvements on Trello. - Are you going to switch C++ and make it a Plugin?
A new C++ version called Fluid Flux Plugin is currently being developed.
Documentation
Getting started
This section covers the fundamentals of Fluid Flux and its tools. If you are new to Unreal Engine, you should become familiar with the Unreal Editor interface, Blueprint visual scripting, and the types of content. Working according to the documentation can provide the best possible experience with this product.
Project configuration
The effective use of the Fluid Flux pack requires activating specific built-in engine plugins and project settings. Working with code provided as an external project is more challenging because every project may use a particular configuration and a different version or engine feature set.
Below, you can find a list of plugins required by Fluid Flux:
- Editor Scripting Utilities
- Niagara
- Procedural mesh Component
The first place to visit in the demo folder is Demo/Maps. This folder contains all example maps working perfectly with the TPP example character (BP_DemoCharacter).
In the final stage of configuring the project, make sure that project settings are properly configurated:
- DBuffer = Enabled. It’s required for proper decal (wetness and caustics) rendering. If you don’t want to use those effects, you can disable decal material in the surface actor.
- CustomDepth-Stencil Pass = Enabled. This feature is required for proper underwater masking.
- Velocity Pass = Write During Base Pass. This feature improves the motion vector rendering.
- Default Renderer Motion Vector = Precise. This feature improves the motion vector rendering.
- Strta/Substrate = Disabled. This feature is still experimental and not supported by Fluid Flux.
- Real-time rendering is active in your viewport, and it is required to simulate fluid in the editor.
Demo character input
The demo maps use example controllers and characters. You can notice the demo is useful for testing features in the bottom right corner of the screen. If you use an example character in your project and want to remove this hud, there are many ways to do it: It can be disabled. Choose one:
- Add ToggleVisible in “begin play” FluidFluxPlayerController like this:
- Remove the “Create BP_HudWidged” node in the player controller
- Switch the game mode (controller) in your level from the demo to your game controller.
The section below is the deprecated input configuration, which will be removed soon. It applies only to Unreal Engine versions 4.26 – 5.2. The Fluid Flux for UE 5.3 and higher uses Enhanced Input, which implements character input inside the project.
As a marketplace creator, I cannot incorporate TPP input config into the asset pack, so developers need to implement them in their projects. I recommend using the template example project for your initial trials with Fluid Flux. The easiest way to run the demo is described below:
- Download the FluidFlux_Template and unpack it.
- Open and run the FluidFlux.uproject file (it will automatically register the FluidFlux project in the launcher projects list). The template project is prepared for 4.26 but can be converted to any higher version, including UE5.
- Download the Fluid Flux asset pack to the template project using the marketplace launcher.
Project structure
The Fluid Flux project is organized in a certain way. This short description will bring you closer to what kind of content can be found in each folder.
- Demo – The demo is the most important folder for new users. The demo examples present how to use this pack, achieve effects, and integrate systems with characters. Everything that can’t be found in this documentation will be shown in demo files.
- Editor – editor-related tools, icons, utilities, procedural mesh generator
- Simulation – Shallow water simulation actor and tools for controlling fluids and generating state.
- Coastline – Generating coastline data for oceans.
- Interaction – A simple system of interactions that adds detailed lightweight ripple fluid simulations.
- Surface – Renders surface, underwater volume, post-process, caustics, and playing audio.
- Environment – Niagara particle systems that allow readback pieces of information from simulation implementing swimming, buoyancy, and drive particles using fluid state.
- Waves is a system designed for generating ocean waves that can be used in the background and mixed with fluid simulation.
- Before starting work with the pack, it’s worth familiarizing yourself with its structure and the systems it provides.
Updating process
The latest version of the product is detailed on the Unreal marketplace page and at the beginning of the documentation. Frequent updates for Fluid Flux are planned, so always ensure that the Fluid Flux package version is up to date. However, be mindful of potential issues when updating.
Before updating the Fluid Flux in your project, please read the Package Update Process carefully. Following the update procedure ensures a smooth transition and minimizes the risk of potential issues arising during the update process.
Reporting Bugs
This Support and Reporting Bugs guide provides essential guidance on reporting system errors. Learn how to identify, report, and analyze bugs to ensure smooth support.
Ground capture
Ground capture is a fundamental aspect of Fluid Flux systems, as the fluid requires a designated vessel. Water blockers are recognized using a top-down projection by rendering the scene into a height map. A height map, also called a ground map, is a specialized texture that stores the height information of the geometry in pixels.
In the Fluid Flux pack, this task is handled by FluxHeightmapComponent, which is used in both the simulation and coastline domains. The generated height data play a pivotal role in determining the appearance and movement of water on slopes.
Visibility options
The ground scene capture component renders the current scene into a heightmap texture. Sometimes, we must exclude certain actors, such as bridges, that should not act as fluid blockers. In the ‘Domain:Heightmap: CaptureVisibility‘ tab, you can find options that may help determine which meshes should be visible in the heightmap:
VisibilityMode can be used to determine whether the capture actor should render the entire scene and exclude specified actors (HideAllListed) or build a list of actors that should be used as blockers (ShowOnlyListed).”
- ActorsReferences – exclude chosen actor objects on your scene
- Actos of Class – can be used for excluding by type of actor class and its child classes
- ActorsWithTag = “FluxHide“: Every actor that uses this tag will be added to the list of excluded objects.
- Use the M_PhantomMesh material to render the mesh ONLY during processing the ground capture (which is invisible to the world). This technique is good for imitating soft slopes of waterfalls or creating an alternative version of the ground when the environment is more complicated (like indoor meshes).
Solving issues
If something is not rendering properly in the height map, you can investigate what is happening without simulating the fluid. The debug preview option is the most crucial feature for domain actors. It shows a height map that will block the water on the scene in case of problems, bugs, or unexpected behavior.
There are many ways to configure the debug preview:
Domain DebugAttribute | Description |
DebugHiddenInGame |
Debugging will only be visible in the editor. You can turn it off to see how the ground map is generated in runtime (sometimes, there may be a difference, for example, when the map is loading for a long time and the ground map captures the LOD details). |
DebugPreview |
Enable/Disable debug mesh. |
DebugSelectedOnly |
Allows to preview the debug only when the domain is selected. |
It’s noticeable that not every detail will be captured on the ground map, and the accuracy depends on the grid scale (attribute AreaWorldPixelSize). The shader for rendering this preview colors lines based on slope and exposes the ground’s discontinuity.
Visualization | Description |
Green lines |
Easy to simulate, very stable fluid. |
Blue lines |
It has a good slope for moving fluid in some direction. |
Red lines |
The area may cause instability if fluid flows on it, but it is suitable for walls. |
White lines |
There may be some caves that can expose holes in the fluid mesh. |
Fully red polygons |
represent holes and discontinuity in the mesh. It should be eliminated if fluid can flow into this area. |
Landscape or mesh is not rendering to the ground map
If the “PixelDepthOffset” feature is used in the material, it may not be rendered to a ground map and cause some simulation problems. This problem can be easily fixed in your material by simple modification. Use the MF_FluxPixelDepthOffset material node to disable “PixelDepthOffset” while rendering the ground map.
The M_Photoscan_Master material is an example of a workaround for this problem using the MF_FluxPixelDepthOffset node.
Wrong Domain Z location:
Remember that after adding the Domain actor to your map, you must modify the domain actor’s height (Z position) depending on your landscape. The debug grid on top of the landscape geometry indicates everything works fine.
Groundmap works in the editor, but it is broken in the build or runtime.
There is a slight difference between testing in PIE and running the Shipping/Development build. Understanding this issue is crucial for finding a solution. The editor uses assets that are already loaded and can render them immediately. However, when you run the executable, the system has to stream landscape and meshes. When the Fluid Flux system captures the ground map and the scene has not yet been streamed, it may lead to inaccuracies, such as a flat ground map or the use of lower LOD. There are several potential solutions:
- Increasing the SimulationDomain.RuntimeCaptureDelay – delay is the simplest way to determine if this is the issue in your case. If, after increasing the value, the ground is captured correctly, it indicates that the ground was not ready when captured initially. However, this is not the optimal solution because you cannot predict how fast the game will load on various target devices. Low-end PCs and consoles may load more slowly, potentially resulting in unpredictable behavior.
- OnLevelLoaded events – The most effective approach is to use SimulationDomain.RuntimeCaptureDelay = -1 and execute the function SimulationDomain.BeginPlaySimulation by hand from an event that notifies you when the level is loaded and ready for use. Unfortunately, there are no such events in the blueprint, so you will need to track this on your own in C++.”
- Setting SimulationDomain.UseInitialStateGround=true forces the system to utilize the ground map from the data stored in the exported SimulationDomain.InitialState
Surface actor
The BP_FluxSurface is an abstract actor responsible for generalizing an audiovisual representation of the simulation and coastline domain data.
An abstract actor is like a guide for creating new actors. It defines some common features that all related classes should have, but it’s not complete on its own. Other classes need to finish the details. For example, an abstract class may not specify any ambient water audio, but a customized ocean template has sounds that match the type of water it represents.
The surface actor implements a list of advanced subsystems:
Actor component | Features |
DecalCausticsWet |
|
SurfaceOverMesh |
|
Post-Process |
|
SurfaceUnderMesh |
|
SurfaceProceduralMesh |
|
FluxAudioComponent |
|
Volume Absorption, Volume Scattering |
|
The BP_FluxSurface is an abstract base parent class, meaning it can’t be placed directly on a level. Configuring all these subsystems can be time-consuming, particularly for new users. This is why the package includes basic configured surface child actors templates that can be found in the FluidFlux/Surface/Templates folder.
Template | Description |
BP_FluxSurface_Water |
Default water surface spawned dynamically when the domain.SurfaceActorReference is not specified. |
BP_FluxSurface_River |
Simple river/waterfall material and basic underwater post-process, reiver audio |
BP_FluxSurface_Ocean |
Advanced ocean materials, ocean audio, materials blended with wave actor, underwater mesh, underwater scattering, and absorption volume. |
BP_FluxSurface_Coastline |
Rendering two domains simulation and coastline at the same time. |
Users can also implement their surface templates and extend the surface’s functionalities.
Interaction system
The BP_FluxInteractionCapture is designed to add efficient, detailed interaction simulated in small areas around the camera (or specified object).
- It is a perfect addition that can improve the look of baked simulation almost for free.
- It currently supports the most straightforward fast ripple solver, but there are plans to simulate a fluid pressure solver in the future.
The interaction system configuration is demonstrated in many example blueprints included in the Fluid Flux demo: BP_DemoCharacter, BP_FluxBoat, and BP_FluxCrate.
A detailed explanation of the implementation presented in BP_DemoCharacter can be found below:
- Component.BP_FluxDataComponent – This component reads the fluid data needed during further interaction calculations, such as height and velocity. You can find more information about this component and configuration in the section Async readback.
- Component.BP_FluxInteractionComponent –This component stores a list of interaction sources. The interaction source is a sphere attached to the component (or skeletal mesh bone) that generates waves after interacting with fluid.
- Interaction sources will be attached to mesh (skeletal or static) with the tag specified in the OwnerComponentTag attribute. Hence, adding this tag (FluxInteractionOwner) to the skeletal mesh that will move the interaction sources is essential.
- The BPI_FluxInteraction interface handles communication between the actor and the interaction capture system. It should be added to the Class Settings of the actor that will interact.
- Implement the GetInteractions in BPI_FluxInteraction. When BP_FluxInteractionCapture is an overlapping interactive actor, it calls this GetInteractions function to find information about occurring interactions.
- The BP_FluxInteractionCapture actor is placed on every map. The actor detects the interactable actors and manages the whole process of generating the interaction effect. The InteractionCapture actor uses the overlap to find actors inside the interaction actor area. This mechanism ensures that only the area’s actors are considered potential interaction sources. For example, a character uses the Capsule component for overlap; custom actors require adding a collision component like SphereCollision.
There are many steps to do before interaction start working but no worries you can debug and make sure that every part of your implementation works correctly:
1. Test it on demo maps at first
2. Enable DrawDebug in BP_FluxInteractionCapture
3. Enable DebugDraw in BP_FluxDataComponent
4. Enable DebugDraw in BP_FluxInteractionComponent
5. Make sure that “GetInteractions” is evaluated. Put a breakpoint in this function to check. If its not then your actor is not detected by overlap with InteractionCapture and you may have to add collision volume to your actor.
Interactions with a fluid surface may generate splashes, which add realism and immersion to the simulation. This is achieved through a straightforward mechanism that detects when the interaction source intersects the fluid surface. If this condition is met, a splash effect is created to simulate the disturbance caused by the interaction.
The InteractionComponent->Source->SplashType defines the splash index, which is stored in the Surface->InteractionSplashes array.
Color presets
The color preset system is a powerful tool for effortlessly configuring the visual aspects of water. It offers a range of predefined presets, eliminating the need to create new material instances to modify scattering and absorption.
Before starting to change the color of the water, make sure the surface is configured correctly. The SurfaceActorReferenceattribute in the Domain actor you use (SimulationDomain or CoastlineDomain) should reference your surface actor. Otherwise, the domain will spawn a temporary water surface that can’t be configured by hand.
Changing surface color:
- Select the surface actor on your map.
- Find MeshRendering Tab and attributes: BaseColorPreset
- You can use any preset from my list of predefined colors or create a duplicate and modify it.
Creating new custom color preset data asset:
There are 24 preconfigured color presets available for oceans, shallow water, and rivers. Additionally, users can create their water presets by duplicating existing examples and adjusting the parameters as desired, allowing for seamless customization and experimentation.
- In the content browser, open folder /FluidFlux/Content/FluidFlux/Surface/Templates/Color/
- Find a data asset preset that is closest to the effect that you want to achieve.
- Duplicate chosen data asset
- Set the data asset to the surface rendered on your map (attribute BaseColorPreset)
- Open data assets and edit parameters:
- Use the ApplyToSurfaceMaterials button at the top of the window where you are editing the color preset to preview the changes you have made.
World painter and brush
The FluxWorldBrush is a unique actor designed to manipulate data stored in the WorldPainterComponent canvas. The system offers three distinct types of canvas on which the FluxWorldBrush can perform painting operations:
- ColorPainter ( BP_FluxWorldPainter), interpolation between the base color and painter color.
- WaveSize (BP_FluxCoastlineDomain), interpolation between no wave and highest wave.
- WaveType (BP_FluxWorldDomain), interpolation between Oceanic wave and coastline wave
This two-minute tutorial presents the workflow and possibilities of brushes:
Reading fluid data
The Fluid Flux uses Niagara asynchronous readback events to read data from fluid render targets and pass them to blueprints. The BP_FluxDataComponent listener can receive, update, and store fluid data at a specific location.
The Fluid Flux uses this feature in multiple situations:
- buoyancy and floating objects
- automatic dam breaking
- interaction detection
- swimming system
- fluid sound source analyzer
- underwater camera detection
Add BP_FluxDataComponent to your actor, and it will automatically detect the fluid surface under the actor. BP_FluxRotatorActor is an excellent example of an actor that can react to fluid.
The Readback data component can be attached to the scene component in the owner actor by adding the tag “FluxReadbackOwner.”
Use Debug option in FluxDataComponent to make sure that component is following your actor and sampling proper values.
Character swimming
In general, swimming is not a prominent feature of this product; it is more of an additional example that presents one of many ways to do it. The swimming example is shown in DemoCharacter and requires a few things to work:
- Swimming requires PhysicsVolume on the map with PhysicsVolume.WaterVolume=true to activate swimming when the character is inside.
- Character.BP_FluxDataComponent – it provides data from water.
- Character.BP_FluxSwimmingComponent implements movement for you and controls CharacterMovement, which is required.
- Open and click the right mouse button on BP_FluxSwimming -> “find references,” and you will see how it is controlled using input.
- The swimming animation depends on the character animation blueprint implementation and will vary in every project, so there are many ways to implement it. My simple example switches animation when SwimmingState is detected in SwimmingComponent.
Niagara integration
The Niagara integration is based on three elements:
- BP_FluxNiagaraActor communicates with the simulation and data to the Niagara system.
- NE_FluxData emitter should be inherited by the Niagara system to read the data.
- NMS_FluxData is a special module that extracts simulation data from Stage Transients variables that can be used to drive the particles.
All particle systems (trash, plants, splashes) in the pack are constructed similarly; feel free to check and modify the examples.
Translucency
Rendering underwater translucents is, in general, a challenging problem to solve. Single-layer water materials do not support translucency, so translucents are invisible when watching surfaces from above water.
In general, I recommend using dithering instead of translucency.
The underwater volume post-process implementation is more functional because it can be overlayed with translucent meshes. It means translucent mesh is rendered on top of postprocess volume, but developers must handle the fading.
Final effect:
Cut mask and holes
In general system supports two methods of cutting holes in the water surface.
The first method is a bit tricky and designed for small boats. Look at the example boat mesh (Demo/Environment/Boat/SM_Boat) that uses additional cap mesh with M_FluxSurfaceInvisible material. The M_FluxSurfaceInvisible renders translucent material using the Single Layer Water mode that overrides the water surface and makes it invisible.
The second method for cutting holes requires the BP_SurfaceCutMask actor, which defines the rectangular area that will be removed. Unfortunately, only one cut mask per surface actor is supported right now.
- Drag and drop the BP_SurfaceCutMask actor into an area where water should be cuted out.
- Select the BP_FluxSurface actor on your level and set the newly created actor to the CutMaskActor attribute.
Simulation Domain
The Fluid Flux simulation implementation is based on shallow water equations. The shallow water equations are a set of mathematical equations that describe water flow in shallow areas, such as rivers and streams. They are commonly used in hydrodynamic modeling to simulate the movement of water and predict its behavior under various conditions. The resulting simulation will show the movement of the water and the formation of ripples and waves on the surface. You can adjust the initial conditions and parameters of the simulation to see how it affects the movement of the water and the formation of ripples. Remember that the shallow water equations are a simplified water flow model, and they may not always accurately reflect the behavior of actual water.
The BP_FluxSimulationDomain blueprint is the heart of the Fluid Flux system. This blueprint is responsible for handling important tasks like:
- Generating the ground height map to the texture (using FluxHeightmapComponent)
- Updating simulation of shallow water fluid, foam, and wetness.
- Baking and exporting simulation state.
- Sending data to the fluid surface renderer.
The Shallow Water simulation is based on the idea of assuming linear vertical pressure profiles, so it is simulated in two dimensions. In general, the algorithm can be described in a few steps:
- Simulation data is stored on 2D render targets.
Ground map – information about landscape and obstacles
Velocity (RG) Depth(B) Foam(A) map – stores information about fluid
Height(R) Wetness(G) map – stores surface height and wetness of the surface - The slope of the ground heightfield and the slope of fluid are combined and used to calculate the pressure and velocity.
- Simulation is an interactive process of updating fluid height and velocity.
- The result of integration is used for foam and velocity advection.
- Fluid modifiers are used as input for simulation to change the current state.
- The simulation frame accumulates fluid wetness and generates the fluid surface mesh displacement.
The BP_FluxSimulationDomain actor placed on the map is doing nothing because it’s empty and needs to be filled with fluid. The simplest way to fill containers with fluid is by using a Modifier source actor.
The BP_FluxSimulationDomain blueprint has a straightforward editor that simulates the fluid’s state on the map in the editor mode. Simulation can be prepared in the editor baked to state or dynamically updated by the simulation blueprint.
Modifier Component
A modifier component is a powerful tool that affects the simulation state and changes the current simulation state. It’s the simplest way to interact with the simulation. Modifiers can be used for:
- Adding/removing fluid in the simulation domain.
- Changing the velocity and flow direction of the fluid
- Simulating custom interaction with fluid
- Generating waves
The tutorial below presents how to add a source modifier on the scene and fill the simulation domain with fluid:
The Fluid Flux contains predefined modifiers:
- BP_FluxModifierComponent – Base parent class for all fluid modifiers. Every modifier component extends it and implements specific behavior. Users can create custom modifier classes and materials for specific use cases like whirlpools/waves. Describing the architecture is outside of the scope of documentation. The BP_FluxModifierSourceComponent component is an excellent example of a modifier that can be used as a starting point for learning how the system is designed.
- BP_FluxModifierSourceComponent – Simple modifier that allows adding/removing fluid and changing velocity in a specific area.
Parameters Volume The quantity of fluid applied by modifier (depending on Mode). Velocity The velocity of fluid applied by the modifier (depending on Mode). Shape The shape of the fluid modifier Mode Defines how the modifier is applied to the simulation. All modifiers are rendered to a simulation buffer. Mode is a method of blending used during this process.
Add – This mode will add the ‘volume’ of fluid and its velocity to the current fluid on the map.
Adjust – adjusting the current state of fluid to the height of the modifier.
Set – will set the constant height of fluid in the area.Edge The softness/hardness of the modifier edge. Useful for soft mixing with fluid or uniform filling the vessel. Intensity Scale the modifier’s effect on the domain (0.0, 1.0>. Duration Defines how long the fluid source will be active. (less than 0 means infinite), (0 Rendered in a single frame and then modifier will be disabled), (more than 0 is the duration in seconds) SortPriority Affecting an order of modifiers in the queue. It may be helpful when the user needs to fill the domain and then remove some fluid. A value larger than 1000 forces the system to add on the end without sorting. AutoActivate The modifier can be inactive initially and activated by an event from gameplay or a sequencer. There are many ways to remove fluid in the simulation domain. It depends on the mode you choose:
Mode= Set, Volume=0 – will set 0 water in the area of the modifier
Mode= Adjust, Actor.Z position – lock fluid at a specific height
Mode= Add, Volume negative – slowly removes fluid - BP_FluxModifierGerstnerComponent – Generates waves/fluid on borders of the simulation domain. More info and use cases can be found in the chapters related to ocean configuration.
- BP_FluxModifierForceComponent – Generates forces when the actor moves (based on the velocity). It can be added to the character.
Modifier Container
The modifier container is a particular type of actor that can store multiple modifiers and send them to the simulation. If the actor implements the BPI_FluxModifierContainer interface, it’s considered a modifier container.
BPI_FluxModifierContainer interface can be implemented by any actor. A good example is BP_DemoCharacter that uses BP_FluxModifierForceComponent to interact with a fluid. AddModiffiers function only needs to be implemented to make it work.
BP_FluxModifierContainerActor is a primary container that can combine multiple modifier components in a single actor that works simultaneously.
BP_FluxModifierSourceActor is a specific type of container actor that simplifies the process of adding simple source modifiers to the scene.
Every modifier is rendered in an additional render target pass, so it’s not cheap. Minimizing the number of fluid modifiers inside the simulation is good practice to achieve the highest performance.
Solving issues
Unexpected spikes sometimes destroy the simulation. Shallow water simulation can exhibit unpredictable behavior due to the loss of stability when encountering steep slopes. This is a widely recognized problem that can be resolved by fine-tuning specific parameters and enhancing the reliability of the simulation.
- Slope Scale (Increase)
Increasing this parameter will scale the scene’s height on the Z-axis and make your fluid move slower on slopes. (This parameter will probably be redesigned in the future version for better consistency with the world scale measurements). - OvershootineBlend(increase), OvershootingEdge(Decrease) Fixes overshooting problem bysmootcheening
- Simulation Delta Time (Decrease)
Fluid flux is updating with constant delay time. That means the time that elapsed between two game frames is divided by delta time, and the result is the number of iterations. In general, more iterations mean less performance. By default, the Simulation Delta Time attribute is set to 0.2. It is not safe regarding accuracy but can work with the highest performance. - Debug Preview / Debug Hidden In-Game (Debug)
Pay attention to the ground debug preview. If you spot some red spikes where the simulation does not work correctly, your ground texture and geometry should probably be adjusted. - Try to tweak other variables like Slope Clamp, Velocity Clamp, Friction, Damping, Gravity, and even World Pixel Scale can make a difference.
I am still experimenting with different solutions for this spikes problem and trying to figure out some method to force stability even in bad conditions. You can expect multiple improvements in future updates.
Fluid state
The PDA_FluxSimulationState is a unique data asset created especially for storing the current frame of the simulation. The simulation state is the most essential structure in the system.
The simulation actor dynamically updates simulation states. A dynamic simulation state is automatically created in the constructor script and stored in BP_FluxSimulationDomain.CurrentState actor. Data can be easily previewed and used for rendering and further fluid analysis.
The simulation state can be exported to the data asset and used later in many ways.
- It can be loaded in runtime
- It can be used as a starting point for the simulation
- It can send data to render by surface actor
- It can be used in other gameplay tools in Niagara emitters and materials
Exporting State
BP_FluxSimulationDomain.CurrentState can be baked to an asset by clicking the right button on BP_FluxSimulationDomain and choosing Scripted Actions -> Flux Export Simulation. The short tutorial below presents the process of generating and exporting the fluid state to a data asset:
- (0:07) Prepare data assets that will store the state
- (0:20) Start the simulation of fluid on your map and stop when it’s ready
- (0:50) Choose SimulationDomain->ContextMenu->ScriptedActions->FluxExportSimulation
- (0.54) Select the newly created state as a target and adjust settings.
Parameter
Description
ExportHeightMax ExportVelocityMax ExportHeightMax and ExportVelocityMax can improve quality. When the velocity or height in the exported simulation is very small, it is worth scaling the precision to use the whole range of bytes when storing the data. The exporter should do this automatically when opening the script. However, analyzing the whole simulation may require many computations and additional implementation, so I decided to leave it for manual adjustments.
UseCompression Exporting compressed assets. It can save some memory but also affects the quality of the surface. Level Of Detail Scales down the simulation resolution Apply State to Surface Applies exported data to the surface, which allows previewing the results.
After those actions, you should see the generated state and additional textures.
Pay attention to simulation resolution! The “Power of Two” rule is a fundamental necessity due to the way game engines work. You will not be able to export simulation state if it is size is not power of two (128/256/512/1024 etc.)
Use case 1: Initial state
Using the state as the initial state of simulation allows to start the simulation from a specific frame. It means that a simulation of flowing water does not have to be generated every time the game starts it can start from the saved frame.
- Select SimulationDomain
- Find InisialState attribute
- Set the state exported before
Since now, the simulation has started by reading data from the state.
Use case 2: Loading state in gameplay
Sometimes, there is a need to load state during the gameplay in blueprints like a checkpoint. Simulation->LoadInitialState function can be used to handle these tasks. Example use presented in the screenshot below:
Use case 3: Using state without simulation
If you are not planning to update the simulation dynamically, then a better option is to remove or disable the SimulationDomain actor and use SimulationState directly in the FluxSurface. This solution may be way faster and more reliable and save some memory. Use this configuration:
- Configure SimulationDomain and run the simulation.
- Click the right mouse button on SimulationDomian and export it to the state data asset.
- Set SimulationDomain->AffectWorld = false
- Set Surface->SimulationState directly using the exported asset.
BP_FluxSimulationDomain.SurfaceActorReference is set, actors communicate together, and the state is automatically passed to BP_FluxSurface.SimulationState, but changing the AffectWorld=false disables this connection.
SimulationDomain can be removed or set IsEditorOnlyActor to avoid spawning it in the final build and wasting memory.
Dynamic ground
The Fluid Flux uses a static ground map for simulating fluids on it, but updating is also allowed occasionally. It is very expensive operation, so it should not be executed in every frame.
The BP_BreakableDam presented in the video can be destroyed when the player hits the trigger. It is an excellent example of updating the ground after the dynamic object. Look at the Break function, which is the heart of the dam system.
It evaluates UpdatGroundMap on a simulation actor, which takes the object’s position and size that will disappear to recreate the ground in this area. You can do the same operation when adding something on your level.
Mesh generator
In the tutorial below, we will go through a valuable workflow for generating static meshes based on a baked state of the simulation. With this method you can achieve the highest performance, unfortunately, the waterline effect will not correlate very well with static mesh geometry.
- Setting up LOD and padding
- Converting a generated mesh to a static mesh asset
- Preparing material for static meshes
- Using static mesh in Surface actor
Mesh generation tools can be found in the BP_FluxSurface – Procedural Mesh tab.
Switch GenerateProceduralMeshView = true to see a preview of the generated mesh. After choosing this option, the surface automatically generates static mesh based on the Procedural Mesh tab configuration.
The last step is selecting SurfaceProceduralMesh Component and clicking “Create StaticMesh,” which will export the mesh to the static mesh asset.
If SurfaceProceduralMesh is not visible on the list of BP_FluidSurface components then you have to deselect the surface and select it again. It’s working like that because the engine does not refresh the list of components after switching on/off generation mode.
Now, you can find your static mesh in the content browser and preview it.
The river was simulated on the map and then converted to static mesh.
If you create a static mesh and try to save it, you might get an error saying it can’t be saved. This happens because the static mesh is using a material instance created dynamically in the blueprint. To fix it, just clear the material slot in the static mesh asset and then save the mesh.
The material configuration “MI_River_SurfaceOverStatic” is designed for static meshes and can handle fluid data such as foam and velocity encoded in vertex color. By setting “MI_River_SurfaceOverStatic.UseSimulation = false“, the system will read the data from the vertex color instead of sampling render targets. This flag allows you to use the static mesh data as a source of water information.
BP_FluxSurface can render static meshes using SurfaceMeshMode=StaticMesh, which means the mesh will not be transformed by simulation state scale, and geometry will be taken from SurfaceOverMesh component configuration.
Recreating Ocean
Creating an ocean scene is an advanced topic involving coordinating multiple actors simultaneously. It is good to try all other tutorials before starting to work on recreating the ocean scene. Examples of ocean setup are presented in the demo maps FluxIslandMap and FluxBeachMap you can copy this setup (SurfaceActor, SimulationDomain, WaveTexture, WaveModifier) or create it from scratch on your map using the description from this chapter:
Configuration step by step:
- Start with an empty map with some island/landscape/ground meshed.
- Add actors:
- Add BP_FluxSimulationDomain actor. Responsible for simulating water.
- Add BP_FluxSurface_Ocean actor. Responsible for rendering.
- Add BP_FluxOceanWave actor. Responsible for ocean waves outside the simulation.
- Add BP_FluxModifierWaveActor actor. Responsible for generating waves in simulation.
- Select BP_FluxSurface_Ocean actor
- Set Surface->SurfaceMeshMode = InfiniteGrid_128_Niagara. It will force rendering infinite mesh (a feature added in version 2.0).
- Set Surface->OceanWaveActor = FluxOceanWave. This action will facilitate the reading of data from the ocean wave actor.
- Select BP_FluxOceanWave – the dedicated actor that provides ocean waves. Implementation is much simpler than the classical analytical approaches like Gertner or FFT. The system uses animated 3D texture (VT_OceanWave) generated in a blender.
- Adjust the Z position of the ocean wave actor.
- Adjust wavelength and wave height to your needs.
- Select BP_FluxModifierWaveActor actor
- Adjust the transform of ModifierWave to cover the edges of the simulation that should generate waves. Change position and size if needed.
- Select BP_FluxSimulationDomain actor
- Switch the simulation domain surface to force rendering a new surface
Simulation->SuraceActorReference = BP_FluxSurface_Ocean - Change the blending of the simulation with the waves outside the simulation using the Simulation->Domain->AreaWorldBlend=(0.1, 0.1, 0.1, 0.1). You can adjust it to your needs. Custom blending between oceanic waves outside the simulation may be necessary in special cases, such as when dealing with a one-sided ocean. This can be achieved by configuring the AreaWorldBlend attribute within the SimulationDomain actor.
- Adjust the Z position of the simulation actor.
- Adjust the XY location, resolution, WorldPixelSize, and size to cover the area where the shallow water simulation should be generated.
- Ensure the ground map is captured correctly by checking if the debug grid represents your scene. (For more info, check the ground capture-related chapters)
- Switch the simulation domain surface to force rendering a new surface
- Test the simulation. Click SimulationDomain->StartSimulation or run the game.
Sequencer
Sequencer allows users to create in-game cinematics through its specialized multi-track editor. Unreal Engine has many options that can be used for previewing scenes, but Fluid Flux does not support some of them:
- Real-time – You can preview the simulation by hitting “play” (green button) in the editor. It will show you how it would behave in real time.
- Editor – Clicking “Start Simulation” in BP_FluxSimulation actor on the scene (as presented in tutorials) allows you to generate some specific frame and sawing int to state (an initial state that can be pinned to the simulation actor as the first frame).
- Sequencer editor – Simulation can’t be previewed in the sequencer because the Fluid Flux system does not allow rewinding simulation in the current version, and the sequencer affects actors – the topic is very complicated.
- Capture Movie – Sequencer Render Movie to Video. It works the same as in real-time mode, and Fluid Flux water will render correctly in the final video.
- Capture 360 – This option was never tested.
If you want to preview the simulation with a sequencer, then this setup may be helpful for you:
- Drag and drop the sequencer on your map.
- Switch the AutoPlay option in LevelSequenceActor.
- Press “Play in selected viewport” or “Simulate.”
Fluid Flux provides an option to use modifier activation/deactivation functions from a sequencer. The process of using this functionality is simple:
- Add Sequencer on the level and set parameter: Autoplay=True
- Add Source modifier on the level and set parameters Duration=-1, AutoActivate=false
- Drag and drop the Source modifier to the sequencer.
- Add Track->FluxModifierSource
- Choose the moment of activation on the timeline and click “Add a new key,” then change the properties of the event as presented on the screen below. You can choose the Activate/Deactivate function.
Now, you can test the scene by rendering a video or playing the game. The modifier should activate automatically by sequencer event.
Coastline Domain
The BP_FluxCoastlineDomain is a dedicated system designed specifically for capturing and baking world data into CoastlineState. The architecture of the BP_FluxCoastlineDomain system is similar to the BP_FluxSimulationDomain, ensuring consistency and familiarity.
The coastline state serves as a fundamental data source during the rendering process for coastlines and oceans. The BP_FluxCoastlineDomain can communicate with the FluxSurface actor and feed it with data needed to render the water as presented in the short video tutorial below:
Coastline state
The BP_FluxCoastlineDomain actor generates a state that can be exported and saved as the data asset and stored in the project files. The CoastlineState data asset can be used as an initial state in the BP_FluxCoastlineDomain actor or loaded directly in the BP_FluxSurfaceActor, the same way as in the case of the SimulationState.
Exporting the current coastline state can be described in a few simple steps:
- Create an empty coastline data asset for storing the data.
ContentBrowswer->RightMouseButton->Miscellaneus->DataAsset->PDA_FluxCoastlineState - Save to newly created data assets.
Select CoastlineDomain->RightMouseButton->ScriptedAction>FluxExportCoastline
Exported CoastlineState data asset stores two textures.
- WorldGroundMap stores the height map of the coastline area.
- WorldCoastlineMap stores the distance to the coastline, direction, wave height, and blending of the coastline.
If you are not planning to update the coastline dynamically, then maybe a better option would be removing (or disabling) the CoastlineDomain actor and using CoastlineState directly in the Surface actor. It may be way faster, more reliable, and save some memory.
Try this configuration:
- Configure CoastlineDomain and export it to the state.
- Set CoastlineDomain->AffectWorld = false
- Set CoastlineDomain->IsEditorOnlyActor = true
- Set Surface->CoastlinerState directly using the exported asset.
You don’t have to remove the domain actor from the scene because IsEditorOnlyActor will remove it automatically for you in final build. Thanks to this solution you are able to use it later again in the editor for regenerating the state if the level geometry change.
Solving Issues
If, after following the tutorial steps, the coastline does not appear, you have likely encountered one of the scenarios listed below:
- Z location of the Coastline actor is wrong:
Remember that after adding the BP_FluxCoastlineDomain actor on your map, you need to modify the domain actor’s height (Z position) depending on your landscape. Otherwise, you may not be able to see coastline waves.
The debug grid on top of the landscape geometry indicates everything works fine.
- Landscape material uses Pixel Depth Offset:
If the “PixelDepthOffset” feature is used in the material, it may not be rendered to a ground map and cause some simulation problems. This problem can be easily fixed in your material by simple modification.
Use the MF_FluxPixelDepthOffset material node to disable “PixelDepthOffset” while caching the ground map.
The M_Photoscan_Master material is an example of a workaround for this problem using the MF_FluxPixelDepthOffset node.
- The coastline is incorrect in standalone/shipping or looks different after play
This issue is associated with the landscape not being ready during the map loading process, and the system utilizes a lower Level of Detail (LOD) for rendering the ground. Detailed explanations can be found in “Groundmap solving issues: Groundmap is broken in shipping/development build.” Two potential solutions are available:
– Use the RuntimeCaptureDelay attribute to postpone rendering the height map,
– Save the coastline to the state and directly load it from the data asset.
(More tutorials soon, thank you for your patience)