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

Pages: [1]
1
Hello, I have noticed that after you click a button in 3.7.6, the hover state is being called even though there is not a mouse cursor. 

I was able to reproduce this in unity 4.6 using the "Control Widgets" demo scene with the latest code pulled from github(12/5/2014).  After you click on the button, it stays highlighted until you click elsewhere in the scene.


2
NGUI 3 Support / Universal Apps build for windows phone
« on: December 02, 2014, 03:34:18 PM »
Hello, I have been migrating our project to the universal apps build for windows/metro, and i noticed that the UNITY_WP8 define doesn't work for the phone deployment(therefore it is missing some functionality like the onscreen keyboard).

I did a quick test, and it looks like if you replace UNITY_WP8 with (UNITY_WP8 || UNITY_WP_8_1) everything works as expected.  I don't think this causes any adverse effects, and I was unsure if the changes needed to be made in the ByteReader.cs and EventDelegate.cs files since the api's are now in sync between the arm/x86 builds. So I was wondering if you would take a look and add these defines for the next release.


Thank you,
Dylan

3
NGUI 3 Support / Clipping options missing in 3.6.2
« on: June 02, 2014, 01:54:09 PM »
Hello, I just noticed none of my scroll views are clipping after upgrading to 3.6.2(from 3.5).  I took a look, and there are now only 3 options:

None,
Soft Clip,
Constrain but dont clip.

Was a clipping option removed? 

Thank you,
Dylan

4
Hello,
In Ngui 3.5 i was able to do this:
EventDelegate.Add(tween.onFinished, () => { HideTweenFinished(); });

But now its throwing this error after i upgraded to 3.6:

Could not find method '<Hide>m__AC' on MissionSelectBase

It also throws errors when doing this:
EventDelegate.Add(tween.onFinished,  HideTweenFinished);

where HideTweenFinished is a private function. 

It looks like its trying to do reflection at this point.  Why wouldn't it just keep a handle to the original function? 

5
NGUI 3 Support / Huge mesh sizes
« on: February 21, 2014, 12:19:04 PM »
Hello.  We have just upgraded from NGUI 2.7 to 3.5.  Most of our app is almost entirely GUI driven and most of our scenes are entirely rendered by NGUI(No custom meshes).  We noticed a massive slowdown in our application when deployed to phones and did a little bit of research.  A scene that we have not changed except for upgrading to NGUI 3.5 now takes up an extra 200+ megs of memory.  Looking at the profiler and doing a before/after comparison, it looks like NGUI 3.5 is generating a massive amount of mesh data.

Ngui 2.7: 2mb of mesh data
Ngui 3.5 210mb of mesh data.

I wanted to add that we do use sliced sprites, but we do not use any tiled sprites in our app.  We do use a fair amount of text also, but both scenes (2.7 and 3.5 versions) are using the same sprites/data.

6
NGUI 3 Support / Odd drag panel behavior when tweening parent object.
« on: February 11, 2014, 03:38:37 PM »
Hello, I have a control structured like so:


MySettingsObject
    ScrollView
       Grid
          Item0
          Item1
          Item2
          etc

Item's are as follows:
ItemObject (with box collider)
    Sprite
    TextLabel

I am tweening "MySettingsObject" into the scene to slide in the panel.  When I do this, sometimes the Items are offset and not in their correct positions.(About 50 pixels off in the x direction).  Now here is the really odd part.  Neither of them have x values that are 50 pixels off(the inspector shows 0), and if i turn the object off/on again in the inspector it will draw them in the correct place. If i look at the Item's base object, its box collider is in the correct place, but it looks like the meshes for the sprite, and text are not being updated when moved until i disable/enable the game object.

Do you have any ideas?



7
NGUI 3 Support / Tweens sharing events?
« on: February 03, 2014, 12:32:41 PM »
Hello, I am currently doing two seperate animations for an open/close ui event, and I noticed that it seems events from previous tweens are being called even though I am doing a new Tween.Begin().

Note: Both tweens are not running at the same time, but are attached to the same root game object.

First Tween:
TweenPosition tween = TweenPosition.Begin(this.gameObject, 0.30f, new Vector3(0.0f, 615.0f, this.transform.localPosition.z));
EventDelegate.Add(tween.onFinished, HideTweenFinished);

Second Event:
TweenPosition tween = TweenPosition.Begin(this.gameObject, 0.30f, new Vector3(0.0f, 0.0f, this.transform.localPosition.z));
EventDelegate.Add(tween.onFinished, ShowTweenFinished);

After calling the first tween, the second tween will call both ShowTweenFinished, and HideTweenFinished when I would expect it to only call the event passed to it.  I am able to remedy the problem by calling Clear() on the event list for the specific tween, but this seems like a bug to me.

Thank you,
Dylan

8
NGUI 3 Support / Is an Incremental NGUI update possible?
« on: November 18, 2013, 02:46:14 PM »
Hello,
For our application we were relying heavily on NGUI for our 2d elements.  Our application consists of many mulitlayered UIs with various animation aspects to each one which will make updating from 2.7 to 3.x take quite a while per scene.  I was wondering if there was a way we could run both versions side by side and update to the new version on a per scene basis? 

Off the top of my head I would think that renaming all of the 2.7 files to something like UIOLD (UISprite -> UIOLDSprite) would work, but we would need to then update all of the prefabs(we have quite a few).  Is there any way we could automate updating the prefabs?  Or do you have any suggestions about what we could do?

Thank you,
Dylan

9
NGUI 3 Support / UITexture or UISprite for runtime images?
« on: October 02, 2013, 10:22:23 AM »
In our application we load a lot of images from a web service and display them at runtime.  We are currently using UISprite which requires them to be packed into atlases, but I was wondering if there would be any large downside to switching to using UITexture since the atlas packing seems to add quite a bit of slowdown on older devices.  Will a UITexture display on all devices even if the source Texture2d is not a power of two? 

10
Hello, I am trying to make my list of items on a drag panel stop/center on an item depending on how fast someone flicked the scroll-able area.

I am wondering if there is a way for me to calculate how far the panel will scroll when someone releases a touch(so i could then modify the momentum to stop on the correct position).  I have been looking at the spring dampen code, but I am rusty on my spring physics and I am unsure on how to calculate this.  Has anyone else come up with a solution they would be willing to share?

Thank you,
Dylan

11
NGUI 3 Support / RegisterSceneUndo obsolete in unity alphas
« on: August 26, 2013, 10:53:25 AM »
 
Hello, I am getting the error:
`UnityEditor.Undo.RegisterSceneUndo(string)' is obsolete: `Please use DestroyObjectImmediate, RegisterCreatedObjectUndo or RegisterUndo instead.'

Do you know what the suggested replacement would be? I am not super familiar with the Undo functionality.

12
NGUI 3 Support / Best Container for UIAnchor
« on: June 27, 2013, 04:08:11 PM »
Hello, I was wondering what the suggestion would be for the best container for a UIAnchor in the following scenario.

We are creating full screen layouts which we want to tween in/out of the scene.  These layouts include controls that will anchor to the various edges of the layout based on the screen size. (We are instantiating layouts for the current screen resolution off the screen)  If we use the camera as the bounds, we can't instantiate the items off screen and fly them in.  The UIPanel requires clipping, which I don't believe we require in this instance, and we don't want to display any widgets as the container.

I have updated the UIAnchor script to allow you to anchor items "relative to the parent" which will anchor items as if they were in the bounds of the screen, but are movable as a whole from the parent object. This works, but I would like to stick to what the library intended.

What would be the suggested approach to accomplish this?  Create a UISprite that is the same size as the screen and use it as the bounding rectangle?

Edit: I am thinking of using a simple UIScreenSize class which inherits from UIWidget and has an OnStart() like the following:

  1.         void Start()
  2.         {
  3.                 if (uiCamera == null)
  4.                 {
  5.                         uiCamera = NGUITools.FindCameraForLayer(gameObject.layer);
  6.                 }
  7.                
  8.                 Rect pixelRect = uiCamera.pixelRect;
  9.                
  10.                 this.gameObject.transform.localScale = new UnityEngine.Vector3(pixelRect.width, pixelRect.height, 0.0f);
  11.         }


Thank you,
Dylan

13
Hello, We are using NGUI for making a UI that has multiple layers and are running into problems with the way it renders items.  Currently we have a scene that uses multiple atlases for the elements, and displays text on multiple layers(think popups over the main ui).  On the popup, Some text will not render. I have changed the z order as well as the actual z value.    I am assuming that these items are being rendered in one pass and hidden underneath the other items attached to another atlas.  Is there a way I can turn off the atlas draw batching?  I am not super concerned with the number of draw calls at this point as we are not doing anything that would tax the graphics processor.  I do not want to add the fonts to every layer's atlas as this would take up a ton of additional memory.

Thank you,
Dylan

14
Hello,
I have been using NGUI pro with my current project and found out that the input widget does not seem to be working correctly in OSX. This can be reproduced by deploying the "Tutorial 9" scene to the OSx web player(it works correctly in the editor).  I have also tested this on the windows web player and it works as expected.   I have done a couple of tests, and the unity web player(in OSx) is receiving the key presses, but is not displaying anything.

Has anyone else run into this, or know a solution? 

I plan on digging into the code to pinpoint the issue, but I wanted to see if anyone else knew how to fix this.

Thank you,
Dylan

Pages: [1]