Search Unity

  1. Unity Asset Manager is now available in public beta. Try it out now and join the conversation here in the forums.
    Dismiss Notice

Bug Action Precondition "list contains" throws error

Discussion in 'AI & Navigation Previews' started by Gnarf, Nov 27, 2020.

  1. Gnarf

    Gnarf

    Joined:
    Jul 29, 2015
    Posts:
    6
    To reproduce :

    - Create new project (Unity 2020.1.12f1).
    - Add AI Planner 0.2.4-preview.3.
    - Create semantic trait "IntList" with List->Integer property "List"
    - Create semantic trait "IntNumber" with Integer property "Number"
    - Create ai planner action "IsNumberInList" with IntList and IntNumber parameters
    - Create precondition with "contains" or "!contains" operator between IntList and IntNumber
    - Create ai planner problem "IntProblem" containing IsNumberInList
    - Run Semantic -> Traits -> Build generates


    Temp\PlannerAssembly\Generated.AI.Planner.Plans\IntProblem\IsNumberInList.cs(106,23):
    error CS1612: Cannot modify the return value of 'DynamicBuffer<IntList>.this[int]'
    because it is not a variable
    UnityEditor.EditorApplication:Internal_CallDelayFunctions()
     

    Attached Files:

    Last edited: Nov 27, 2020
  2. mplantady_unity

    mplantady_unity

    Unity Technologies

    Joined:
    Jun 19, 2019
    Posts:
    49
    Thanks for the bug report, I will look into that!