Unity game working perfectly in Unity remote 5 but not functioning properly when built

157 Views Asked by At

My 2 player android Unity game is working just fine in Unity remote 5, I have a small minigame where there are multiple coloured tiles and coloured buttons and so to match a tile, u have to click the right button and as quick as possible before the other player, during start all the tiles are properly generated in Unity remote 5 but when the game is built and ran on my Nokia phone then there is just 1 tile that spawns I think and the other player's ones doesnt even spawn, that is just one issue, there are other issues in other games. Plus the first scene has a gameobject spinning, in Unity remote 5 it spins in a good speed but in build it spins super slow, like way too slow.

I made new Unity project and transferred everything there to see if it would work but it didn't. I also dont have any device-specific code I think, I have input.touch but that is becuz its an android game. I don't know what else to try, in the player/project settings, I have done IL2CPP for ARM64 and that is the only change I have made, what else could I change?

1

There are 1 best solutions below

9
On BEST ANSWER

Unity Remote 5 is not playing a build. it is just a mirror. therefore, if a game plays on editor it plays on Unity Remote 5 as well.

for other issues there might be several different problemes. Here I will share most common ones:

  • your PC's frame rate is different than your phone and each device can be different. Therefore you cannot relay on it. you have use "time.deltatime". example code:

    transform.Rotate(0, 0, degreesPerSecond * Time.deltaTime);

link for details

  • if your other player spawns in the Unity editor. its is spawning in the phone as well for sure. however most probably you are not using proper layers. I suggest you work on canvas and panel based. so you can easily sort them and give order when to show up when to hide.

probably your player stays behind an item see the attached image

image