Author Topic: NGUIEditorTools.FindAll is not found on 3.0.2  (Read 1483 times)

rganeyev

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 22
    • View Profile
NGUIEditorTools.FindAll is not found on 3.0.2
« on: October 09, 2013, 10:17:59 AM »
I imported an upgrade from 2.7.0 to 3.0.2
Everything was ok, except UpgradeWidgets script. It claims that there's no method NGUIEditorTools.FindAll<T>. It seems that I have broken NGUIEditorTools script?

  1. List<UISlicedSprite> sliced = NGUIEditorTools.FindAll<UISlicedSprite>();
  2.  
It's only thing that doesn't compile, so I added code like this:
  1. //NGUIEditorTools.cs
  2. public static List<T> FindAll<T>() where T : MonoBehaviour
  3.     {
  4.         var objs = Object.FindObjectsOfType(typeof (T));
  5.         return objs.Cast<T>().ToList();
  6.     }
  7.  

Can anybody share me NGUIEditorTools, please?
« Last Edit: October 09, 2013, 10:23:03 AM by rganeyev »

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: NGUIEditorTools.FindAll is not found on 3.0.2
« Reply #1 on: October 09, 2013, 01:31:18 PM »
It's on line 649 of NGUIEditorTools.cs. It's also present in NGUITools.