std::unordered_map vs TMap Performance?

The bigger issue IMO is that STL isn’t going to work with UE’s reflection system or the Garbage Collector.

So if you have something like:



stl::unordered_map<FString, AActor*> NameToActorMap;


You aren’t able to mark that field as a UPROPERTY and any references to the AActors contained within the map will never be tracked and may be deleted if no one else has a reference to that actor.

2 Likes