var trace_target[3];
vec_set(trace_target,player.x);
c_trace(player.x,trace_target,IGNORE_ME|IGNORE_PASSABLE|USE_BOX);
The problems are in these lines.
1. You can't use anything but vectors in c_trace. So, make your trace_target a vector.
2. vec_set : vector_set

So you should set vectors with it.
3. If you want to use EVENT_SCAN or other events, you should use c_scan to scan the area. c_trace only sends a beam.
I looked for these on Manual to be sure. Use trace_target as a VECTOR and use c_scan instead of c_trace. It should work with them...