Author Topic: RegisterSceneUndo obsolete in unity alphas  (Read 7150 times)

dillrye

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 1
  • Posts: 30
    • View Profile
RegisterSceneUndo obsolete in unity alphas
« on: August 26, 2013, 10:53:25 AM »
 
Hello, I am getting the error:
`UnityEditor.Undo.RegisterSceneUndo(string)' is obsolete: `Please use DestroyObjectImmediate, RegisterCreatedObjectUndo or RegisterUndo instead.'

Do you know what the suggested replacement would be? I am not super familiar with the Undo functionality.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: RegisterSceneUndo obsolete in unity alphas
« Reply #1 on: August 27, 2013, 02:51:12 AM »
Are you asking for your own project or NGUI? If former, I'd advise asking on the beta forum, as that functionality is only in the alpha/beta of 4.3 and should be kept confined to that forum.

If the latter, I wouldn't change anything in NGUI trying to fix it. It will be adjusted for you in a later version.

dillrye

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 1
  • Posts: 30
    • View Profile
Re: RegisterSceneUndo obsolete in unity alphas
« Reply #2 on: August 27, 2013, 09:19:01 AM »
I wanted to update my local copy of NGUI so I could use the newest client.  I would revert these changes once the official fix was added. This is throwing a compilation error, not a warning.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: RegisterSceneUndo obsolete in unity alphas
« Reply #3 on: August 27, 2013, 12:19:37 PM »
As I understand it, the last 4.3 build fucked up and removed some functionality instead of deprecating it -- something the next build should address. I am not sure which undo to use in this case, but you can always simply comment out the offending line.