Author Topic: (!!!) Improving NGUI: Voice your opinion  (Read 160589 times)

jaz1974

  • Guest
Re: (!!!) Improving NGUI: Voice your opinion
« Reply #135 on: December 12, 2013, 07:32:29 PM »
http://www.youtube.com/watch?v=B66xhIvYF00&feature=c4-overview&list=UUQGZdUwzE8gmvgjomZSNFJg, around 32:40 mark I make it possible to drag & drop items out of a scroll view.

Fantastic stuff!!
Love these videos.   Keep up the great work.

Jaz

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: (!!!) Improving NGUI: Voice your opinion
« Reply #136 on: December 13, 2013, 05:50:20 AM »
Hello Michael,

I wish an improved UIpanel script that allow the user to nest a clipped panel in an other one, like a scroll view inside an other scroll view...

Cheers,

Hlx
Random thought just hit me.... this is already possible. You just need to use stencils. I'll see about adding a tutorial on this in the near future.

Cabal

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 1
  • Posts: 16
    • View Profile
Re: (!!!) Improving NGUI: Voice your opinion
« Reply #137 on: December 13, 2013, 10:39:39 AM »
One suggestion for tweens when you want to create an animation that, for instance, blinks three times and then stops: the UITweener class could a "count" variable that can be specified in the editor to tell NGUI how many times to play the given tween. The count parameter would be decremented every time the animation completes and the script would only disable itself when count reaches 0.

Example 1: blink three times
style = loop
count = 3

Example 2: fade in and out once
style = pingpong
count = 1

This would simplify creating simple tweens with predictable behaviors.

Thoughts?

Yukichu

  • Full Member
  • ***
  • Thank You
  • -Given: 3
  • -Receive: 8
  • Posts: 101
    • View Profile
Re: (!!!) Improving NGUI: Voice your opinion
« Reply #138 on: December 13, 2013, 01:57:40 PM »
All NGUI files should be able to compile inside of MonoDevelop. Things like default parameters in C# typically do not compile in Mono, even though they compile in Unity. I always test by building in Mono first to track down obvious errors and warnings, but now, I have to make sure to close NGUI files because some of them have errors.

Build with Unity.  Just switch windows to the Unity Editor and Unity will compile it.  I used to think 'make it compile in MonoDevelop' too for everything; however, handicapping the development of something because MonoDevelop doesn't support it... but Unity does... just makes no sense.  Use Visual Studio Express (it's free), or use Unity to compile things.  I only use Mono to attach a debugger for the rare times I need that functionality.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: (!!!) Improving NGUI: Voice your opinion
« Reply #139 on: December 13, 2013, 05:54:28 PM »
@Cabal: You can do all this by simply creating that pattern in the Curve field.

ryan

  • Jr. Member
  • **
  • Thank You
  • -Given: 0
  • -Receive: 1
  • Posts: 90
    • View Profile
Re: (!!!) Improving NGUI: Voice your opinion
« Reply #140 on: December 13, 2013, 07:54:40 PM »
I would love an event that we could hook into to be notified when a widget or rect's size and position have changed.  The new anchor system is great for making UI's the fit whatever screen dimensions you've got, but I have several cases where I want to do something more complicated within a particular region of the UI based on the space available.  This is stuff that I don't want to recalculate every frame, and I'd rather not have to poll to see if the widget has changed, either.

Maybe there's a more general solution that can work with the new anchor system to allow more powerful layouts to be created...

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: (!!!) Improving NGUI: Voice your opinion
« Reply #141 on: December 14, 2013, 12:39:52 PM »
Done. UIWidget.onChange is now in the Pro repo.

KirbyRawr

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 9
    • View Profile
Re: (!!!) Improving NGUI: Voice your opinion
« Reply #142 on: December 15, 2013, 02:10:57 PM »
New Validation system for UILabel , i created one specifically for input of the names, without symbols but with accents supports:

  1. else if (validation == Validation.NameWithSymbols)
  2.                 {
  3.                         char lastChar = (text.Length > 0) ? text[Mathf.Clamp(pos, 0, text.Length - 1)] : ' ';
  4.  
  5.        
  6.                         if (ch >= 'a' && ch <= 'z')
  7.                         {
  8.                                 // Space followed by a letter -- make sure it's capitalized
  9.                                 if (lastChar == ' ') return (char)(ch - 'a' + 'A');
  10.                                 return ch;
  11.                         }
  12.  
  13.                         else if(!(ch >= '0' && ch<= '9') && ch !='?' && ch !='!' && ch !='<' && ch !='>' && ch !='\u00BF'
  14.                                 && !(ch >= '\u007B' && ch <= '\u00BF') && !(ch >= '\u0020' && ch <= '\u0040') && ch != ' '
  15.                     && !(ch >= '\u02B0' && ch <= '\u036F')
  16.                                 && !(ch >= '\u005B' && ch <= '\u0060')){
  17.                         return ch;
  18.                         }
  19.                 }

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: (!!!) Improving NGUI: Voice your opinion
« Reply #143 on: December 15, 2013, 04:31:46 PM »
You can just set UIInput.onValidate to your custom validator. No need to modify UIInput itself.

kitgui

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 26
    • View Profile
Re: (!!!) Improving NGUI: Voice your opinion
« Reply #144 on: December 16, 2013, 02:42:13 PM »
Quote
- NEW: Enabling/disabling widgets no longer affects other panels.

Sweet! :D Thanks Mike

jsbanwjly

  • Guest
Re: (!!!) Improving NGUI: Voice your opinion
« Reply #145 on: December 17, 2013, 02:48:27 AM »
hi, i need repeated button.  process "onPressed".
thank you.

hlx

  • Newbie
  • *
  • Thank You
  • -Given: 1
  • -Receive: 0
  • Posts: 4
    • View Profile
Re: (!!!) Improving NGUI: Voice your opinion
« Reply #146 on: December 17, 2013, 04:41:38 AM »
... this is already possible. You just need to use stencils. I'll see about adding a tutorial on this in the near future.

Oh yes, please. I need some explanation since I would like masking a scroll bar (and his content) by a (high level) parent panel object. By stencil, I guess that you are talking about a texture widget that have an alpha channel that should be the parent of the hierarchy to mask. Am I right ?

ChrisR

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 33
    • View Profile
Re: (!!!) Improving NGUI: Voice your opinion
« Reply #147 on: December 17, 2013, 06:00:07 AM »
You might've already added these Aren (we're still on 3.0.5 ourselves, haven't been able to upgrade in a while) but this is some stuff we've found useful and added ourselves:

UIImage Button: added the option to set a disabled state sprite.
UIButton Color: added a disabled state colour.
UIPopupList: Added an option to adjust the speed of the TweenPosition and TweenColour.
UIPopupList: Added the option to offset the position of the popup box - to compensate for the sliced sprite bound.
UIToggle: Added a "Can be none" option when a toggle is part of a toggle group. For us, this was useful in avatar icon select - once a user had selected a picture, they weren't able to have no picture, so we added this to allow that.

UIInput: I think we added a custom validation type for Email. Not sure if it's clever enough to detect a bad email format, but it removes the illegal characters.

Minor things, but they were helpful!
« Last Edit: December 17, 2013, 06:24:37 AM by ChrisR »

ChrisR

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 33
    • View Profile
Re: (!!!) Improving NGUI: Voice your opinion
« Reply #148 on: December 17, 2013, 06:01:29 AM »
Random thought just hit me.... this is already possible. You just need to use stencils. I'll see about adding a tutorial on this in the near future.

Also I'd love to see a tutorial on this, when you get the time. :)

kitgui

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 26
    • View Profile
Re: (!!!) Improving NGUI: Voice your opinion
« Reply #149 on: December 17, 2013, 03:16:10 PM »
As far as I know, stencil buffering is disabled in unity free, but it can be simulated with the use of multiple cameras