Recent content by szczepan

  1. S

    Possible performance improvement

    And one more idea- This one will be more complicated to implement, using behavior tree reference i s de of another behavior tree is currently very slow. One thing I was able to do is instead of passing parameters to that task (which involves a lot of slow type conversions) it's better to save...
  2. S

    Possible performance improvement

    I'm working on large tree with and I noticed that calling EnableBehavior when spawning new agents is allocating a lot of memory (~0.3MB) and is taking 30ms. It seems that it's caused by this method: TaskContainsMethod(string methodName, Task task) and the reflection used here: MethodInfo method...
  3. S

    [Bug][Unity 2021.1.3f1][BD 1.6.8] External behavior on prefab- variables reset in play mode

    I had something like that earlier, but I have a large number of components on my gameobject which were getting really hard to manage, so I ended up assembling gameobject from multiple prefabs - this way I can limit the number of prefab variants.
  4. S

    [Bug][Unity 2021.1.3f1][BD 1.6.8] External behavior on prefab- variables reset in play mode

    Thanks, I was able to narrow down the problem. Indeed when prefab is instantiated everything works fine. My mistake was that instead of actually instantiating a prefab I just created a blank component (gameObject.AddComponent<BehaviorTree>()) and copied all fields from referenced prefab. I'm...
  5. S

    [Bug][Unity 2021.1.3f1][BD 1.6.8] External behavior on prefab- variables reset in play mode

    On my prefab I have a Behavior Tree component referencing external behavior I can set behavior variables on the prefab and they get serialized correctly, but as soon as I enter play mode they are reverted to defaults from external behavior. When I exit play mode, they're correct again. Note this...
Top