Search Unity

Confused with exporting asset bundle

Discussion in 'Documentation' started by elpuerco63, Jun 29, 2015.

  1. elpuerco63

    elpuerco63

    Joined:
    Jun 26, 2014
    Posts:
    271
    Try as I might I cannot get this to work which is a shame as to me the previous 4.6 way was a dream :(

    The steps I follow here does create some files in the AssetBundle folder but I do not see what I am to do with them?

    In the 4.6 way I would have a model in a .unity3d file but now I have 4 files in the AssetBundle folder and if I copy either the entire folder or just its contents to my server the www call fails

    I don't quite follow this: http://docs.unity3d.com/Manual/BuildingAssetBundles5x.html

    What am I supposed to copy to my server?

    And then using this example does not work cod download and cache as I never get a bundle to work with in the first place? :(:(

    http://docs.unity3d.com/Manual/DownloadingAssetBundles.html
     
  2. alexeyzakharov

    alexeyzakharov

    Joined:
    Jul 2, 2014
    Posts:
    508
    The bundle files don't have extensions in Unity5. If bundle name is 'mybundledmodel', then there will be generated: 'mybundledmodel' - assetbundle file, 'mybundledmodel.manifest' - text file with information about bundled data, denepdencies, etc.. Plus, in case these files are in 'Assets' folder, corresponding .meta files will be generated. You can still use WWW to load 'mybundledmodel'.

    Please take a look at this demo: http://forum.unity3d.com/threads/new-assetbundle-build-system-in-unity-5-0.293975/
    It contains detailed information about build process and also has a demo AssetBundleManager that simplifies bundles loading.
     
  3. elpuerco63

    elpuerco63

    Joined:
    Jun 26, 2014
    Posts:
    271
    When I export to assetbundle and then import to the destination I find that the assest name is:

    assets/prefabs/housecontainerprefab.prefab

    Whereas under Unity 4.6 I would have simply used house.unity3d So now I have to prefix my code with assest/prefabs plus the actual name?

    Apart from that I actually got it to work :)))
     
    Last edited: Jun 29, 2015