Tasharen Entertainment Forum

Support => NGUI 3 Support => Topic started by: Alessaint on May 04, 2012, 03:03:46 AM

Title: Position/scale refresh in editor
Post by: Alessaint on May 04, 2012, 03:03:46 AM
Hi,

I'm experiencing  quite a strange behavior.

I have a pretty simple GUI - panel with two anchors (TL and TR) both with several child widgets. If I change resolution / aspect of the game window in editor the widgets may become clipped etc. So I run the game, they refresh and are positioned/scaled correctly.

I stop the game and they return to wrong position/scale. I press play again, they refresh and now, when I stop the game, they remain positioned correctly.

In another words - after I change size/aspect of the game window I need to press Play twice in order for the widgets to show correctly in editor.

It's not really a serious problem ... I find it interesting though :)

Ales
Title: Re: Position/scale refresh in editor
Post by: ArenMook on May 04, 2012, 08:09:21 AM
It's an issue in the Unity editor, it doesn't send updates after the resolution changes. You can achieve the same effect without pressing Play though. Simply click on the game window or hit Ctrl+S twice.
Title: Re: Position/scale refresh in editor
Post by: Alessaint on May 04, 2012, 01:30:25 PM
Oh, I see. Good to know, thanks.

Ales