Cast To Blueprint Actor Fails (Actor in world)

Hello,
I have a Blueprint Actor placed in the level and I have an AI roamer who performs a linetrace to detect any actor with a larger, “easy to see” collision box in his vision and print string the object’s name. I have a Cast To node to specify the actor, but the cast always fails. I used a “IsValid” node and a Print String node to see if it is valid, and my results so far have always been valid.

Can someone let me know why the Cast always fails, or what I am doing wrong? Let me know if you need more detail or screenshots.

Thank you

I’d suggest taking a look at the behavior tree quick start if you want to get AI behavior working. It may be more exhaustive than what you are looking for, but you will definitely learn how to use the line trace correctly.

https://docs.unrealengine.com/latest/INT/Engine/AI/BehaviorTrees/QuickStart/

The only reason this would fail is if that Actor you are Casting to, is not the one that the line trace is actually hitting. I just tested your setup myself and everything works as intended.

My setup:

Thank you very much for you help. I got it working. You were right it was cast failing because the trace was not hitting the door.

If my answer was correct, please upvote it and mark as answer to close this. Thank you.