Reply To: Is there a way to assign the agent at runtime?

Forums 💬 NodeCanvas 🗨️ General Discussion Is there a way to assign the agent at runtime? Reply To: Is there a way to assign the agent at runtime?

#14789
alic
Participant

    Hey, my bad for not mentioning the key point! I was up a little too late when I posted. Sorry to waste some of your time 🙁 I’m using Tick() on the tree owner and not using StartBehavior(). That’s the code from the documentation I was using (I’m using the behavior trees for a turn-based game, so tick makes sense.) I figured out I could get it to work by calling StartBehavior() and EndBehavior(), and get exactly the behaviour I want with the lines

    before I start ticking the tree owner. It doesn’t work with the code in the documentation as far as I can tell, though.