Author Topic: 'Shuriken Magic' Effects and NGUI  (Read 2703 times)

maaya

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 22
    • View Profile
'Shuriken Magic' Effects and NGUI
« on: February 20, 2014, 01:56:08 PM »
Hi,

I have had some success building our game with NGUI and now I am trying to add effects but falling flat. I purchased the Shuriken Magic Effects pack from the Asset store but they dont seem to be playing nice with NGUI. Both these assets appear to be quite popular, so has anybody else run into similar issues?

1. Attached are the images of what I see in my scene with NGUI camera (solid red) for the axe vs. the image in their demo. I would guess it has something to do with the Shader since the other effects using the same shader also appear in solid color unlike the effects in their demo.
However, they look fine if I add them to a new scene with Unity's camera. Could anyone point me to what the Shader could be interfering with NGUI?

2. All the effects seem to be as if looking from the side when using NGUI's camera vs. looking from the top with Unity's camera since I can adjust the position. I tried changing the Render Queue as mentioned in this post: http://www.tasharen.com/forum/index.php?topic=2247.0 but no luck. If I change the Z-value, to push them back, it does not seem to be making any difference either. Is the NGUI camera working only in X-Y ?

I'd really appreciate if anyone can point me in the right direction.

Thanks

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: 'Shuriken Magic' Effects and NGUI
« Reply #1 on: February 21, 2014, 04:12:58 PM »
Those aren't sprites. They're 3D objects.

maaya

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 22
    • View Profile
Re: 'Shuriken Magic' Effects and NGUI
« Reply #2 on: February 22, 2014, 02:27:16 PM »
That is correct. They are 3D objects with some Shader which is interfering with NGUI. Using Unity's (Perspective) camera, they look fine. Moving NGUI's 2nd Orthographic camera under UIRoot, changed its position to something like (0, 1985, -2345) and it started showing right again.

Any pointers (on #2 as well) will be much appreciated.

Thanks

Nicki

  • Global Moderator
  • Hero Member
  • *****
  • Thank You
  • -Given: 33
  • -Receive: 141
  • Posts: 1,768
    • View Profile
Re: 'Shuriken Magic' Effects and NGUI
« Reply #3 on: February 23, 2014, 01:22:11 AM »
Are you rendering ingame effects using the UICamera? Why?

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: 'Shuriken Magic' Effects and NGUI
« Reply #4 on: February 23, 2014, 12:25:04 PM »
Orthographic cameras don't work with certain shaders. Water shader for example. Without knowing what shader it's using, I can't do much. Even with the shader it's not an NGUI question, it's a Unity question. NGUI has nothing to do with rendering of 3D objects.