When Player see Enemy inside camera

Thanks for the answer , I’m thinking also this idea and i think it will work 100%
but this idea will not work for other thing , for example :
If the wall between player and enemy , if i put your idea the sound will play cause the enemy will overlapping
What i need , i need hit actor only camera view this will be work not single line trace , but how to do this ?
I hope to get the answer.