0
\$\begingroup\$

I am using Unity to build a game that is going to be used on PC and Android mobile devices. The problem I have is that when I use a UI Button, it works perfectly on mobile, but on PC and in the editor, is not working.

Why could this be happening?

\$\endgroup\$

1 Answer 1

1
\$\begingroup\$

I found out why this is happening. I use player preferences to store some user settings, and after I tested the app a few times on my Android device, I decided to modify the script. The previous settings remain saved after the update, so it worked on mobile devices, but on the PC it was never used so there was no previous settings to work from.

\$\endgroup\$
1
  • \$\begingroup\$ It sounds like you did not actually build it to your phone (or alternatively, test it via Unity Remote) after your changes. It is always good to keep record of the version your actually testing from. \$\endgroup\$
    – Gnemlock
    Feb 2, 2017 at 0:26

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .