C++ Find Specific Actor in Scene

You can use naming conventions to make your search much faster. Basically… search for the first few letters of what you’re looking for and organize it that way. So basically you can set the iterator like this…

It’ll narrow the search quite abit.

“ActorItr->GetName().Contains”

Here is an example of how to use it.

		FString A = "hey";

		if (A.Contains(FString("he")))
		{
			GEngine->AddOnScreenDebugMessage(-1, 10.0, FColor::Yellow, FString::FString("FOUND IT!!!!"));
		}

		else
		{
			GEngine->AddOnScreenDebugMessage(-1, 10.0, FColor::Yellow, FString::FString("NOPE!!!!!"));
		}