Navigation
API > API/Runtime > API/Runtime/Constraints
References
| Module | Constraints |
| Header | /Engine/Source/Runtime/Experimental/Animation/Constraints/Public/ConstraintsManager.h |
| Include | #include "ConstraintsManager.h" |
Syntax
class FConstraintsManagerController
Functions
| Type | Name | Description | |
|---|---|---|---|
| bool | AddConstraint
(
UTickableConstraint* InConstraint |
Add this constraint to the manager | |
| UTickableConstraint * | AddConstraintFromCopy
(
UTickableConstraint* CopyOfConstraint |
Make a copy of this constraint and add it to the manager, returns the copy mode if it was added | |
| TConstraint * | AllocateConstraintT
(
const FName& InBaseName, |
Allocates a new constraint with the constraints manager as the owner. | |
| bool | DoesExistInAnyWorld
(
UTickableConstraint* InConstraint |
When PIEing/Simulating it's possible that the constraint isn't in the active manager but still lives | |
| void | Go through each constraint in order and evaluate and tick them | ||
| void | |||
| FConstraintsManagerController & | Get
(
UWorld* InWorld |
Get and Set Controller acive in this world | |
| TArray< TWeakObjectPtr< UTickableConstraint > > | GetAllConstraints
(
const bool bSorted |
Returns systems' constraints array (sorted if needed). | |
| UTickableConstraint * | GetConstraint
(
const int32 InConstraintIndex |
Returns the constraint based on it's index within the manager's constraints array. | |
| UTickableConstraint * | GetConstraint
(
const FGuid& InGuid |
Returns the constraint based on it's ID within the manager's constraints array. | |
| int32 | GetConstraintIndex
(
const FGuid& InGuid |
Get the index of the given constraint's ID. | |
| const TArray< TWeakObjectPtr< UTickableConstraint > > & | Get read-only access to the array of constraints. | ||
| TArray< TWeakObjectPtr< UTickableConstraint > > | GetConstraintsByPredicate
(
Predicate Pred, |
Returns a filtered constraints array checking if the predicate for each element is true. | |
| FConstraintsManagerNotifyDelegate & | Delegate to trigger changes in the constraints manager. | ||
| TArray< TWeakObjectPtr< UTickableConstraint > > | GetParentConstraints
(
const uint32 InTargetHash, |
Get parent constraints of the specified child. | |
| TArray< TWeakObjectPtr< UTickableConstraint > > | GetStaticConstraints
(
const bool bSorted |
Returns the static/non-animated constraints | |
| void | |||
| void | MarkConstraintForEvaluation
(
UTickableConstraint* InConstraint |
Evaluation graph API. | |
| void | Notify
(
EConstraintsManagerNotifyType InNotifyType, |
Notify from changes in the constraints manager. | |
| FOnSceneComponentConstrained & | Delegate that's fired when a scene component is constrained, this is needed to make sure things like gizmo's get updated after the constraint tick happens | ||
| bool | RemoveAllConstraints
(
bool bDoNotCompensate |
Remove All Constraints | |
| bool | RemoveConstraint
(
const int32 InConstraintIndex, |
Remove the constraint at the given index. | |
| bool | RemoveConstraint
(
UTickableConstraint* InConstraint, |
Remove constraint by ptr | |
| void | SetConstraintsDependencies
(
const FName& InNameToTickBefore, |
Set dependencies between two constraints. | |
| void | SetConstraintsDependencies
(
const FGuid& InGuidToTickBefore, |
||
| void | StaticConstraintCreated
(
UWorld* InWorld, |
If static contraint created, we call this, which stores it to the manager/actor |
Typedefs
| Name | Description |
|---|---|
| FOnSceneComponentConstrained | Delegeate that's fired when a scene component is constrained, this is needed to make sure things like gizmo's get updated after the constraint tick happens |
Constants
| Name | Description |
|---|---|
| bDoNotRemoveConstraint | Static to control if we should remove constraints or not, may not want to do some when compensating since we may be deleting spawnables while doing so |