I've seen a few posts here regarding how to test if an enemy is visible. The one I linked suggested using a mesh collider and if that hit the NPC that I could raycast. What I'm wondering is if there is a more refined method. It seems to me in this case if I don't pick the correct ray that the NPC would still remain hidden.
For example: An NPC is behind a hill and all that is visible, to my player, is his hat. The collider would say the NPC is in range but if I cast a ray from the center of my player's eye out chances are it's going to hit the hill.
The only way I can see to check real visibility is to cast a ray from the player's eye to ever vertex on the other mesh and break if I find any that aren't blocked but this would be very expensive.