Skip to content

ATTracking ad tracking permission (required) ​

effect ​

This is the new policy of iOS14, the policy on the control of advertising identifiers. In order to adapt to this policy, a simple and convenient api is provided for you to use.

be careful ​

1. iOS15 and SDK marketing data related Notes To ensure that the permission request works properly, you need to have a method to connect to the didFinishLaunchingWithOptions and applicationDidBecomeActive of the GamedreamerSDK,And the permission request is called after the two methods are triggered.
2. Relevant Notes on iOS System Library AppTrackingTransparency

  1. When using our dynamic sdk, there is no need to add the dependency of AppTrackingTransparency to the project, because the sdk has already dynamically linked the system Library at the bottom.
  2. When using our static sdk, we need to add the dependency of AppTrackingTransparency to the project and configure the required to option accordingly.

Function ​

objective-c
- (void)gamedreamerATTrackingWithWeakTip:(int)count andCompletion:(void(^)(int status))completion;

Parameter ​

Parameter nameEmpty (Yes/No)explain
countNoThe number of weak prompts: if it is 0, no weak prompts will be displayed, only the system pop-up box will be displayed.
completionYesCallback of permission application result

Round ​

Parameter nameexplain
status0: permission application failed; 1: permission application succeeded; 2: The system does not support ios14idfa

Example code ​

objective-c
- (void)applicationDidBecomeActive:(UIApplication *)application {
    
    [[GamedreamerManager shareInstance] applicationDidBecomeActive:application];
    
    if (!isFirstActive) {
// If the requirement is to only pop up the box once each time the application is opened, please add a restriction to allow one time, because applicationDidBecomeActive will trigger each time the application is active.
        isFirstActive = true;
        [[GamedreamerManager shareInstance] gamedreamerATTrackingWithWeakTip:0 andCompletion:^(int status) {
        }];
    }
}