News › Forums › RAIN › General Discussion and Troubleshooting › Problems with the Timer node.
Tagged: Behavior Tree, Timer Node
This topic contains 7 replies, has 2 voices, and was last updated by prime 2 years, 2 months ago.
-
AuthorPosts
-
November 1, 2022 at 3:28 pm #4930
Heya, it seems I have a problem with the timer behavior node. I made an Q&A post, but I think this might be a better place to ask.
|
I thought I was getting somewhere when i got it to work on my spawn node:
(Image: Blue line)-SELECTOR Root --CONSTRAINT Spawn (!haveSpawned) ---move (Looped to success) ---PARALLEL PositionReached ----timer ----MECANIM PARAMETER(s) ---EXPRESSION ClearMoveTarget
|
But when I tried to use almost the same setup further into my behaviors, it did not work. It seems that it for some reason gets stuck on the Timer node. The only difference is that it is within some more nodes.
(Image: Red Line)-PARALLEL Main --CONSTRAINT TargetNotDead ---SELECTOR States ----CONSTRAINT NotPaused -----<Same as the setup above, but with other constraint>
|
Since it works when I run it in spawn I can not really see why it shouldn’t run there.
|
|
|
On an unrelated note; how do I make spaces between lines? O,oNovember 2, 2022 at 11:23 pm #4980I’m going to guess that you aren’t getting stuck on the timer node, but instead are either getting stuck on the move node or are failing out of the parallel/constraint for other reasons.
-
This reply was modified 2 years, 3 months ago by
prime.
November 4, 2022 at 7:14 am #5004Hm, it seem to me that the only node running when it gets stuck is the timer node (see picture below). But of course it might be something else, but I can’t seem to locate it. The constraint should not fail unless the whole node collection is finished.
|
-
This reply was modified 2 years, 3 months ago by
Pax.
November 4, 2022 at 2:49 pm #5014Is this a project you can share with us so we can take a look?
November 4, 2022 at 5:43 pm #5019I’m afraid I can’t share that specific project, but I reproduced the locking in another project. This project uses more or less the same BT that the main project uses, except for some custom actions.
|
Timer Test Project
|-
This reply was modified 2 years, 3 months ago by
Pax.
-
This reply was modified 2 years, 3 months ago by
Pax.
-
This reply was modified 2 years, 3 months ago by
Pax.
-
This reply was modified 2 years, 3 months ago by
Pax.
-
This reply was modified 2 years, 3 months ago by
Pax.
-
This reply was modified 2 years, 3 months ago by
Pax.
November 11, 2022 at 8:47 am #5187Was just wondering if you have had the time to take a look at the timer problem?
November 11, 2022 at 6:41 pm #5199November 11, 2022 at 7:16 pm #5208The problem is not the timer node. It shows yellow (RUNNING) because that’s the state it was last in. However, your entire behavior tree is resetting every frame, because the other nodes in your Main parallel are failing constantly and your Main parallel is set to fail if any child fails.
You will need to solve that issue, then the timed part of your tree will start working for you.
-
This reply was modified 2 years, 3 months ago by
-
AuthorPosts
You must be logged in to reply to this topic.