Editor questions upgrading to 4.3

I upgraded to 4.3 since the rest of my lab upgraded. Now I have entirely new evils to work with.

I have a few main questions I was hoping a wise Unity3D sage or two could help me with:

  1. With the deprecation of the Undo functions and Undo.RegisterSceneUndo(), what do I call to make an undo to EditorApplication.OpenSceneAdditive()? I see a Undo.RegisterFullObjectHierarchyUndo(), but it takes in an Object, and it has no info in the documentation.

  2. My rich text in the editor labels are now raw and showing the tags.

  3. One of my EditorWindow has a reference to a MonoBehaviour. When I play and stop the game, the connection becomes null (or at least the var == null check returns true), which means I have to close and reopen it to give it a new valid reference. It used to be able to keep the connection. There was also an oddity with it since the editor also edited ScriptableObjects, which means I had to have

int id = m_Targ.GetInstanceID();
m_Targ = (HelpSys)EditorUtility.InstanceIDToObject( id );

at the beginning of OnGUI (where HelpSys is the MonoBehaviour), but it worked - but not even that rebinds the MonoBehaviour between play and stopped (and removing it doesn’t help). I can store GameObject and call GetComponent() on it at the top of OnGUI() but I’d prefer not to.

Thanks!

Hello WilliamLeu,

We have here the same problem with Undo.RegisterFullObjectHierarchyUndo(). We cannot manage how to use the new Undo API.

We have to store undo operations for the object and all of its hierarchy (transform, mesh destruction, colliders instantiation…), but It doesn’t work.

Hope the people at Unity can help us soon,