Author Topic: Button colliders in different position for some Windows Phone devices.  (Read 2955 times)

roberto_sc

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 25
    • View Profile
Hi ArenMook

I'm porting a game to Windows Phone and it uses NGUI 2.6.4. I really tried to upgrade but the effort for this is huge - it's worse because we didn't do the game so I don't know the game code well.

I'm experiencing a bug that you fixed in a newer version: for some Windows Phone devices (I guess the high resolution ones, like Lumia 1520), the widget colliders seem to have an offset in relation to the widget itself. For exemple, I have a button in the center of the screen but I have to tap in the right corner to click it.

Can you please guide me on where I should change to fix this? I can compare this old version with the newest and redo the changes, but I don't know where to start.

Thank you.

roberto_sc

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 25
    • View Profile
Nevermind, this was an Unity bug that they fixed but there was a regression in 4.5RC1.
Input.mousePosition reports wrong coordinates.

konsnos

  • Newbie
  • *
  • Thank You
  • -Given: 8
  • -Receive: 0
  • Posts: 26
    • View Profile
Re: Button colliders in different position for some Windows Phone devices.
« Reply #2 on: September 12, 2014, 04:21:03 PM »
Hello,
sorry to revive such an old thread. Running an app from a build for Windows Phone at Visual Studio, on Emulator 8.1 1080P 5.5 inch has the same result. Colliders are positioned at a lower position. This doesn't seem to be the case for any other versions of the app, or the smaller screen size emulators. Nokias 1520 are affected by this, while others eg. 630 are not.
Unity version 4.5.4.
« Last Edit: September 12, 2014, 04:27:13 PM by konsnos »

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Button colliders in different position for some Windows Phone devices.
« Reply #3 on: September 13, 2014, 03:36:30 AM »
You should report this to Unity if that's the case. Regression bugs like these tend to get fixed quickly.

I suggest creating a simple repro case for them though -- something that just prints the touch position.

konsnos

  • Newbie
  • *
  • Thank You
  • -Given: 8
  • -Receive: 0
  • Posts: 26
    • View Profile
Re: Button colliders in different position for some Windows Phone devices.
« Reply #4 on: September 13, 2014, 07:27:14 AM »
You should report this to Unity if that's the case. Regression bugs like these tend to get fixed quickly.

I suggest creating a simple repro case for them though -- something that just prints the touch position.
Hm, I'm not sure if it's a Unity bug. What can I test to pinpoint it? As far as I understand it the colliders aren't in the correct position.

If I find that this is a bug, can I send the bug report with NGUI code? I'm not sure if I can help them much since I haven't looked at it and don't know how it works.

konsnos

  • Newbie
  • *
  • Thank You
  • -Given: 8
  • -Receive: 0
  • Posts: 26
    • View Profile
Re: Button colliders in different position for some Windows Phone devices.
« Reply #5 on: September 13, 2014, 01:28:58 PM »
I tried to replicate the bug, but I couldn't. Also the new Unity GUI seems to have the same problem in my project but not in an empty one. Seems that the problem exists only on my current project and only on 1080P :-S
What could possibly go wrong? What can I check?

I'll keep testing things...

konsnos

  • Newbie
  • *
  • Thank You
  • -Given: 8
  • -Receive: 0
  • Posts: 26
    • View Profile
Re: Button colliders in different position for some Windows Phone devices.
« Reply #6 on: September 13, 2014, 06:38:51 PM »
Sorry for the triple post. Found the problem and reported it. Here is the bug report to anyone having the same problem.