News Forums RAIN General Discussion and Troubleshooting Animate in Behavior Tree

This topic contains 4 replies, has 2 voices, and was last updated by  RyanMitchellGames 5 months, 2 weeks ago.

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #35169

    RyanMitchellGames
    Participant

    I have no idea what could be wrong where.
    I place animate in the root node under a par and it animates. It works exactly as it should.
    I place it anywhere else and it does not animate?
    Even directly under a waypoint node and it will not animate.

    #35170

    RyanMitchellGames
    Participant

    Here is a very simple tree probably wrong in areas but I just want to see animation.

    <behaviortree version="1.1" repeatuntil="" name="Basic" debugbreak="False"><parallel tiebreaker="succeed" succeed="all" repeatuntil="running" name="root" fail="any" debugbreak="False"><detect sensor=""close"" repeatuntil="" name="close" entityobjectvariable="formVarClose" debugbreak="False" aspectvariable="aspCloseVar" aspectobjectvariable="mpCloseVar" aspect="hero" /><animate repeatuntil="running" name="animate" debugbreak="False" animationstate="walk" /><detect sensor=""eyes"" repeatuntil="" name="detect" entityobjectvariable="varHero" debugbreak="False" aspectvariable="aspectVar" aspectobjectvariable="mpVar" aspect=""hero"" /><selector usepriorities="False" repeatuntil="" name="selector" debugbreak="False"><constraint repeatuntil="" priority="" name="constraint" debugbreak="False" constraint="varHero != null"><selector usepriorities="False" repeatuntil="" name="selector" debugbreak="False"><constraint repeatuntil="" priority="" name="constraint" debugbreak="False" constraint="formVarClose == null"><parallel tiebreaker="fail" succeed="all" repeatuntil="" name="parallel" fail="all" debugbreak="False"><move turnspeed="" repeatuntil="" name="move" movetarget="varHero" movespeed="2.0" facetarget="" debugbreak="False" closeenoughdistance="" closeenoughangle="" /><animate repeatuntil="" name="animate" debugbreak="False" animationstate="walk" /></parallel></constraint><constraint repeatuntil="" priority="" name="constraint" debugbreak="False" constraint="formVarClose != null"><animate repeatuntil="" name="animate" debugbreak="False" animationstate="walk" /></constraint></selector></constraint><constraint repeatuntil="" priority="" name="constraint" debugbreak="False" constraint="varHero == null"><waypointpatrol waypointsetvariable="PatrolRoute" waypointactiontype="patrol" traversetype="pingpong" traverseorder="forward" repeatuntil="" pathtargetvariable="" name="waypointpatrol" movetargetvariable="" debugbreak="False"><move turnspeed="" repeatuntil="" name="move" movetarget="nextStop" movespeed="1.0" facetarget="" debugbreak="False" closeenoughdistance="" closeenoughangle="" /><animate repeatuntil="" name="animate" debugbreak="False" animationstate="walk" /></waypointpatrol></constraint></selector></parallel></behaviortree>
    #35171

    RyanMitchellGames
    Participant

    <?xml version=”1.0″ encoding=”UTF-8″?>
    <behaviortree version=”1.1″ repeatuntil=”” name=”Basic” debugbreak=”False”>
    <parallel tiebreaker=”succeed” succeed=”all” repeatuntil=”running” name=”root” fail=”any” debugbreak=”False”>
    <detect sensor=”"close"” repeatuntil=”” name=”close” entityobjectvariable=”formVarClose” debugbreak=”False” aspectvariable=”aspCloseVar” aspectobjectvariable=”mpCloseVar” aspect=”hero” />
    <animate repeatuntil=”running” name=”animate” debugbreak=”False” animationstate=”walk” />
    <detect sensor=”"eyes"” repeatuntil=”” name=”detect” entityobjectvariable=”varHero” debugbreak=”False” aspectvariable=”aspectVar” aspectobjectvariable=”mpVar” aspect=”"hero"” />
    <selector usepriorities=”False” repeatuntil=”” name=”selector” debugbreak=”False”>
    <constraint repeatuntil=”” priority=”” name=”constraint” debugbreak=”False” constraint=”varHero != null”>
    <selector usepriorities=”False” repeatuntil=”” name=”selector” debugbreak=”False”>
    <constraint repeatuntil=”” priority=”” name=”constraint” debugbreak=”False” constraint=”formVarClose == null”>
    <parallel tiebreaker=”fail” succeed=”all” repeatuntil=”” name=”parallel” fail=”all” debugbreak=”False”>
    <move turnspeed=”” repeatuntil=”” name=”move” movetarget=”varHero” movespeed=”2.0″ facetarget=”” debugbreak=”False” closeenoughdistance=”” closeenoughangle=”” />
    <animate repeatuntil=”” name=”animate” debugbreak=”False” animationstate=”walk” />
    </parallel>
    </constraint>
    <constraint repeatuntil=”” priority=”” name=”constraint” debugbreak=”False” constraint=”formVarClose != null”>
    <animate repeatuntil=”” name=”animate” debugbreak=”False” animationstate=”walk” />
    </constraint>
    </selector>
    </constraint>
    <constraint repeatuntil=”” priority=”” name=”constraint” debugbreak=”False” constraint=”varHero == null”>
    <waypointpatrol waypointsetvariable=”PatrolRoute” waypointactiontype=”patrol” traversetype=”pingpong” traverseorder=”forward” repeatuntil=”” pathtargetvariable=”” name=”waypointpatrol” movetargetvariable=”” debugbreak=”False”>
    <move turnspeed=”” repeatuntil=”” name=”move” movetarget=”nextStop” movespeed=”1.0″ facetarget=”” debugbreak=”False” closeenoughdistance=”” closeenoughangle=”” />
    <animate repeatuntil=”” name=”animate” debugbreak=”False” animationstate=”walk” />
    </waypointpatrol>
    </constraint>
    </selector>
    </parallel>
    </behaviortree>

    #35207

    prime
    Keymaster

    I’m not sure what you are testing with that tree. As an example, though, your top level animate node is repeating forever. Any of the animate nodes that hit underneath it will be fighting with it and won’t work properly.

    #35216

    RyanMitchellGames
    Participant

    Learning process =)… very messed up tree I have it all going well now thanks! Quite a nice design.

    And thanks again to you all for all the nav mesh help it worked out great! I now have generated levels with a unified nav mesh!

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.