BehaviorTree.CPP icon indicating copy to clipboard operation
BehaviorTree.CPP copied to clipboard

Script invocation in t03_generic_ports should fail regarding the scripting language description

Open stepkun opened this issue 8 months ago • 0 comments

Regarding the XML definition in t03_generic_ports.cpp:

<root BTCPP_format="4" >
     <BehaviorTree ID="MainTree">
        <Sequence name="root">
            <CalculateGoal   goal="{GoalPosition}" />
            <PrintTarget     target="{GoalPosition}" />
            <Script          code="OtherGoal='-1;3'" />
            <PrintTarget     target="{OtherGoal}" />
        </Sequence>
     </BehaviorTree>
 </root>

I think that the Script invocation should fail due to the assignment to 'OtherGoal' with only '=' because the variable 'OtherGoal' does not yet exist and according to the scripting language description this requires a ':=' assignment.

stepkun avatar May 06 '25 10:05 stepkun