Method is asking for FName of a Component, what should I put in?
I'm currently using the Cable Component for my project, and am trying to use the SetAttachEndTo method in my code.
The method requires two parameters: an AActor and an FName that is the name of the component to attach to.
I am stuck in that I am not sure what to put for the FName of the component I would like to attach to, I.E. the root component of my input Actor. Anyone have any experience with this type of parameter?
asked Jul 17 '15 at 03:21 AM in C++ Programming
Every component attached to an actor in the world will have an FName. To get the root component's FName, use the method GetDefaultSceneRootVariableName(). So your final code might look something like:
For more on FNames, and how they are different from normal strings, check out this documentation page: FName | Unreal Engine
Follow this question
Once you sign in you will be able to subscribe for any updates here