Search Unity

Bug Game Stops doing Anything on Android when targetFrameRate is set above 60 fps

Discussion in 'Android' started by SchmendrickTheWizard, Apr 11, 2023.

  1. SchmendrickTheWizard

    SchmendrickTheWizard

    Joined:
    Jan 13, 2023
    Posts:
    7
    Hey there,

    We are currently experiencing following very strange behavior on android:
    we have set the targetFrameRate to 60 instead of the default 30 and since then on some devices we expierence a weird freeze where the game just stops doing anything (No Animations Playing, not responding to input) and stays in this state. This appears at random times. On some devices more often than on others. It also doenst seem to be an issue with older devices, because the older devices seem to dont have the issue that often, on some we never have experienced it.

    We also tried to change the targetFrameRate to 90, where it doesnt appear as often as with targetFrameRate 60 but it still happens. On targetFrameRate 120 we havent experienced it until now.

    It also only happens with the production build. On the development build, the issue isnt there.
    I also tried to disable Optimized Frame Pacing but it helped nothing

    Does anyone have an Idea what could be the Problem?
     
  2. giantkilleroverunity3d

    giantkilleroverunity3d

    Joined:
    Feb 28, 2014
    Posts:
    383
    I am experiencing crashes on my Moto as a dev too. You sparked a thought. Could it be the device game optimizer on some devices? I have that running on my phone and the screen does dim for game sessions.
    Just a thought.
     
  3. SchmendrickTheWizard

    SchmendrickTheWizard

    Joined:
    Jan 13, 2023
    Posts:
    7
    Yes, I checked this out, sadly it hasnt helped turning off the game optimizer. I also tried an empty scene with just a rotating cube in the same project, but there die freeze doesnt appear.
     
  4. SchmendrickTheWizard

    SchmendrickTheWizard

    Joined:
    Jan 13, 2023
    Posts:
    7
    The project is on unity version 2022.2.14f1
     
  5. SchmendrickTheWizard

    SchmendrickTheWizard

    Joined:
    Jan 13, 2023
    Posts:
    7
    I have new Insights regarding this Issue:
    First of all I tested if the issue also appears in a build with a near empty scene and just a rotating cube, but in the same project, so I can be sure, that the same Unity settings are active. There the Issue doesnt seem to appear, so I am guessing that there is a need for some load on the cpu for the issue to appear.

    Second, as i wrote above, when doing a development build, the freeze dont happen. So I triefd just setting the
    DEVELOPMENT_BUILD symbol manualy but make a production build and the issue vanished again.
     
  6. pablo_leban

    pablo_leban

    Joined:
    Sep 19, 2013
    Posts:
    68
    Hey! Have you found any solution to this issue?