Search Unity

[Bug v1.1.5] Null Reference Exception in GenerateLocationListsTask.cs line 114

Discussion in 'Addressables' started by MaskedMouse, Jul 19, 2019.

  1. MaskedMouse

    MaskedMouse

    Joined:
    Jul 8, 2014
    Posts:
    1,092
    I've discovered a bug when Built In Data is set as "Default", the
    GenerateLocationListsTask
    is throwing a null reference exception when building the addressables. This is because
    var bagSchema = group.GetSchema<BundledAssetGroupSchema>();
    on line 113 is null.

    When the default is set to another asset group other than Built In Data then it doesn't throw the null reference.
    It makes sense because the Built In Data doesn't have a BundledAssetGroupSchema.
     
    Last edited: Jul 20, 2019
  2. unity_bill

    unity_bill

    Joined:
    Apr 11, 2017
    Posts:
    1,053
    Thanks for the post, this has come up elsewhere. We've got the easy fix in to make sure we don't de-reference null. the more complex fix of controlling which groups can be "default" is a bit more complex. We're working on that one.
     
    MaskedMouse likes this.