LineTrace sometimes returns (0,0,0)

Here are ingame screenshots:

Problem:


How it should go: