Author Topic: Dynamic fonts issue with Unity 4.3  (Read 11873 times)

Nubeh

  • Newbie
  • *
  • Thank You
  • -Given: 1
  • -Receive: 0
  • Posts: 41
    • View Profile
Dynamic fonts issue with Unity 4.3
« on: November 29, 2013, 03:45:30 AM »
After I updated to Unity 4.3 (and yesterday update to 4.3.1 didn't solve the things) I have an issue with my fonts. Basically instead of taking my font (which was working before) now the font is Arial. The weird thing is that I was seeing Arial fonts also in the Editor until yesterday. When I updated to Unity 4.3.1 and that allowed the Editor to render the correct font I'm using. But if I deploy to iOS or Android the font is again Arial.

For the dynamic font I have simply imported a .ttf file in Unity and used that without creating a Font with NGUI.

I don't know if this is related but after updating NGUI to the latest version (3.0.6) I also get these error message in the console,

Unlit/Text doesn't have a clipped shader version for SoftClip
UnityEngine.Debug:LogError(Object)
Debug:LogError(Object) (at Assets/Scripts/Debug.cs:58)
UIDrawCall:CreateMaterial() (at Assets/NGUI/Scripts/Internal/UIDrawCall.cs:303)
UIDrawCall:RebuildMaterial() (at Assets/NGUI/Scripts/Internal/UIDrawCall.cs:324)
UIDrawCall:UpdateMaterials() (at Assets/NGUI/Scripts/Internal/UIDrawCall.cs:347)
UIDrawCall:Set(BetterList`1, BetterList`1, BetterList`1, BetterList`1, BetterList`1) (at Assets/NGUI/Scripts/Internal/UIDrawCall.cs:453)
UIPanel:SubmitDrawCall(UIDrawCall) (at Assets/NGUI/Scripts/UI/UIPanel.cs:1049)
UIPanel:Fill() (at Assets/NGUI/Scripts/UI/UIPanel.cs:1004)

Anybody has this problem as well? Thanks.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Dynamic fonts issue with Unity 4.3
« Reply #1 on: November 29, 2013, 09:20:38 AM »
Did you move the shaders that come with NGUI from their default location within the Resources folder? That error will only happen if NGUI can't load them.

As for your fonts being replaced with Arial... don't know about that one. Maybe they are not imported as dynamic fonts, but rather as static size. Check on the font itself.

Nubeh

  • Newbie
  • *
  • Thank You
  • -Given: 1
  • -Receive: 0
  • Posts: 41
    • View Profile
Re: Dynamic fonts issue with Unity 4.3
« Reply #2 on: December 02, 2013, 03:52:41 AM »
Oh, yes I didn't import the Shaders folder by mistake, thanks.

The issue with the fonts is still there though...but again it happened when I updated Unity to 4.3 and 4.3.1 made the fonts work in the editor but not on device. Maybe I'll try to create fonts with NGUI instead of using the imported dynamic font directly.

Nubeh

  • Newbie
  • *
  • Thank You
  • -Given: 1
  • -Receive: 0
  • Posts: 41
    • View Profile
Re: Dynamic fonts issue with Unity 4.3
« Reply #3 on: January 27, 2014, 05:42:22 AM »
Hi, I'm still having the issue with the dynamic fonts not being shown correctly only when deployed on device (I sent you also an e-mail). The issue was supposed to be fixed in one of the latest releases of NGUI but for me the problem is still there.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile

Nubeh

  • Newbie
  • *
  • Thank You
  • -Given: 1
  • -Receive: 0
  • Posts: 41
    • View Profile
Re: Dynamic fonts issue with Unity 4.3
« Reply #5 on: January 29, 2014, 04:50:00 AM »
I'm having a different problem...I don't have missing characters or misaligned characters. My characters display correctly at the right position, the problem is that on device they don't display with the font I use but with the default (Arial I guess) font.
This means that in the editor when I run the game my labels use my font, while when deployed on device (both iOS and Android) my font is not used and the default Arial font is used instead for some reason.

Any idea why? It started after Unity updated to 4.3, before that it worked fine.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Dynamic fonts issue with Unity 4.3
« Reply #6 on: January 29, 2014, 08:31:21 AM »
Sounds like Unity bugged something. I suggest reporting it.

Nubeh

  • Newbie
  • *
  • Thank You
  • -Given: 1
  • -Receive: 0
  • Posts: 41
    • View Profile
Re: Dynamic fonts issue with Unity 4.3
« Reply #7 on: January 30, 2014, 07:31:34 AM »
what is strange also is that if I use ttf files from my Mac they work fine, but if I use a ttf downloaded from dafont.com then it doesn't work anymore. All my labels have weird cut characters for some reason. All except that one font I was using before (the Batman Forever font, that one still works fine in the editor). Strange :(