Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

In App Review Problem

Discussion in 'Scripting' started by gaishinbu, Aug 22, 2021.

  1. gaishinbu

    gaishinbu

    Joined:
    Oct 10, 2015
    Posts:
    64
    Hello!

    I called the function In App Review at level 6-20-30-40-50... in my game.First at level 6, The comment and star rating window opens. But if the player clicks the "Not Now" button and somehow closes the window without leaving comments and stars, In App Review doesn't work (not opening) anymore at other levels.

    I tried it on 3 different phones by deleting and reinstalling the game. Likewise, the problem persists.

    Code (CSharp):
    1. using System.Collections;
    2. using System.Collections.Generic;
    3. using UnityEngine;
    4. using Google.Play.Review;
    5.  
    6. public class appreview : MonoBehaviour
    7. {
    8.     private ReviewManager _reviewManager;
    9.     PlayReviewInfo _playReviewInfo;
    10.  
    11.     void Start()
    12.     {
    13.         _reviewManager = new ReviewManager();
    14.  
    15.         StartCoroutine(review());
    16.     }
    17.  
    18.     public IEnumerator review()
    19.     {
    20.         yield return new WaitForSeconds(1f);
    21.  
    22.         var requestFlowOperation = _reviewManager.RequestReviewFlow();
    23.         yield return requestFlowOperation;
    24.         if (requestFlowOperation.Error != ReviewErrorCode.NoError)
    25.         {
    26.             yield break;
    27.         }
    28.         _playReviewInfo = requestFlowOperation.GetResult();
    29.    
    30.         var launchFlowOperation = _reviewManager.LaunchReviewFlow(_playReviewInfo);
    31.         yield return launchFlowOperation;
    32.         _playReviewInfo = null;
    33.         if (launchFlowOperation.Error != ReviewErrorCode.NoError)
    34.         {
    35.             yield break;
    36.         }
    37.     }
    38. }


    The guide i used : https://developer.android.com/guide/playcore/in-app-review/unity

    Thank you.
     
  2. Adrian

    Adrian

    Joined:
    Apr 5, 2008
    Posts:
    1,051
    This is expected, Google has implemented a quota for how often the review dialog is shown and if you try open it more frequently, it will simply be ignored.

    In the documentation it says:
    The documentation on testing the in-app reviews has some details on how the quota can be ignored for testing the app.
     
    gaishinbu likes this.
  3. gaishinbu

    gaishinbu

    Joined:
    Oct 10, 2015
    Posts:
    64
    ""less than a month" ??? Really? Will it be shown only once in 1 month? I was wondering about the actual time. Thank you very much for your reply. I didn't know such a thing existed.