How to turn off anchor at runtime?

How do I turn off a chaos anchor field? If I add it to a geometry collection’s initialization fields array then it works but can’t be turned off. If I don’t, then it doesn’t work even tho it’s set as “active”.

I want to make sure that part of a geometry collection remains in place no matter what… for a while. Then, when the time comes, the anchored parts should become breakable like the rest.

Hi

Anchor fields are only meant to be used at initialization and they effectively set the underlying elements of the geometry collection as kinematic and they will stay like this until their state is changed
There’s a few way to change their state at runtime:

  • Use a field that change the state of the underlying elements
  • Use one of the following blueprint functions on the geometry collection component
    • RemoveAllAnchors
    • SetAnchoredByIndex
    • SetAnchoredByBox
    • SetAnchoredByTransformedBox

There’s also another way to anchor a geometry collection that does not require an anchor field
In the fracture editor hierarchy, select root ( or any other element of the geometry collection ) and right click on it and select the Anchored > Yes menu

This will set the piece anchored but it will be still destroyable

I hope this helps

1 Like