How can i set so that my AI cannot see through my own Object Types?

I suppose i could do a line trace to check visibility, but i felt that it was kind of pointless to have the AI perception component handle sight if i had to do even more line traces for each sight to check something basic like visibility.