How do I find a component by name?

you can make your own component, and give it the name variable you want,

wiki tutorial: Custom BP-friendly UObject Components

then you can find it by doing this

for(TObjectIterator<UYourCompClass> Itr; Itr; ++Itr)
{
   if(Itr->YourStringVariableName = "YourName")
  {
     //do stuff!
     return;

  }
}
1 Like