Author Topic: HUDText - All letters Black  (Read 5266 times)

schwarzenego

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 30
    • View Profile
HUDText - All letters Black
« on: July 09, 2013, 05:10:42 PM »
Hello,

I've purchased HUD Text and first of all I must say its awesome! Its been working great so far... however, I have a problem I have no idea what to do to fix.

The plugin works great on my pc, but there are some Android devices (I've tested on: Samsung Galaxy S2 (works great), Motorola Xoom (bugs), Asus Nexus 7 (bugs)) which show all letters as black squares. Since it is working on PC and even on Galaxy S2, I dont think I've done something wrong on my side, but Id like to know if this is a known bug, or I am really doing something wrong.

Thank you for your attention,
Best regards,
Allan

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: HUDText - All letters Black
« Reply #1 on: July 09, 2013, 10:06:48 PM »
HUDText simply uses NGUI's labels, so this would be an NGUI question. Try adding a simple label to the scene instead and see if that works.

schwarzenego

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 30
    • View Profile
Re: HUDText - All letters Black
« Reply #2 on: July 10, 2013, 09:55:19 AM »
Doesnt work, same problem =/

This is my second project with NGUI, on the first it works perfectly on these same devices, and this one, which is a simpler than the other, this error is happening =/ Have any idea of what could be?

Also, let me ask you, on this project I have a lot of units on screen (max 42, for mobile). I've noticed that when they all are taking damage (thats when I call HUDText for scrolling combat text), the profiler indicates a high load on the UIPanel.LateUpdate() and constant GC.Collect() calls that use up to 10ms each (these calls happen like every 30 frames while the text is being displayed). Is there some kind of optimization I could make in any way?

Thanks for your attention,
Best regards,
Allan

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: HUDText - All letters Black
« Reply #3 on: July 10, 2013, 12:09:25 PM »
What version of NGUI? 2.6.3 reduced the strain on GC significantly.

If the first one works, and the second doesn't, then I suggest looking closer at the project's settings to see what's different. You said you checked GLES 2.0. Set the main camera's clear settings to clear color or skybox with color that has alpha of 255. Set the UI camera to clear only depth. Compare the quality settings with the project that works.

schwarzenego

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 30
    • View Profile
Re: HUDText - All letters Black
« Reply #4 on: July 10, 2013, 03:50:09 PM »
Im using NGUI 2.6.3 and HUDText 1.6. There can be quite a lot of scrolling combat text during my game at the same time, but the CG calls reduce quite much the performance of my game, which is already on the edge with 40 enemies on screen...

I've re-checked the project settings (all of them) and they are pretty much the same, except for Stripping Level, which on the previous project was mscorlib and on this one is disabled. Ive set up the cameras as you've suggested, but the same thing happens. I've even tried changing the text shader, but always with the same results. It is as if fonts were being rendered all black...

On the other project however I do not use HUD Text, only NGUI regular features, I had another system for scrolling combat text, decided to switch to HUD Text cause it was Unity GUI based.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: HUDText - All letters Black
« Reply #5 on: July 10, 2013, 08:32:53 PM »
Start a new scene, hit ALT+SHIFT+L to create a label. Still black squares? If no, then use that scene until you figure out what you did wrong in the old one. If yes, check the panel responsible for drawing your labels. Is it using clipping? If it does, then it's using a different set of shaders that it attempts to load from the Resources folder. If you moved the shaders somewhere else, it won't be able to find them. To fix this, you need to delete NGUI and re-import it from the package.

If that's not it, I don't know what's wrong with your project, and all I can suggest at that point is starting anew with the project that works.

schwarzenego

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 30
    • View Profile
Re: HUDText - All letters Black
« Reply #6 on: July 12, 2013, 02:40:48 PM »
I dont know exacly what was causing it... actually I have no idea... but I've created a new font and it is working again... in another words, there was something I did on the other font that prevented it from working on some android devices... =/ If by any chance I discover or repeat the error, I will let you know what it is.

Thanks for the support anyway!