Announcement

Collapse
No announcement yet.

Timers not working in Behavior Tree?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Timers not working in Behavior Tree?

    Hi,

    I have a somewhat simple problem (I think), but not really sure what's going on. I want to be able to use a timer (Set Timer by Function OR Event), but for some reason in my behavior tree TASK the timer never gets triggered. Here's a SS of the blueprint as it's running. It just gets here and gets stuck but never plays the animation:

    Click image for larger version

Name:	what.jpg
Views:	1
Size:	204.8 KB
ID:	1182964

    I'm fairly new when it comes to AI in unreal so maybe you're just unable to use Timer's in AI? Anybody run into this before? Thanks so much!
    Last edited by derm; 05-28-2016, 01:10 AM.

    #2
    For delayed action you have decorators i think.

    Comment


      #3
      Setting time value to 0 or less will clear timer instead of running it immediately.
      Source
      SuperGrid: Marketplace Page | Feedback Thread | Demo | Website
      Level design and prototyping for newbies

      Comment


        #4
        Originally posted by zeOrb View Post
        Setting time value to 0 or less will clear timer instead of running it immediately.
        Source
        Thanks for the reply! Yeah I tried to set that value to something other than 0 and it still does the same thing. So I added a breakpoint on the play animation and it still never gets triggered. The below screenshot is after about 30 seconds of this blueprint being triggered:

        Click image for larger version

Name:	what_02.jpg
Views:	1
Size:	228.5 KB
ID:	1107254

        I wouldn't imagine this is a bug or anything right?
        Last edited by derm; 05-27-2016, 10:37 PM.

        Comment


          #5
          I think calling it again resets it to that time. Try a Do Once node and reset it from the even you're trying to get working.
          They broke the signatures so I removed mine thinking it'd be awhile. The signatures work again, but I haven't redone my signature yet.

          Comment


            #6
            Originally posted by KorkuVeren View Post
            I think calling it again resets it to that time. Try a Do Once node and reset it from the even you're trying to get working.
            This is correct. You need to call the Timer once or it gets reset. Worked alot on Timers myself so.
            Fighting Game Template: PROJECT: Unreal Fighter 2D

            Comment


              #7
              Originally posted by KorkuVeren View Post
              I think calling it again resets it to that time. Try a Do Once node and reset it from the even you're trying to get working.
              Ah success! That was exactly it. Thanks so much, that's really great to know. Yeah it was the fact that the blueprint kept getting fired by the behavior tree and must have kept just resetting the timer.

              Comment

              Working...
              X