UBuoyancyComponent

Choose your operating system:

Windows

macOS

Linux

Inheritance Hierarchy

References

Module

Water

Header

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

Include

#include "BuoyancyComponent.h"

Syntax

UCLASS(Blueprintable, Config=Game, Meta=(BlueprintSpawnableComponent))
class UBuoyancyComponent : public UActorComponent

Variables

Name Description

Protected variable

int8: 1

 

bCanBeActive

Protected variable

int8: 1

 

bIsInWaterBody

Protected variable

int8: 1

 

bIsOverlappingWaterBody

Public variable UProperty Category, EditDefaultsOnly

FBuoyancyData

 

BuoyancyData

Public variable

uint8: 1

 

bUseAsyncPath

Protected variable

TMap< uint32, T...

 

ConfiguredPontoonCoefficients

Protected variable

FBuoyancyCompon...

 

CurAsyncInput

Protected variable

FBuoyancyCompon...

 

CurAsyncOutput

Protected variable

EAsyncBuoyancyC...

 

CurAsyncType

Protected variable UProperty Transient

TArray< UWaterB...

 

CurrentWaterBodyComponents

Protected variable

FBuoyancyCompon...

 

NextAsyncOutput

Public variable UProperty Category BlueprintAssignable

FOnPontoonEnter...

 

OnEnteredWaterDelegate

Public variable UProperty Category BlueprintAssignable

FOnPontoonExite...

 

OnExitedWaterDelegate

Protected variable

float

 

OutputInterpAlpha

Protected variable

TArray< FAsyncO...

 

OutputsWaitingOn

Protected variable

uint32

 

PontoonConfiguration

Protected variable UProperty

UPrimitiveCompo...

 

SimulatingComponent

Primitive component that will be used for physics simulation.

Protected variable

int32

 

VelocityPontoonIndex

Constructors

Name Description

Public function

UBuoyancyComponent

(
    const FObjectInitializer& ObjectIn...
)

Functions

Name Description

Public function

void

 

AddCustomPontoon

(
    float Radius,
    FName CenterSocketName
)

Public function

void

 

AddCustomPontoon

(
    float Radius,
    const FVector& RelativeLocation
)

Protected function Virtual

void

 

ApplyBuoyancy

(
    UPrimitiveComponent* Primitive...
)

Public function Virtual

void

 

ApplyForces

(
    float DeltaTime,
    FVector LinearVelocity,
    float ForwardSpeed,
    float ForwardSpeedKmh,
    UPrimitiveComponent* Primitive...
)

Public function Const

FVector

 

ComputeAngularDragTorque

(
    const FVector& AngularVelocity
)

Protected function

void

 

ComputeBuoyancy

(
    FSphericalPontoon& Pontoon,
    float ForwardSpeedKmh
)

Public function Const

FVector

 

ComputeLinearDragForce

(
    const FVector& PhyiscsVelocity
)

Protected function

void

 

ComputePontoonCoefficients()

Public function Const

FVector

 

ComputeWaterForce

(
    const float DeltaTime,
    const FVector LinearVelocity
)

Public function Virtual Const

TUniquePtr< ...

 

CreateAsyncAux()

Public function

void

 

EnteredWaterBody

(
    UWaterBodyComponent* WaterBody...
)

Public function

void

 

ExitedWaterBody

(
    UWaterBodyComponent* WaterBody...
)

Public function Virtual

void

 

FinalizeAuxData()

Public function

void

 

FinalizeSimCallbackData

(
    FBuoyancyManagerAsyncInput& Input
)

Public function Virtual

void

 

GameThread_ProcessIntermediateAsyncOutput

(
    const FBuoyancyComponentAsyncOutput...
)

Public function

void

 

GameThread_ProcessIntermediateAsyncOutput

(
    const FBuoyancyManagerAsyncOutput&...
)

Public function

TArray< UWat...

 

GetCurrentWaterBodyComponents()

Public function Const UFunction BlueprintCallable, Category

const TArray...

 

GetCurrentWaterBodyComponents()

Public function UFunction BlueprintCallable, Category

void

 

GetLastWaterSurfaceInfo

(
    FVector& OutWaterPlaneLocation,
    FVector& OutWaterPlaneNormal,
    FVector& OutWaterSurfacePosition,
    float& OutWaterDepth,
    int32& OutWaterBodyIdx,
    FVector& OutWaterVelocity
)

Public function

UPrimitiveCo...

 

GetSimulatingComponent()

Public function

float

 

GetWaterHeight

(
    FVector Position,
    const TMap< const UWaterBodyCompone...,
    float DefaultHeight,
    UWaterBodyComponent*& OutWater...,
    float& OutWaterDepth,
    FVector& OutWaterPlaneLocation,
    FVector& OutWaterPlaneNormal,
    FVector& OutWaterSurfacePosition,
    FVector& OutWaterVelocity,
    int32& OutWaterBodyIdx,
    bool bShouldIncludeWaves
)

Public function

float

 

GetWaterHeight

(
    FVector Position,
    const TMap< const UWaterBodyCompone...,
    float DefaultHeight,
    bool bShouldIncludeWaves
)

Public function Const

void

 

GetWaterSplineKey

(
    FVector Location,
    TMap< const UWaterBodyComponent...,
    TMap< const UWaterBodyComponent...
)

Public function Const

bool

 

HasPontoons()

Public function Virtual Const

bool

 

IsActive()

Public function Const UFunction BlueprintCallable, Category

bool

 

IsInWaterBody()

Public function Const UFunction BlueprintCallable, Category

bool

 

IsOverlappingWaterBody()

Public function Const

bool

 

IsUsingAsyncPath()

Public function UFunction BlueprintCallable, Category

void

 

OnPontoonEnteredWater

(
    const FSphericalPontoon& Pontoon
)

Public function UFunction BlueprintCallable, Category

void

 

OnPontoonExitedWater

(
    const FSphericalPontoon& Pontoon
)

Public function

void

 

SetCanBeActive

(
    bool bInCanBeActive
)

Public function Virtual

TUniquePtr< ...

 

SetCurrentAsyncInputOutput

(
    int32 InputIdx,
    FBuoyancyManagerAsyncOutput* C...,
    FBuoyancyManagerAsyncOutput* N...,
    float Alpha,
    int32 BuoyancyManagerTimestamp
)

Public function

void

 

SetCurrentAsyncInputOutputInternal

(
    FBuoyancyComponentAsyncInput* ...,
    int32 InputIdx,
    FBuoyancyManagerAsyncOutput* C...,
    FBuoyancyManagerAsyncOutput* N...,
    float Alpha,
    int32 BuoyancyManagerTimestamp
)

Public function Virtual

void

 

SetupWaterBodyOverlaps()

Public function Virtual

void

 

Update

(
    float DeltaTime
)

Public function

void

 

UpdatePontoonCoefficients()

Public function Virtual

int32

 

UpdatePontoons

(
    float DeltaTime,
    float ForwardSpeed,
    float ForwardSpeedKmh,
    UPrimitiveComponent* Primitive...
)

Overridden from UActorComponent

Name Description

Public function Virtual

void

 

BeginPlay()

Begins Play for the component.

Public function Virtual

void

 

EndPlay

(
    const EEndPlayReason::Type EndPlayR...
)

Ends gameplay for this component.

Public function Virtual

void

 

TickComponent

(
    float DeltaTime,
    enum ELevelTick TickType,
    FActorComponentTickFunction* T...
)

Function called every frame on this ActorComponent.

Overridden from UObject

Name Description

Public function Virtual

void

 

PostLoad()

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

Public function Virtual

void

 

Serialize

(
    FArchive& Ar
)

Handles reading, writing, and reference collecting using FArchive.

Classes

Name

Description

Protected struct

FAsyncOutputWrapper

Deprecated Variables

Name Description

Public variable UProperty Meta

TArray< FSpheri...

 

Pontoons_DEPRECATED