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.


Topics - Wumpee

Pages: [1]
1
NGUI 3 Support / NGUI Popup list on click instead of on press?
« on: March 19, 2017, 07:42:35 PM »
Would it be possible for you to add a mode to popup lists so that the item is selected on click rather than on press?

This functionality is desirable in many cases where you don't want mouse release events to fall through.

A simple toggle to select the mode of operation would be fantastic.

2
Why would the items in a popup menu be blank (not drawn) the first time you click on the popup?

I'm dynamically setting the values of the popup for an in-game inspector by setting the UIPopupList's items member, as well as calling Set to set the current item.

When I run and click the popup list, all options are blank. They appear to be there but not rendering. If I drill into the hierarchy and change the size of any one of the options however, they all suddenly appear. The same is true if I click the popup, then click off it, then click on it again.

This is really odd.

3
Hey Arenmook,

With the latest version of NGUI (3.11.1), we've noticed that UICamera.hoveredObject is no longer being set for objects in our world. We have a UICamera object on the second (World) camera and it's set to Event Type '3D World'.

Has something changed in the latest version of NGUI that may have affected this?

4
NGUI 3 Support / Strange dithering issue in UI
« on: December 18, 2015, 01:26:25 AM »
Hi Arenmook,

Have you come across this issue before?

It's happening for us intermittently and only happens on certain people's PCs.

Please refer to the attached image.

5
NGUI 3 Support / Dragging panel with embedded scroll view?
« on: October 04, 2015, 06:14:17 AM »
Hi, I have a couple of cases where I have a panel with an embedded scroll view, and when I drag the parent panel around, the scroll view hitches and looks bad.

Is there a particular way to set up something like this?

e.g. I have a Map with a title bar, which can be used to drag the entire map. The map itself can be scrolled around as it is much larger than the scroll view.

Panel_Map
- Title Bar (Has UIDragObject with Panel_Map as target)
- Panel (scroll view)
  - Texture (map)

This seems like a logical setup to me, but it just doesn't work nicely at all - it's like the panels are updating in the wrong order, or the scroll view isn't fully in local space.

6
NGUI 3 Support / UIPopupList item labels have a Z depth of -1
« on: July 30, 2015, 05:22:59 PM »
Hi, I was just wondering why the UIPopupList code puts the generated labels at a Z of -1?

I've noticed this causing issues. Some popup lists work, while others don't display their item labels all the time. Some times the labels will vanish the next time you click the popup.

Why is it being set to -1f in this code?

lbl.cachedTransform.localPosition = new Vector3(bgPadding.x + padding.x - lbl.pivotOffset.x, y, -1f);

7
NGUI 3 Support / UITextList issues with latest update
« on: July 05, 2015, 11:38:44 PM »
Hi,

With the latest version of UITextList, a static history has been added which broke our multiple tabbed chat windows.

Instead of using the control name for the dictionary key, would you be able to add a UniqueId field to the UITextList instead?


8
How should I best go about getting widgets to keep themselves visible (i.e. fully on-screen) when a user quits out and loads back in with a different screen resolution?

e.g. User places their character info widget in the top left corner of the screen while running the game at a 16:9 resolution, they exit the game, which saves the position and size of the widget. Then they reload the game in 4:3 - the widget now gets re-positioned to be off-screen, and is potentially irretrievable unless they change resolutions back.

Is there any functionality in place to snap a UIWidget based widget so that it is fully visible?

Or is there another way to be looking at this issue that I'm not considering? Obviously anchoring everything in place prevents this, but when you want the user to be able to move a widget / panel such as a chat window and have it remember the position, achoring doesn't appear to be ideal, except when they run the client the first time.

Is UIDragObject the only component with this functionality?

Also, why doesn't UIDragResize have a flag to prevent resizing past the screen bounds?

9
NGUI 3 Support / Prevent right mouse button from dragging UIDragObject
« on: November 26, 2014, 03:49:57 PM »
What is the correct way to prevent the right mouse button from dragging an object with a UIDragObject component on it?

10
NGUI 3 Support / Selecting UIInput field without text selection
« on: October 18, 2014, 07:46:42 PM »
How can I set a UIInput object as active and not have the text selected?

I am trying to set up a key binding for the / key so that when you press it, the input field is selected, and a slash is in the input field already so you can continue typing, but the / always comes up selected with the highlight on it, which I don't want.

Doing this following doesn't work as expected:

  1. var input = gameObject.GetComponent<UIInput>();
  2. input.value = "/";
  3. input.selectionStart = 1;
  4. input.selectionEnd = 1;

I want it so that when I press / I can continue typing rather than having to press Enter, then type "/help" etc.

11
NGUI 3 Support / Only rendering N characters in a Label?
« on: April 15, 2014, 09:04:57 PM »
Hi,

Is there a way to tell a UILabel to only render a certain number of characters? I'm wanting to set up a typewriter effect for cut-scene text which is right justified, and slowly growing the text parameter just doesn't cut it.

Even with left justified text it would be ideal to just be able to just render N characters so you don't get weird pops when a word wraps.

12
NGUI 3 Support / Cutting holes in sprites
« on: January 01, 2014, 08:48:54 PM »
Hi,

What would be the most effective way to cut a hole through a sprite?

We only really need to cut a rectangular hole at this stage, but I am interested in knowing if there is a good technique to cut arbitrary shapes out of sprites too.

13
NGUI 3 Support / Italic text
« on: February 27, 2013, 05:20:04 AM »
Hi ArenMook,

Is there a simple way that I could add italics support by shifting the top 2 vertices of each character to the right by a set number of pixels, or would that require some major changes?


14
NGUI 3 Support / Setting / Getting position of UIDraggablePanel
« on: February 22, 2013, 08:15:08 PM »
Hello,

We are using the UIDraggablePanel class along with UIGrid and UICenterOnChild for a horizontal list of photos.

What I am needing to do is find out the current index of the list, and also be able to set the current index of the list since the photos are split into categories (e.g. the first 4 are category 1, the next 3 are category 2 etc.).  There are category buttons on the screen (similar to a toggle button group), and these need to take you to the index of the first photo of that category.  Also, if you drag the panel around, it should automatically switch the category based on which photo is centered.

Do you know of a simple way to achieve this?

15
NGUI 3 Support / Bug in UIButtonOffset
« on: November 22, 2012, 07:35:36 PM »
There is a simple bug in UIButtonOffset which happens when you set the Duration to 0.\

A simple way to replicate this is to put 3 buttons in a row horizontally, set the Duration of the offset to 0 for each of them, then hover over button #2 and button #3.  The first time you hover over them, their label snaps to the position of button #1's label briefly (appears to last for 1 frame or so).

Pages: [1]