The Build Object Remover allow you to automatically remove object with selected tag from scenes from a build.
By default Unity Editor removes objects with tag 'EditorOnly' from build and runtime.
Build Object Remover allow you to add more tags that will be removed from selected platforms and build types.
Latest steps available at Unity manual
- Copy https link to this repository
https://github.com/vverum/Unity_BuildObjectRemover.git - Open package manager in unity
- Press Add button (+ in the upper left corner) and select
Add package from git URL...
- Paste link and press
add
- Download package (tgz file) from releases
- Move file to project location
- Open package manager in unity
- Press Add button (+ in the upper left corner) and select
Add package from tarball...
- Select package file
- install normally like any unity asset from Unity Asset Store
Package dependencies:
- com.unity.settings-manager #2.0.1
Build Object Remover view is located in Project Settings
- Adding and removing tags is as simple as pressing the appropriate button.
- Select correct tag from drop-down list with tags in new created row.
- Enable the row with selected tag.
- Select correct build type.
- Done.
In Remove from build types
you are selecting the type of build when the object will be removed.
- Nothing - does not remove from any runtime or build
- Everything - remove from any runtime or build
- Editor Play Time - remove from play time in editor
- Development - remove from builds that have checked Development option
- Release - remove from build that is not development
For example:
If only 'Development' is selected, then objects in "Development" build will remove, but objects in the release build will not be removed.
- Press
Add Platform
button. - Select the platform you want to add options to.
- Press
Add Platform
again.
A tag set on a specific platform will not override the tag setted in All platforms
!
Press Apply
button to save current changes.
Press Revert
button to discard currently unsaved changes.
Changes that are not applied before build will not take effect!
Tags marked to remove will be listed in log in console after building process.
github.com/vverum/Unity_BuildObjectRemover
This project's license is available in the provided "LICENSE.md" file.