Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - legend411

Pages: [1]
1
NGUI 3 Support / Re: Parent ParticleSystem to UISprite?
« on: March 18, 2014, 12:48:25 PM »
Nevermind! I just realized the particle prefab I was using had a self-destruct script on it. Doooy  :o

2
NGUI 3 Support / Parent ParticleSystem to UISprite?
« on: March 18, 2014, 12:21:07 PM »
I have a particle effect i'd like to appear over top of a button... I'm not having any rendering queue issues, but i'm not sure how to make it so the particle system is positioned and scaled appropriately to the button. I tried parenting it to it, and it works sometimes, but other times I run the scene it NGUI decides to just delete the ParticleSystem. What gives?

3
As I mentioned in the OP, it works fine when I do it manually... but I need to disable/enable the panel and all its children whenever it fades out/in, and SetActiveRecursively() is giving me weird issues or not working at all, and apparently NGUITools.SetActive() doesn't exist in the free version, unless I'm missing something.

Either way, if doing it by hand works, it'd be nice if you could make the TweenColor work, too (on the panel and all child widgets); not sure why it doesn't. I really like how intuitive using the built-in tweens is.

4
I don't just want to set it invisible, I want to fade the alpha from 255-0 over time, then disable it entirely so it can't be interacted with.

5
I tried using a tween color component on the parent UIPanel and activating it with a UIButtonTween in another panel, but I get really odd results.

Also, is NGUITools.SetActive() in the latest version of the free package? I've been trying to do it by hand as an alternative, looping through all the GetComponentsInChildren.<UIWidget>() of the panel and lerping their color.a, but I'm getting weird results with SetActiveRecursively(), and its telling me NUGITools.SetActive() doesn't exist. I just downloaded the package over the weekend?

6
NGUI 3 Support / Best way to re-position UIPanel through script?
« on: May 05, 2012, 11:30:51 PM »
I'm trying to move a UIPanel to the position of a UIButton, plus an offset, when the button is pressed. just setting UIPanel.transform.position to the button position seems to work fine, but when I try to add an offset to the x/y position, it seems to be using world units, not pixels, to position it. How can I add an offset in pixels?

7
Naw its set to toggle, so it switches between forward and reverse. I was hoping "disable after reverse" would still work with a toggle, but it seems it only works when play direction is set to reverse.

8
I've got it mostly worked out... the only other thing is the edit I made to the OP, that the Disable When Finished functionality of UIButtonTween doesn't seem to be working at all...

Edit: ohh I see, its not working because I have the button being a toggle. Since toggle just switches between forward/reverse depending on whatever was last done, couldn't disable after reverse still be a viable thing?

9
So I have two separate UIPanels, one has a simple sprite box and some labels, the other has a button with UIButtonTween that has the other panel set as the target object. That panel (set as the target) has a TweenColor component going from 0-255 alpha, disabled at the start.

When I push the button, the panel fades in, but as it fades in the button I pushed fades away, even though its in a totally separate panel from the one set as the target of the UIButtonTween. I tried playing with the depth, to no avail. Is this intended behavior?

EDIT: I also noticed enableThenPlay works in UIButtonTween, but neither disableAfterForward or disableAfterReverse work at all.

Pages: [1]