Does save scene as save all setting changes?
I have a game that I have been saving along many steps of creating, and now I realize after many "save scene as" saves it is not saving the changes as I thought. it saves what game objects you add or delete from the inspector only . when I changed speeds of players or other things like this in the inspector it did not save different it saves over the original
so does anyone know what exactly save scene saves and what it doesn't?
is there a way to save all changes thanks
Answer by TheGreyRaveen · Dec 25, 2016 at 08:40 PM
If you save a scene all public variables in scripts set via Inspector are also saved. Did you change them while in play mode? Changes made in play mode are not saved, only those made in the editor mode are saved.
hi no , i am aware of that if changed in play mode nothing is saved
I always saved in editor mode also if you change a script is that also saved in new save?
Scripts have to be saved independently. Saving scene doesn't save changes made in scripts. In fact Unity has access only to these versions of scripts which are saved on a hard drive. If you make some changes in scripts always remember to save them in your code editor, otherwise Unity will still read old version of a script without displaying any warning messages. This can be sometimes very confusing.
when you say save them in code editor can you explain how I do this? do you mean to save them under a different new name?
yes also so to be clear,, -- so everything is saved in a "save scene as " except script changes?
As far as I know "save scene" saves you only a scene file .unity. Generally all other "things" are saved independently. I'm gonna give some examples. If we create a script .cs, it will be immediately saved on a drive. And going further if we want to change its code, we have to save it in VisualStudio, $$anonymous$$onoDevelop etc ( these are examples of those "code editors" i mentioned). If we take .prefab and change some values in its Inspector it will be immediately changed in its file and overwritten on a drive. Or if we create animation .anim it will be saved immediately on a hard drive. What I'm trying to say is that the operation "save scene" only overwrites "scene.unity" file. It has nothing to do with other files like scripts, sprites etc. And to be clear .unity file is responsible only for the objects and their settings set in the specific scene(those you can see in Hierarchy window). All assets included in projects remain untouched regardless of whether you save scene or not. That's why there's no warning if for example you only change some assets and quit Unity.