What does `EditorFolding` class do (Engine) ?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Thakee Nathees

As I was debugging the engine, I’ve came across an instance of EditorFolding (godot\editor\editor_folding.h) and I’ve no idea what that class is for. Could someone explain ( and what does the method EditorFolding::save_scene_folding() do) ?

:bust_in_silhouette: Reply From: njamster

When you save a scene (or resource), Godot will store information regarding:

  • the properties in the inspector you unfolded (node|resource_unfolds)
  • the nodes in the scene-tree you folded away (nodes_folded)

On Linux you can find the files containing these information under ~/.config/godot/projects/<ProjectName>-<MD5Sum>. There are normal *.cfg-files, so you can open and read them with any standard text editor. If you reopen the scene, this information will be loaded to restore the work environment precisely the way you left it.