Search Issue Tracker
By Design
Votes
0
Found in
2017.3.0p1
Issue ID
1030160
Regression
No
HideInHierarchy flag objects can not build into assetbundle
How to reproduce:
1. Open the attached project
2. Click Tools/Add Sub Asset
3. Click Tools/Build Assetbundle
4. Open the "Demo" scene
5. Click Play
6. Check the console (it logs objects inside both asset bundles)
Actual result: There are no sub-asset objects in SubAssetHide asset bundle.
Expected result: The asset bundle should contain sub-asset objects.
Reproducible with: 2018.2.0b2, 2018.1.0f2, 2017.4.2f1, 2017.2.2p4, 2017.1.3p3.
Notes:
"Tools/Add Sub Asset" adds sub-asset to "SubAssetHide" and "SubAssetVisible". The one added to SubAssetHide hideFlags is HideInHierarchy.
"Tools/Build Assetbundle" builds SubAssetHide and SubAssetVisible to two asset bundles.
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- ListView fails to display items when the source list is cleared and a single element is added
- UI Toolkit ':hover' state remains active when another panel is drawn over the hovered element and Touch input is used
- Unsupported Orient modes can be selected and throw errors when using Strip VFX
- "Tab" key exits the name text field in the VFX Graph tab when renaming the Property
- Shader warnings are thrown when deleting blocks in the Ribbon VFX Graph
Resolution Note:
BuildPipeline.BuildAssetBundles builds based on what it can detect is being used. In the provided example, the main object is a material and it has no references to the HideInHierarchy objects thus it does not include them as it sees them as unused. Scriptable Build Pipeline (2018.2 package) changes this behavior to get all source objects instead and allows user filtering of those objects as needed.