Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
2
Question by BDV · Mar 10, 2015 at 07:17 AM · unity5assetbundleassetbundlescommand

AssetBundles Unity5 (No AssetBundle has been set for this build)

Hi, i saw the changes in Unity5 assetbundles export methods. However i need to create assetbundles in a script and run that script from command line. In unity 4.6 it worked.

I was trying to create assetbundles with this example :

 @MenuItem("Test/Build Asset Bundles")
 static function BuildABs() {
     // Create the array of bundle build details.
     var buildMap: AssetBundleBuild[] = new AssetBundleBuild[1];
     
     buildMap[0].assetBundleName = "enemybundle";
     var enemyAssets: String[] = new String[1];
     enemyAssets[0] = "cube_prefab";
       buildMap[0].assetNames = enemyAssets;
     
 
     
     BuildPipeline.BuildAssetBundles("Assets/ABs", buildMap);
 }

It should create assetbundles using some building map. I created a simple cube , made a prefab from it and called it cube_prefab. When i run this script i just get a warning No AssetBundle has been set for this build.

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

3 Replies

· Add your reply
  • Sort: 
avatar image
8
Best Answer

Answer by BDV · Mar 10, 2015 at 09:02 AM

I solved it, you need to put relative paths into the assetnames ... so instead of "cube_prefab" it should be "Assets/cube_prefab.prefab" and it works.

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image MorphVGX · Jul 05, 2018 at 12:04 AM 0
Share

I discovered I would still "No AssetBundle has been set for this build." if the path to any of the assets is incorrect.

avatar image
0

Answer by Desdemona_cry · Apr 16, 2015 at 07:17 PM

is this script for build assetbundle at runtime?

Comment
Add comment · Show 3 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image BDV · Apr 17, 2015 at 02:43 PM 0
Share

you need to use namespace UnityEditor so its working only in editor

avatar image Desdemona_cry · Apr 17, 2015 at 03:22 PM 0
Share

Is there any way for build assetbundlet at runtime dude? i browse a thousand time and found nothing about that..

avatar image Banemus · Jun 02, 2015 at 01:02 PM 0
Share

nope it is not possible.

avatar image
0

Answer by wanghaibo0903 · Nov 22, 2016 at 09:07 AM

I still can't figure it out.

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image BDV · Nov 22, 2016 at 01:18 PM 0
Share

Where did you get stuck ?

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

24 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Unity 5 Asset Bundles limitations for mobile platforms. 0 Answers

Exporting assets from Unity 5 to Unity 4 1 Answer

2D toolkit dynamically load scenes with the new assetbundle of Unity5 0 Answers

Loading.IDRemapping AssetBundles 1 Answer

AssetBundleManager - what asset bundle URL to specify for iOS (Xcode simulator, Testflight, Appstore)? 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges