public static void SaveSceneObjPosesAsInt() { GameObject go = GameObject.Find("scene"); if (go == null) { Debug.LogError("SaveSceneObjPosesAsInt scene null"); } SceneObjects so = go.GetComponent <SceneObjects>(); so.HandleObjs(); so.HandleObstacles(); UnityEditor.SceneManagement.EditorSceneManager.SaveOpenScenes(); }