UCableComponent

Component that allows you to specify custom triangle mesh geometry

Windows
MacOS
Linux

Inheritance Hierarchy

References

Module

CableComponent

Header

/Engine/Plugins/Runtime/CableComponent/Source/CableComponent/Classes/CableComponent.h

Include

#include "CableComponent.h"

Syntax

[UCLASS](Programming/UnrealArchitecture/Reference/Classes#classdeclaration)(HideCategories=(Object, Physics, Activation, "Components|Activation"), EditInlineNew,
       Meta=(BlueprintSpawnableComponent), ClassGroup=Rendering)
class UCableComponent : public UMeshComponent

Remarks

Component that allows you to specify custom triangle mesh geometry

Variables

Name Description

Public variable UProperty Category, EditAnywhere

FComponentRefer...

 

AttachEndTo

Actor or Component that the defines the end position of the cable

Public variable UProperty Category, EditAnywhere

FName

 

AttachEndToSocketName

Socket name on the AttachEndTo component to attach to

Public variable UProperty Category, EditAnywhere BlueprintReadWrite

bool

 

bAttachEnd

Should we fix the end to something (using AttachEndTo and EndLocation), or leave it free.

Public variable UProperty Category, EditAnywhere BlueprintReadWrite

bool

 

bAttachStart

Should we fix the start to something, or leave it free.

Public variable UProperty Category, EditAnywhere, AdvancedDisplay BlueprintReadWrite

bool

 

bEnableCollision

EXPERIMENTAL.

Public variable UProperty Category, EditAnywhere, AdvancedDisplay BlueprintReadWrite

bool

 

bEnableStiffness

Add stiffness constraints to cable.

Public variable UProperty Category, EditAnywhere BlueprintReadWrite

FVector

 

CableForce

Force vector (world space) applied to all particles in cable.

Public variable UProperty Category, EditAnywhere BlueprintReadWrite

float

 

CableGravityScale

Scaling applied to world gravity affecting this cable.

Public variable UProperty Category, EditAnywhere, Meta BlueprintReadWrite

float

 

CableLength

Rest length of the cable

Public variable UProperty Category, EditAnywhere, Meta BlueprintReadWrite

float

 

CableWidth

How wide the cable geometry is

Public variable UProperty Category, EditAnywhere, AdvancedDisplay, Meta BlueprintReadWrite

float

 

CollisionFriction

If collision is enabled, control how much sliding friction is applied when cable is in contact.

Public variable UProperty Category, EditAnywhere, Meta BlueprintReadWrite

FVector

 

EndLocation

End location of cable, relative to AttachEndTo (or AttachEndToSocketName) if specified, otherwise relative to cable component.

Public variable UProperty Category, EditAnywhere, Meta BlueprintReadOnly

int32

 

NumSegments

How many segments the cable has

Public variable UProperty Category, EditAnywhere, Meta BlueprintReadOnly

int32

 

NumSides

Number of sides of the cable geometry

Public variable UProperty Category, EditAnywhere, Meta BlueprintReadWrite

int32

 

SolverIterations

The number of solver iterations controls how 'stiff' the cable is

Public variable UProperty Category, EditAnywhere, AdvancedDisplay, Meta BlueprintReadOnly

float

 

SubstepTime

Controls the simulation substep time for the cable

Public variable UProperty Category, EditAnywhere, Meta BlueprintReadWrite

float

 

TileMaterial

How many times to repeat the material along the length of the cable

Constructors

Name Description

Public function

UCableComponent

(
    const FObjectInitializer& ObjectIn...
)

Functions

Name Description

Public function Const UFunction BlueprintCallable, Category

AActor *

 

GetAttachedActor()

Gets the Actor that the cable is attached to

Public function Const UFunction BlueprintCallable, Category

USceneCompon...

 

GetAttachedComponent()

Gets the specific USceneComponent that the cable is attached to

Public function Const UFunction BlueprintCallable, Category

void

 

GetCableParticleLocations

(
    TArray< FVector >& Locations
)

Get array of locations of particles (in world space) making up the cable simulation.

Public function UFunction BlueprintCallable, Category

void

 

SetAttachEndTo

(
    AActor* Actor,
    FName ComponentProperty,
    FName SocketName
)

Attaches the end of the cable to a specific Component within an Actor

Public function UFunction BlueprintCallable, Category

void

 

SetAttachEndToComponent

(
    USceneComponent* Component,
    FName SocketName
)

Attaches the end of the cable to a specific Component

Overridden from UPrimitiveComponent

Name Description

Public function Virtual

FPrimitiveSc...

 

CreateSceneProxy()

Creates a proxy to represent the primitive to the scene manager in the rendering thread.

Public function Virtual Const

int32

 

GetNumMaterials()

Return number of material elements in this primitive

Overridden from USceneComponent

Name Description

Public function Virtual Const

FBoxSphereBo...

 

CalcBounds

(
    const FTransform& LocalToWorld
)

Calculate the bounds of the component. Default behavior is a bounding box/sphere of zero size.

Public function Virtual Const

bool

 

DoesSocketExist

(
    FName InSocketName
)

Return true if socket with the given name exists

Public function Virtual Const

FTransform

 

GetSocketTransform

(
    FName InSocketName,
    ERelativeTransformSpace TransformSp...
)

Get world-space socket transform.

Public function Virtual Const

bool

 

HasAnySockets()

Returns true if this component has any sockets

Public function Virtual Const

void

 

QuerySupportedSockets

Get a list of sockets this component contains

Overridden from UActorComponent

Name Description

Public function Virtual

void

 

ApplyWorldOffset

(
    const FVector& InOffset,
    bool bWorldShift
)

Called by owner actor on position shifting Component should update all relevant data structures to reflect new actor location

Public function Virtual

void

 

CreateRenderState_Concurrent

(
    FRegisterComponentContext* Con...
)

Used to create any rendering thread information for this component

Public function Virtual

void

 

OnRegister()

Called when a component is registered, after Scene is set, but before CreateRenderState_Concurrent or OnCreatePhysicsState are called.

Public function Virtual

void

 

SendRenderDynamicData_Concurrent()

Called to send dynamic data for this component to the rendering thread

Public function Virtual

void

 

TickComponent

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

Function called every frame on this ActorComponent.

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss