Why does saving a script in runtime lose in game data?

I remember in the earlier versions of unity that when you saved any changes to a script while playing live in the engine, that it didn’t lose information in game, it just updated… What happened? When I save a change in any script during run time (even non relevant), it loses all data set from awake and start functions and so forth, and I have to restart the game play to get current with any new code I set. I HATE THIS! I test out a lot concepts for my games and having to restart plays from the beginning just because I changed one simple thing in a script is driving me crazy.

Is there a way to bypass this? Am I missing something in the new version?

I have heard of player prefs but is really necessary for just updating a script while playing in the engine itself?

I have a ton of scripts so when I save in any one of them, it takes forever to update.

Sounds like an issue with serialization. Check out this blog: Unity Serialization | Unity Blog . They talk about EditorWindows, but it’s all applicable to the inspector as well.