Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Question Materials for sprite renderers loaded from the AssetBundle

Discussion in 'Scripting' started by astrokoo3, Oct 27, 2021.

  1. astrokoo3

    astrokoo3

    Joined:
    Jan 31, 2020
    Posts:
    22
    When you have a GameObject loaded from an AssetBundle

    The Material in that GameObject's Sprite Renderer component is copied and named instanced.

    Since we create those GameObjects very frequently, the material keeps accumulating and

    Because it was copied, the layout is also broken, which is a problem.

    Is this a Unity bug?

    our version is 2018.4.30f
     
    Last edited: Oct 27, 2021
  2. astrokoo3

    astrokoo3

    Joined:
    Jan 31, 2020
    Posts:
    22
    this cause by watch renderer of materials when breakpoint on vs or rider

    so if i not break and watch it remains not copied