- Home /
How do I build asset bundles when play mode button is clicked?
I'm using Asset Bundles and the standard Unity build pipeline. I use the following editor script to kickoff asset bundle build for my project.
[MenuItem( "Assets/Asset Bundles/Build Windows x64" )]
static void BuildWindows64()
{
// code to build omitted
}
My current workflow requires me to manually build assets via the menu item above before clicking play button. I'd like to know if I can simplify this workflow. Ideally, when I click the play button, the build would automatically occur for asset bundles and then begin playing. How can this be achieved?
Your answer
![](https://koobas.hobune.stream/wayback/20220613024155im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Loading a large texture at at run time kills fps 1 Answer
How to save AssetBundles to Cache? (Loaded from Memory) 0 Answers
Unity 5.3.3f1: How to set an object as AssetBundle by script? 0 Answers
Will assetbundle automaticly load instead of download if its already present on the device 1 Answer
"Switch Video" script? 1 Answer