Gj, though i should say that as far as i can see you partially missed the point about how exactly a bullet trace works.
Code:
// this is a second traceline, for shooting through walls
Yes, but actually the second trace is created if bullet is hit any solid object including so called monsters. So basically you are blocking 2nd and next traces that potentially may damage a players if the 1st trace is hit a player.
Take a look:
Code:
bullet is fired, the bullet is hit a player #4
the bullet is hit a player #2
the bullet is hit a player #3
This is an awp's single bullet traces that doesn't hit a wall (ref:
[HOWTO] Detect fired particle creation/type/number/damage/obstacle/vector).