AI check if door is open

Hi,

I have a simple AI system.
Every time it spawns it has to go to the same location, so I’m not using a behavior tree (I can’t add it after can I?)

How do I send another MoveTo after the previous one has finished?

And how can I check if a door is open?
It’s a BP, that is placed in the map and uses an interface to check, but how do I get that actor?
Here’s the AI controller containing this:

Thanks.
Feel free to ask what I mean if I explained poorly.

I just want to quickly note that the AIMoveTo node (in pawns, not controllers) is asynchronous and has a “Completed” pin, which makes it useful for moving to different locations. You could just use a sphere trace to search for nearby doors and cast the output to your door class. NB: Casting to a blueprint instead of a C++ class can create a hard reference, which consumes excess RAM. Therefore, you should try and find a method without casting if possible.

I’ll try this.
Thanks.

I added the AIMoveTo to the character BP, but it never successfully executes. I set the pawn to self and the destination.
Any other method?

1 Like