Description

By [Link Removed], user can disable IDFA without customizing engine code. But, if using Launcher build, the added settings( Enable Advertising Identified(IFFA) ) does NOT work correctly. Because engine code does not be compiled when using Launcher build. In other words, Change of project settings is not reflected to ENABLE_ADVERTISING_IDENTIFER

IOSPlatformMisc.cpp
FString FIOSPlatformMisc::GetUniqueAdvertisingId()
{
#if !PLATFORM_TVOS && ENABLE_ADVERTISING_IDENTIFIER
// Check to see if this OS has this function
if ([[ASIdentifierManager sharedManager] respondsToSelector:@selector(advertisingIdentifier)])
{
NSString* IdfaString = [[[ASIdentifierManager sharedManager] advertisingIdentifier] UUIDString];
FString IDFA(IdfaString);
return IDFA;
}
#endif
return FString();
}
UEBuildIOS.cs
if (ProjectSettings.bEnableAdvertisingIdentifier) { CompileEnvironment.Definitions.Add("ENABLE_ADVERTISING_IDENTIFIER=1"); }

As written on [Link Removed], We should move this function to engine plugin for Launcher build.

 

Steps to Reproduce
  1. Create C++ project using Launcher build
  2. Add code for checking IDFA
  3. Set Enable Advertising Identified(IFFA) of ProjectSettings to true
  4. Run on ios device and check IDFA ( result : display IDFA correctly )
  5. Set Enable Advertising Identified(IFFA) of ProjectSettings to false
  6. Run on ios device and check IDFA

or open attached project and do 3~6

expect : display nothing
result : display IDFA

Have Comments or More Details?

There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-76414 in the post.

4
Login to Vote

Won't Fix
ComponentUE - Platform - Mobile
Affects Versions4.22
CreatedJun 18, 2019
ResolvedAug 27, 2021
UpdatedAug 27, 2021
View Jira Issue