Testing and Building - Unity-Technologies/EndlessRunnerSampleGame GitHub Wiki
Since the project use asset bundle, there is a couple of specific steps to take to test it in the editor or build it to device (android or ios)
Testing
Going in the menu Assets > AssetsBundles
enable "Simulation Mode". This will make the Bundle Manager directly use the asset from the project and you won't need to build them.
Building
To build the project, we first need to build the Asset bundle.
- Be sure to switch the platform in your Build Window to the target platform (Android or iOS)
- Use the menu entry
Assets > AssetBundles > Build AssetBundles
. This will build the bundle in an AssetBundles folder next to your Asset folder. - Copy that entire folder in your
StreamingAsset
folder in your project (So the folder structure should beStreamingAssets/AssetBundles/...
) - You can now build normally for your platform.
Testing built bundles in the Editor
It can be useful sometime to try using the built bundles in the editor instead of the Simulation mode, to check everything is bundled properly.
To do that, we just need to switch the platform to desktop and build bundles, put the AssetBundle in the StreamingAssets folder and disable the Simulation mode.
If you have fully pink objects trying that, verify that it is the desktop Asset Bundle you built and that your Editor have the platform set to Desktop. If your platform is Android/iOS, it will try to use iOS/Android Bundles, and mobile compiled shaders won't work in Desktop