I have a suggestion...
Maybe change c_scan to not scans through walls all the time but only with some mode like ignore_blocks?
Because now is hard to make detection system with walls using cone...
trace is only line/box-line, trigger is full sphere... only scan using cones like "if I can see you" (it means f.e. 120 degrees horizontal and 50 vertical depends of my pan/tilt) but through the walls
what you think about it?