- Home /
Variables assigned in inspector disappear in git version-control?
I'm working on a unity project with a number of people using git version control. When I assign a variable in the inspector (e.g. drag an AudioClip into an AudioSource component), it sometimes disappears when someone else opens the project after I've pushed my changes. This even happens on prefabs when I apply the changes I've made and upload it to the repo.
Does anyone know what causes this problem? Where exactly are the variables one assigned in the inspector saved? Is this maybe a general repo/git problem? Or does it depend on some Unity settings?
Are you sure you have followed every steps of the guide ?
Yes, I did. Apart from this issue, everything is working properly with the repo. I've had this problem with several projects already…
$$anonymous$$ake sure that both the asset itself and the associated .meta file is added to version control... Then you can put it gitignore, if you want
Changes applied to a prefab is saved in the prefab meta file. When you save a scene everything is saved, and can be pushed to git.
Answer by dccoo · Jun 07, 2017 at 01:39 PM
Edit > Project Settings > Editor > Version Control > Visible Metadata
Your answer
Follow this Question
Related Questions
How to assign a variable in the inspector 1 Answer
Variable nos assigned on inspector, but it has been assigned on inspector ? 0 Answers
Public variables are not showing in the inspector 1 Answer
Using git on scripts - Why do i have to keep setting project permissions on launching unity? 1 Answer
Inspector slider value? 2 Answers