Search Unity

Question Can't instantiate alembic prefab

Discussion in 'Asset Importing & Exporting' started by Leekimyung, May 18, 2020.

  1. Leekimyung

    Leekimyung

    Joined:
    Dec 5, 2017
    Posts:
    3
    Hello, question,
    I imported alembic file and it works in unity editor but not in the build.
    there is no problem to make prefab in the scene but prefab doesn't work when trying to instantiate the prefab.
    error mssage : "failed to load alembic at "path/.abc"
    It only works on build in alembic file direct instantiate
    How to solve this problem?

    my unity version is 2018.4.8f1
    alembic package version is 1.0.6
     
  2. vladala

    vladala

    Unity Technologies

    Joined:
    Mar 3, 2017
    Posts:
    189
    Hey,

    I presume you Instantiate the prefabs on the fly at runtime.
    The alembic package implements a build post processor and it traverses the all the scenes and copies the files in the app streaming asset directory.
    If the prefabs are spawned on the fly, this cannot work.
    I suggest you create your prefab instances in the scene and disable them until needed.
     
  3. Leekimyung

    Leekimyung

    Joined:
    Dec 5, 2017
    Posts:
    3
    I checked the error message, but It was tracking from wrong path.

    If the file location Assets/app/model/a.abc. system was looking for the file in streamingassets/app/model/a.abc.

    I resolved this problem by copying and pasting it to the same path.
     

    Attached Files: