Search Unity

Bug Asset Bundle clearing List elements

Discussion in 'Asset Bundles' started by filipemourao_, Oct 14, 2022.

  1. filipemourao_

    filipemourao_

    Joined:
    Oct 9, 2020
    Posts:
    57
    Currently I have these three list's that contain these elements
    Code (CSharp):
    1. public List<GameObject> mediaPanels = new List<GameObject>();
    2.     public List<Button> continueButtons = new List<Button>();
    3.     public List<Button> backButtons = new List<Button>();
    upload_2022-10-14_13-41-42.png
    There is nothing within this script that clears the in Start or Awake methods.

    Once I build an Asset Bundle and load into it, the List's clear for some reason with size of 0. When I play the scene through the editor, the list does not clear, so I believe that it has something to do with the Asset Bundle build. Not sure what is going on. I also have other List's within my Asset Bundle that do not get cleared but these do.