Author Topic: Error on import~  (Read 4250 times)

Burdock

  • Guest
Error on import~
« on: September 01, 2013, 12:09:33 AM »
Just got NGUI today, got my email with the download link~ downloaded it, imported ..... And compiling error :)

/NGUI/Scripts/UI/UIFont.cs (644,38): error CS1502: The best overloaded method match for `UnityEngine.Font.GetCharacterInfo(char, out UnityEngine.CharacterInfo, int, UnityEngine.FontStyle)' has some invalid arguments

Assets/NGUI/Scripts/UI/UIFont.cs(825,66): error CS1061: Type `CharacterInfo' does not contain a definition for `width' and no extension method `width' of type `CharacterInfo' could be found (are you missing a using directive or an assembly reference?)

Assets/NGUI/Scripts/UI/UIFont.cs(1282,54): error CS1061: Type `CharacterInfo' does not contain a definition for `uv' and no extension method `uv' of type `CharacterInfo' could be found (are you missing a using directive or an assembly reference?)

 

And about 24 others ~ I think they all stem from  CharacterInfo j in Assets/NGUI/Scripts/UI/UIFont.cs....

Am I doing something wrong? Is there any quick fix to this? Or is UnityEngine.Font.GetCharacterInfo just written wrong?


LightSky

  • Jr. Member
  • **
  • Thank You
  • -Given: 3
  • -Receive: 2
  • Posts: 56
    • View Profile
Re: Error on import~
« Reply #1 on: September 01, 2013, 12:51:46 AM »
Do you have any scripts that might have conflicting names? 
Try importing NGUI into an empty project.  If it works (which it should), then there is a confliction in your previous project which you need to find and deal with.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Error on import~
« Reply #2 on: September 02, 2013, 06:16:26 PM »
What version of Unity? NGUI requires 4.1+, or 3.5.7.

Burdock

  • Guest
Re: Error on import~
« Reply #3 on: September 04, 2013, 05:50:25 PM »
I got it fixed, the issue was that the Class of the method CharacterInfo was importing in the wrong location... Nothing that reinstalling unity didn't solve.

Sorry guys, I guess it was an import error... nothing to do with NGUI :/

~Daniel