AWaterBody

Choose your operating system:

Windows

macOS

Linux

Inheritance Hierarchy

References

Module

Water

Header

/Engine/Plugins/Experimental/Water/Source/Runtime/Public/WaterBodyActor.h

Include

#include "WaterBodyActor.h"

Syntax

UCLASS(Blueprintable, Abstract,
       HideCategories=(Tags, Activation, Cooking, Replication, Input, Actor, AssetUserData))
class AWaterBody :
    public AActor,
    public IWaterBrushActorInterface

Variables

Name Description

Protected variable UProperty Transient

UBillboardCompo...

 

ActorIcon

Protected variable UProperty Category, Meta BlueprintReadOnly visibleanywhere

UWaterSplineCom...

 

SplineComp

The spline data attached to this water type.

Protected variable UProperty Category, Meta BlueprintReadOnly visibleanywhere

UWaterBodyCompo...

 

WaterBodyComponent

Protected variable UProperty Category, Meta BlueprintReadOnly Transient duplicatetransient, nontransactional

int32

 

WaterBodyIndex

Unique Id for accessing (wave, ... ) data in GPU buffers

Protected variable UProperty Category, EditDefaultsOnly, Meta

EWaterBodyType

 

WaterBodyType

Protected variable UProperty instanced

UWaterSplineMet...

 

WaterSplineMetadata

Protected variable UProperty Category, EditAnywhere BlueprintReadOnly displayname, instanced

UWaterWavesBase...

 

WaterWaves

#todo_water: This should be moved to the component when component subobjects are supported

Constructors

Name Description

Public function

AWaterBody

(
    const FObjectInitializer& ObjectIn...
)

Functions

Name Description

Protected function Virtual

void

 

DeprecateData()

Public function Virtual Const UFunction BlueprintCallable, Category, Meta

float

 

GetAudioIntensityAtSplineInputKey

(
    float InKey
)

Public function Const UFunction BlueprintCallable, Category, Meta

TArray< AWat...

 

GetExclusionVolumes()

Public function Const UFunction BlueprintCallable, Category, Meta

TArray< AWat...

 

GetIslands()

Public function Virtual UFunction BlueprintCallable, Category, Meta

UMaterialIns...

 

GetRiverToLakeTransitionMaterialInstance()

Public function Virtual UFunction BlueprintCallable, Category, Meta

UMaterialIns...

 

GetRiverToOceanTransitionMaterialInstance()

Public function Const UFunction BlueprintCallable, Category

UWaterBodyCo...

 

GetWaterBodyComponent()

Returns the water body component

Public function Virtual Const UFunction BlueprintCallable, Category

EWaterBodyTy...

 

GetWaterBodyType()

Returns the type of body

Public function UFunction BlueprintCallable, Category, Meta

UMaterialIns...

 

GetWaterMaterialInstance()

Public function Const UFunction BlueprintCallable, Category

UWaterSpline...

 

GetWaterSpline()

Returns water spline component

Public function

UWaterSpline...

 

GetWaterSplineMetadata()

Public function Const

const UWater...

 

GetWaterSplineMetadata()

Public function Virtual Const UFunction BlueprintCallable, Category, Meta

float

 

GetWaterVelocityAtSplineInputKey

(
    float InKey
)

Public function Virtual Const UFunction BlueprintCallable, Category, Meta

FVector

 

GetWaterVelocityVectorAtSplineInputKey

(
    float InKey
)

Public function Const

UWaterWavesB...

 

GetWaterWaves()

Protected function Virtual

void

 

InitializeBody()

Initializes the water body by creating the respective component for this water body type.

Protected function Virtual Const

bool

 

IsIconVisible()

Returns whether icon billboard is visible.

Public function UFunction BlueprintCallable, Category, Meta

void

 

OnWaterBodyChanged

(
    bool bShapeOrPositionChanged,
    bool bWeightmapSettingsChanged
)

Public function UFunction BlueprintCallable, Category, Meta

void

 

SetWaterMaterial

(
    UMaterialInterface* InMaterial
)

Public function UFunction BlueprintCallable, Category

void

 

SetWaterWaves

(
    UWaterWavesBase* InWaterWaves
)

Protected function

void

 

SetWaterWavesInternal

(
    UWaterWavesBase* InWaterWaves
)

Public function

void

 

UpdateActorIcon()

#todo_water: all icon stuff can be moved to the component

Overridden from AActor

Name Description

Public function Virtual

void

 

NotifyActorBeginOverlap

(
    AActor* OtherActor
)

Actor Interface

Public function Virtual

void

 

NotifyActorEndOverlap

(
    AActor* OtherActor
)

Event when an actor no longer overlaps another actor, and they have separated.

Protected function Virtual

void

 

PostEditMove

(
    bool bFinished
)

Called after an actor has been moved in the editor

Public function Virtual

void

 

PostRegisterAllComponents()

Called after all the components in the Components array are registered, called both in editor and during gameplay

Public function Virtual

void

 

PreInitializeComponents()

Called right before components are initialized, only called during gameplay

Public function Virtual

void

 

PreRegisterAllComponents()

Called before all the components in the Components array are registered, called both in editor and during gameplay

Public function Virtual

void

 

SetActorHiddenInGame

(
    bool bNewHidden
)

Sets the actor to be hidden in the game

Public function Virtual

bool

 

SetIsHiddenEdLayer

(
    bool bIsHiddenEdLayer
)

Changes bHiddenEdLayer flag and returns true if flag changed.

Public function Virtual

void

 

SetIsTemporarilyHiddenInEditor

(
    bool bIsHidden
)

Explicitly sets whether or not this actor is hidden in the editor for the duration of the current editor session

Public function Virtual

void

 

UnregisterAllComponents

(
    bool bForReregister
)

Unregister all currently registered components

Overridden from UObject

Name Description

Protected function Virtual

void

 

PostDuplicate

(
    bool bDuplicateForPIE
)

Called after duplication & serialization and before PostLoad.

Protected function Virtual

void

 

PostEditChangeProperty

(
    FPropertyChangedEvent& PropertyCha...
)

Called when a property on this object has been modified externally

Public function Virtual

void

 

PostInitProperties()

Called after the C++ constructor and after the properties have been initialized, including those loaded from config.

Public function Virtual

void

 

PostLoad()

Do any object-specific cleanup required immediately after loading an object.

Protected function Virtual

void

 

PreEditChange

(
    FProperty* PropertyAboutToChan...
)

This is called when a property is about to be modified externally

Public function Virtual

void

 

Serialize

(
    FArchive& Ar
)

Handles reading, writing, and reference collecting using FArchive.

Overridden from IWaterBrushActorInterface

Name Description

Public function Virtual Const

bool

 

AffectsLandscape()

Returns true if this water actor is currently setup to modify the landscape :

Public function Virtual Const

bool

 

AffectsWaterMesh()

Returns true if this water actor is currently affecting (i.e. being rendered by) a AWaterZoneActor :

Public function Virtual Const

bool

 

CanAffectWaterMesh()

Returns true if this water actor could potentially be affecting (i.e. being rendered by) a AWaterZoneActor :

Public function Virtual Const

TArray< UPri...

 

GetBrushRenderableComponents()

Returns an ordered list of components to render in the actor brush render pass (e.g. USplineMeshComponents for rivers)

Public function Virtual Const

void

 

GetBrushRenderDependencies

(
    TSet< UObject* >& OutDependen...
)

Returns the list of objects this actor depends on to render its brush (textures, materials...)

Public function Virtual Const

ETextureRend...

 

GetBrushRenderTargetFormat()

Returns the format of the render target used to render this actor in the water brush

Public function Virtual Const

const TMap< ...

 

GetLayerWeightmapSettings()

Returns the landscape weightmap settings, per layer, for this water actor

Public function Virtual Const

const FWater...

 

GetWaterCurveSettings()

Returns the curve settings for this water actor

Public function Virtual Const

const FWater...

 

GetWaterHeightmapSettings()

Returns the landscape heightmap settings for this water actor

Deprecated Variables

Name Description

Protected variable UProperty

bool

 

bAffectsLandscape_DEPRECATED

Protected variable UProperty

bool

 

bCanAffectNavigation_DEPRECATED

Protected variable UProperty

bool

 

bFillCollisionUnderWaterBodiesForNavmesh_DEPRECATED

Protected variable UProperty

bool

 

bGenerateCollisions_DEPRECATED

Protected variable UProperty

bool

 

bOverrideWaterMesh_DEPRECATED

Protected variable UProperty

FName

 

CollisionProfileName_DEPRECATED

Protected variable UProperty

FWaterCurveSett...

 

CurveSettings_DEPRECATED

Protected variable UProperty

TArray< TLazyOb...

 

ExclusionVolumes_DEPRECATED

Protected variable UProperty

TArray< TLazyOb...

 

Islands_DEPRECATED

Protected variable UProperty

TMap< FName, FW...

 

LayerWeightmapSettings_DEPRECATED

Protected variable UProperty

float

 

MaxWaveHeightOffset_DEPRECATED

Protected variable UProperty

int32

 

OverlapMaterialPriority_DEPRECATED

Protected variable UProperty

UPhysicalMateri...

 

PhysicalMaterial_DEPRECATED

Protected variable UProperty

float

 

ShapeDilation_DEPRECATED

Protected variable UProperty

float

 

TargetWaveMaskDepth_DEPRECATED

Protected variable UProperty

FLandmassTerrai...

 

TerrainCarvingSettings_DEPRECATED

Protected variable UProperty

UMaterialInterf...

 

UnderwaterPostProcessMaterial_DEPRECATED

Protected variable UProperty

UMaterialInstan...

 

UnderwaterPostProcessMID_DEPRECATED

Protected variable UProperty

FUnderwaterPost...

 

UnderwaterPostProcessSettings_DEPRECATED

Protected variable UProperty

FWaterBodyHeigh...

 

WaterHeightmapSettings_DEPRECATED

Protected variable UProperty

UMaterialInterf...

 

WaterMaterial_DEPRECATED

Protected variable UProperty

UStaticMesh ...

 

WaterMeshOverride_DEPRECATED

Protected variable UProperty

UMaterialInstan...

 

WaterMID_DEPRECATED

Protected variable UProperty

TSubclassOf< UN...

 

WaterNavAreaClass_DEPRECATED

Deprecated Functions

Name Description

Public function

void

 

AddExclusionVolume

(
    AWaterBodyExclusionVolume* InE...
)

Moved to WaterBodyComponent

Protected function Virtual

void

 

BeginUpdateWaterBody()

Moved to WaterBodyComponent

Protected function Virtual Const

bool

 

CanAffectNavigation()

Moved to WaterBodyComponent

Public function Const

bool

 

ContainsExclusionVolume

Moved to WaterBodyComponent

Public function Const

bool

 

ContainsIsland

(
    TLazyObjectPtr< AWaterBodyIsland > ...
)

Moved to WaterBodyComponent

Public function Const

float

 

FindInputKeyClosestToWorldLocation

(
    const FVector& WorldLocation
)

Moved to WaterBodyComponent

Public function Virtual Const

ALandscapePr...

 

FindLandscape()

Moved to WaterBodyComponent

Public function Const

float

 

GetChannelDepth()

Moved to WaterBodyComponent

Public function Virtual Const

TArray< UPri...

 

GetCollisionComponents()

Moved to WaterBodyComponent

Public function Virtual Const

FVector

 

GetCollisionExtents()

Moved to WaterBodyComponent

Protected function Virtual Const

float

 

GetConstantDepth()

Moved to WaterBodyComponent

Protected function Virtual Const

float

 

GetConstantSurfaceZ()

Moved to WaterBodyComponent

Public function Virtual Const

float

 

GetHeightOffset()

Moved to WaterBodyComponent

Public function Const

int32

 

GetOverlapMaterialPriority()

Moved to WaterBodyComponent

Public function Const

FPostProcess...

 

GetPostProcessProperties()

Moved to WaterBodyComponent

Protected function Virtual Const

float

 

GetSimpleWaveHeightAtPosition

(
    const FVector& InPosition,
    float InWaterDepth,
    float InTime
)

Moved to WaterBodyComponent

Protected function Virtual Const

void

 

GetSurfaceMinMaxZ

(
    float& OutMinZ,
    float& OutMaxZ
)

Moved to WaterBodyComponent

Public function Const

FVector

 

GetWaterNavCollisionOffset()

Moved to WaterBodyComponent

Protected function Virtual Const

float

 

GetWaveAttenuationFactor

(
    const FVector& InPosition,
    float InWaterDepth
)

Moved to WaterBodyComponent

Protected function Virtual Const

float

 

GetWaveHeightAtPosition

(
    const FVector& InPosition,
    float InWaterDepth,
    float InTime,
    FVector& OutNormal
)

Moved to WaterBodyComponent

Public function Const

bool

 

GetWaveInfoAtPosition

(
    const FVector& InPosition,
    float InWaterDepth,
    bool bInSimpleWaves,
    FWaveInfo& InOutWaveInfo
)

Moved to WaterBodyComponent

Public function Virtual Const

float

 

GetWaveReferenceTime()

Moved to WaterBodyComponent

Public function Virtual Const

bool

 

HasWaves()

Moved to WaterBodyComponent

Protected function Virtual Const

bool

 

IsBodyDynamic()

Moved to WaterBodyComponent

Protected function Virtual Const

bool

 

IsFlatSurface()

Moved to WaterBodyComponent

Protected function Virtual Const

bool

 

IsHeightOffsetSupported()

Moved to WaterBodyComponent

Protected function Virtual Const

bool

 

IsWaterSplineClosedLoop()

Moved to WaterBodyComponent

Public function Virtual Const

bool

 

IsWaveSupported()

Moved to WaterBodyComponent

Public function Const

bool

 

IsWorldLocationInExclusionVolume

(
    const FVector& InWorldLocation
)

Moved to WaterBodyComponent

Public function Virtual Const

FWaterBodyQu...

 

QueryWaterInfoClosestToWorldLocation

(
    const FVector& InWorldLocation,
    EWaterBodyQueryFlags InQueryFlags,
    const TOptional< float >& InSpline...
)

Moved to WaterBodyComponent

Public function

void

 

RemoveExclusionVolume

(
    AWaterBodyExclusionVolume* InE...
)

Moved to WaterBodyComponent

Public function Virtual

void

 

SetDynamicParametersOnMID

(
    UMaterialInstanceDynamic* InMI...
)

Moved to WaterBodyComponent

Public function Virtual

void

 

SetHeightOffset

(
    float InHeightOffset
)

Moved to WaterBodyComponent

Public function

void

 

SetUnderwaterPostProcessMaterial

(
    UMaterialInterface* InMaterial
)

Moved to WaterBodyComponent

Public function

void

 

SetWaterMeshOverride

(
    UStaticMesh* InMesh
)

Moved to WaterBodyComponent

Public function Const

bool

 

ShouldGenerateWaterMeshTile()

Moved to WaterBodyComponent

Public function Virtual

void

 

UpdateMaterialInstances()

Moved to WaterBodyComponent

Protected function Virtual

void

 

UpdateWaterBody

(
    bool bWithExclusionVolumes
)

Moved to WaterBodyComponent