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 - ChrisR

Pages: [1] 2 3
1
Aren: We also use "Handles" off mode exclusively, and use the Transform gizmo to constrain movement to one axis.

Bluescrn: Thanks a lot for this!

2
NGUI 3 Support / Re: Best NGUI hierarchy?
« on: December 17, 2013, 06:32:28 AM »
It's always tempting to have a general solution, but it's almost never the case. Unfortunately, life is too complicated for that. :)

3
NGUI 3 Support / Re: Create 3 tabs with imageButton
« on: December 17, 2013, 06:31:52 AM »
Fake it instead.

Add a UIImage Button and a UIToggle to the same object GameObject. Set a background to be the target of the UIImage button, add the right images. Then add a checkmark as a target of the UIToggle. The checkmark will be whatever you want your tabbed state to be.

Copy and paste the GameObject, and set all the UIToggles to the same toggle group.


4
NGUI 3 Support / Re: (!!!) Improving NGUI: Voice your opinion
« 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. :)

5
NGUI 3 Support / Re: (!!!) Improving NGUI: Voice your opinion
« 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!

6
NGUI 3 Support / Re: Best NGUI hierarchy?
« on: December 17, 2013, 05:51:29 AM »
That can be a big advantage as well, depending on what you need to achieve with certain UIs/UI elements.

There's no one 'best' solution for every case you come across. In our projects, we mix and match as necessary, and this is fine because everybody understands when we need to lay out our hierarchies in a particular way - they're not caught out by it. It's not something I'd recommend if people are less aware of what's going on with your UI, however.

7
NGUI 3 Support / Re: New fonts imported with an outline
« on: December 03, 2013, 06:02:53 AM »
Not quite!  You want the following settings:

A: Glyph
R: One 
G: One 
B: One


8
NGUI 3 Support / Re: ArgumentOutOfRangeException
« on: October 14, 2013, 04:50:49 AM »
I believe this error occurs when you have a sliced, tiled or filled sprite with a negative scale. (Usually done to mirror the graphic one an axis by artists.)

If you need to have a sprite inverted, you can use rotations instead of a negative scale.

9
NGUI 3 Support / Re: 3.0 UIPanel Depth/DrawCall Management
« on: October 02, 2013, 08:56:37 AM »
First off, thanks for taking all of this onboard Aren. And yes, that change does sound great.

Just a question (I assume the answer is yes, but just double checking) you will continue to provide support on NGUI 2.7.0 right?

Regarding a specific answer you had for me:

Quote
When instantiating prefabs inside a panel (for example objects inside a draggable panel), don't bring them to front.

If you need to adjust their depth, don't do so blindly. Drag & drop your prefab into where it's supposed to be instantiated in the UI hierarchy, adjust the depth there, then hit Apply. This way when you instantiate this prefab, it will already have the correct depth.

This works if the prefab only needs to be instantiated onto that specific panel. If the prefab gets used in multiple locations  - for example, an inventory of cards, but also a pack of cards, etc, then this becomes much more difficult to manage.

But it doesn't really matter, because I believe your change will fix my issues with this.

10
NGUI 3 Support / Re: 3.0 UIPanel Depth/DrawCall Management
« on: October 01, 2013, 07:26:16 AM »
I hope I won't step on any toes with this, but I'd just to help NGUI improve.

After using the new system for a couple of days, I have to agree with Farazel. While the new system is good in the sense it solves a problem that confused users before, the added effort that is necessary to keep draw calls down is turning out to be a big time consumer. It's harder for me to maintain a clear overview what's going on in the project, and building new UI elements is taking longer because I need to consider all other possible UI elements that are on screen at the same time.

It's also a big problem for dynamic interface elements. Before, I saved out root objects as prefabs (for example, Trading Cards), and we could instantiate these onto any other UI element. Now, we need to take that extra step of using BringForward a specific amount of times to make sure such a system doesn't balloon the draw calls to unacceptable levels. And this amount is dependent on the bit of UI the dynamic UI element will share the screen with. It just becomes confusing to keep track of it.

Making mistakes also impacts us more than before, because performance problems make it harder to test gameplay and code than visual errors.

Ferazels suggested some improvements, and I'd like to echo one in particular:

Quote
  • Make each UIPanel manage the draw call for the widgets under it like the prior system. It will not check/compare depths of widgets on other panels.

The first would solve all the issues that I currently have with the new system and make NGUI better than ever, I would think. :)

11
NGUI 3 Support / Re: NGUI Infinite Pickers - Now on the Asset Store
« on: September 24, 2013, 10:31:39 AM »
Hey Gregzo,

Do you know if this would work with NGUI 3.0.0, or if not, are you working on an update to make it compatible?

It looks great by the way. We just ran into the problem your tool solves today! Looking forward to using it. :)

12
Also, while I am working with this, I just noticed that the collider size is also determined by the generated label's dimensions. This might be something that you want the user to be able to set; as it should probably cover the entire width of the background sprite used when creating the pop-up list.


Edit: Width, not length.

13
NGUI 3 Support / Re: NGUI 3 upgrade feedback & questions
« on: September 24, 2013, 05:36:05 AM »
Obviously, I'm not Aren, but regarding scaling widgets - if you scale according to B) sliced, tiled and filled sprites won't adjust, meaning you get awkward stretching. And as you rightly pointed out, if you want to take advantage of nested widgets, you really don't want to scale like that.

You can still make uniform adjustments on B), just like you would use empty game objects as containers before. 

14
NGUI 3 Support / Creating Scrollable UIPopup List, used for "Select Country"
« on: September 24, 2013, 05:24:17 AM »
Hey all,

I'm currently creating a scenario editor for our game. One of the problems I'm encountering is that there's some options that have many different values, such as a list of countries that the designers want to show in a pop-up list.  For this to work, I'd need the pop-up list to be scroll-able, otherwise the available options would overflow the current screen size.

I've brainstormed some possible solutions for doing it from art, but they are unwieldy and not very elegant. (Example: Creating a clipped Panel with a sorted UIGrid containing text labels that are clickable and update the value of a given label.)

So I'm left looking at either designing the UI around it, or looking at a code solution. While the former is possible, it's not the most user friendly option in some anticipated cases - such as country select. So my questions are: A) Has anyone found a way to make scrollable pop-up lists? and B) Aren, is this something you have considered adding in the near future?

Thanks in advance for any help!

15
NGUI 3 Support / Re: 2.6.5 issue with label Shrink to fit.
« on: September 10, 2013, 04:03:05 AM »
Which problem should that solve?  I also could not find that line of code in UILabel...

If you don't comment this line out, the UILabel seems to disregard the font atlas pixel size. This is a problem when you're swapping out HD/SD textures, as one or the other will be half (if SD) or double (if HD) the scale you intend them to be.

Just commenting because I think Aren won't be around for a while.

Pages: [1] 2 3