- Home /
The question is answered, right answer was accepted
Version tracking
Is there any easy way to have version number and build index (which increment every time I build game) in Unity project? For exaple when I save project it will be saved to folder named "[project name]_[version]" (for example "EasyPlatformer_4_36"). And have that version stored in variable so I will be able to write: about.text = "Version " + version + " build " + build.
I hope you understand what I had in mind.
How many builds are you creating because if it's just a few, you could just hardcode the version and build number.
@n314p // Not many, but that number will be increaseing.
Hardcode it isn't a bad idea but how it will be most optimal?
maybe it's possible to have a Editor script that let's you do this ? just a guess
Answer by Xarbrough · Dec 21, 2017 at 01:10 AM
You can use the Build Player Pipeline to increment your version number. You could just store a text file or ScriptableObject in your asset folder, load it, increment the number and then build how you like. If you google "Build Script" and "-Pipeline" you should find other examples. There are also open source and Asset Store tools for this. No built-in or easy method though.
Follow this Question
Related Questions
Flashlight Moving Awkwardly 0 Answers
Share (and edit) assets across different projects 0 Answers
How Does One "Setup" For A New Project 1 Answer
version control - related to another question 1 Answer
question Project Maintenance 1 Answer