How do we know that GetPlayerViewPoint belongs to GetWorld?

At 4:55 in the video Mike says to use GetPlayerViewPoint we need to specify GetWorld and GetFirstPlayerController. How does he know that this is the case? As far as I can see there is no way that you can back track up the class hierarchy from the GetPlayerViewPoint documentation. Is he just using experience/prior knowledge here or is there a more explicit way of getting this information?

It’s a top down vs bottom up approach. You would start with either GetWorld which returns the current UWorld so you would have access to all actors etc. and go down or GetOwner which would return the AActor that owns the actor/component.

Privacy & Terms