Tags, Layer Names Runtime?

Ok, first of all, I KNOW that this question has been asked many times before and all the time people said it’s impossible to change the tag list, layer list and sorting layer list in run time or in other words, by using custom editor menus, but, for me, i never accept impossible as an answer, to me, it comes from people who don’t want to accept a challenge and sit and think and find a solution.
please take a look at this picture :
alt text

Behind the scene this is the TagManager.asset file in project settings folder, I opened it with a hex editor and what i see? it’s a binary file with all the names i added to project being there! So the question comes into the mind, if the layer names are simple strings, even in the binary file, without any encoding, and I’m sure somewhere there in the file there is an integer defining the number of elements in the list…

Why the hell we shouldn’t be able to read this binary file and tweak it’s data using .net classes and stream readers? I didn’t do the binary read personally, so this is the reason I’m asking the same old question again !

Also, there is another question regarding this, I’m not good at reflection in coding, but is it possible to change these lists and their members by reflection from code?

please before closing your eyes and say “It’s impossible!” sit for a minute and think for a possible solution on tweaking these asset files, because if we can change even one of them, the rest of the settings in the folder falls under same solution !

Nice Concept!

But when people say it is not possible to add tags at runtime it is because it is not supported in the Unity public API and not because they are dumb.

If you are in a dire need of creating custom tags at runtime and using them then you can create your own tagging system which I think is way less pain in the … than trying to tweak those files.

And why do you even need to change the project settings files? Do you think if you just change one line in those files will provide you with magic features?

Plus I suppose those guys at Unity aren’t so stupid to keep things so easily accessible and open to the world when they are selling a paid product costing thousands of dollars. Think about that.

Plus have you even thought about the Copyright and Licenses issues that are present in doing something that you suggest. Food for thought! :stuck_out_tongue: