How can I include tags in an unitypackage and asset store build?
It would have to contain the tagmanager.asset right, but how am I supposed to include this in any of the above?
Anyone who has tried to transport a PC-created project to a Mac or vice-versa knows exactly what you mean. I haven’t gotten around this task yet, but my recommendation would be to create string/class references for all of your objects, and then reverse that process afterwards.
For instance:
You have a project where all trees must be tagged as “Tree.” They also have a script called “Tree” on them.
Use GameObject.FindObjectsOfType to find each object with said script on it in your initial Start() function reference.
Then, once you get the game over to the buyer, you can reverse that by doing something like:
public int ID = 1;
if(int > 0)
foreach(GameObject OBJ in Trees){
OBJ.tag == "Tree";
}
Of course, while you’re editing the project, you should keep your ID at 0. You can make this more convoluted if you wish, like a string ID.
The only way I know of to readily accomplish an export the tagmanager.asset is to include all of the project setting asset files. You will have to write a custom package exporter to do so. Here are the pages in the docs to get you started: