I can see nothing wrong with your code, it's just that over a long distance, you have to aim very directly at the player to get the stuff to show. If you dont like that, write your own trace thingy, probably with a few vector operations in it.
Good luck.