this was nullptr when trying to get coordinates

It seems I didn’t describe the error quite correctly, when I call the same function from the NPC class it works fine, but I need to register this function in Task and there is a problem with nullptr, it seems to me it can’t get LineTraceComp which is in my AI class