Build version tags can be statically checked in simulation graphs and allow to switch between two versions of a given computation depending on the platform the effect is baked for.
For example, this allows to disable some expensive features on mobile platforms, such as turbulence, but keep them active in a desktop build.
You can also use version tags to differentiate debug and release bakes of your assets by adding a special “debug” tag where you enable some extra computations in your effects graphs which are there just for debugging purposes. When baking without the “debug” tag, the graph compiler will strip all computations culled by the version node.
Version tags are set in the Particle oven, in its ‘BuildVersions’ array.
Here is an example particle config for a build target named “Desktop” and another named “Mobile”, that defines a couple of version tags:
COvenBakeConfig_Particle $7B0C3E1E { BakeTarget = "Desktop"; BuildVersions = { "desktop", "x86", "pc", "windows", "linux", "macos", }; } COvenBakeConfig_Particle $DDECD857 { BakeTarget = "Mobile"; BuildVersions = { "mobile", "android", "ios", "arm", }; }
Any graph doing a version check on either “mobile”, “android”, “ios”, or “arm”, will evaluate that version check to ‘true’ whenever baked for the build target “Mobile”.