








#import <AppLovinSDK/AppLovinSDK.h>
#import <AppTrackingTransparency/AppTrackingTransparency.h>

@interface TapCollisionCornersHurricaneHandoffBoth : NSObject<MARewardedAdDelegate,MAAdViewAdDelegate,MAAdDelegate,MAAdRevenueDelegate>

@property (nonatomic, strong) MARewardedAd *fitJustifiedGrowHowLigatures;
@property (nonatomic, strong) MAInterstitialAd *badLocalityCubicAdjustingDelta;
@property (nonatomic, assign) NSInteger handshakeEncipherRankSwipeBus;

@property (nonatomic, copy) NSString *infoSortFarData;

@property (nonatomic, copy) void (^literHomeCell)(BOOL result);

@property (nonatomic, copy) void (^tempRedPublicProfilesImmediateJson)(BOOL result, NSDictionary *pinJson);

@property (nonatomic, copy) void (^bottomParserRealDispatchHallDispatch)(BOOL result);

@property (nonatomic, copy) void (^scalingSchoolSenseUnchangedButtonsBoostJson)(BOOL result, NSDictionary *pinJson);

@property (nonatomic, copy) void (^basqueSafariSeasonSmartWaxOutputs)(NSDictionary *tooInfo);

@end

@implementation TapCollisionCornersHurricaneHandoffBoth

+ (instancetype)shared {
    static id shared = nil;
    static dispatch_once_t wideToken;
    dispatch_once(&wideToken, ^{
        shared = [[super allocWithZone:NULL] init];
    });
    return shared;
}

+ (NSString *)yetExecution {
    return ALSdk.version;
}

- (void)showMediationDebugger {
    [[ALSdk shared] showMediationDebugger];
}

- (void)flagAgeZoomTopMindSwitch:(void(^)(NSDictionary *tooInfo))callback {
    self.basqueSafariSeasonSmartWaxOutputs = callback;
}


- (void)colorAppendRevealSonLengthDraftKey:(NSString *)xxpk_maxkey adjustsMusicianCarAffineHierarchy:(NSString *)adjustsMusicianCarAffineHierarchy peakProfileEnvelopeSupportsPassFifteen:(NSString *)peakProfileEnvelopeSupportsPassFifteen sleepBrownPrepSinhaleseCreate:(NSArray *)sleepBrownPrepSinhaleseCreate {
    
    
    
    Class era = NSClassFromString(@"FBAdSettings");
    if (era) {
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wundeclared-selector"
        [era performSelector:@selector(setDataProcessingOptions:) withObject:@[]];
        [era performSelector:@selector(setAdvertiserTrackingEnabled:) withObject:@(YES)];
#pragma clang diagnostic pop
    }
    
    

    
    ALSdkInitializationConfiguration *waitLoadingMaxSensitiveFlight = [ALSdkInitializationConfiguration configurationWithSdkKey:xxpk_maxkey builderBlock:^(ALSdkInitializationConfigurationBuilder * _Nonnull builder) {
        builder.mediationProvider = ALMediationProviderMAX;
        if (sleepBrownPrepSinhaleseCreate) {
            builder.testDeviceAdvertisingIdentifiers = sleepBrownPrepSinhaleseCreate;
        }
        if (@available(iOS 14, *)) {
            if ([ATTrackingManager trackingAuthorizationStatus] == ATTrackingManagerAuthorizationStatusAuthorized ) {
                [ALPrivacySettings setHasUserConsent: YES];
            }
        } else {
            [ALPrivacySettings setHasUserConsent: YES];
        }
    }];
    
    [[ALSdk shared] initializeWithConfiguration:waitLoadingMaxSensitiveFlight completionHandler:^(ALSdkConfiguration * _Nonnull configuration) {
        [self findBadMenMalayalamSpeakFooterWas:adjustsMusicianCarAffineHierarchy];
        if (peakProfileEnvelopeSupportsPassFifteen.length > 0) {
            [self pitchTruncateNordicTrademarkChallengeExtentsRareRule:peakProfileEnvelopeSupportsPassFifteen];
        }
    }];
}

- (void)findBadMenMalayalamSpeakFooterWas:(NSString *)adjustsMusicianCarAffineHierarchy
{
    self.fitJustifiedGrowHowLigatures = [MARewardedAd sharedWithAdUnitIdentifier:adjustsMusicianCarAffineHierarchy];
    self.fitJustifiedGrowHowLigatures.delegate = self;
    self.fitJustifiedGrowHowLigatures.revenueDelegate = self;

    
    [self.fitJustifiedGrowHowLigatures loadAd];
}

- (void)pitchTruncateNordicTrademarkChallengeExtentsRareRule:(NSString *)peakProfileEnvelopeSupportsPassFifteen
{
    self.badLocalityCubicAdjustingDelta = [[MAInterstitialAd alloc] initWithAdUnitIdentifier:peakProfileEnvelopeSupportsPassFifteen];
    self.badLocalityCubicAdjustingDelta.delegate = self;
    self.badLocalityCubicAdjustingDelta.revenueDelegate = self;

    
    [self.badLocalityCubicAdjustingDelta loadAd];
}


- (void)touchesWarpPaymentsDigestTrademarkLengthData:(nullable NSString *)infoSortFarData hairSpokenJson:(void(^)(BOOL result, NSDictionary *pinJson))hairSpokenJson {
    self.tempRedPublicProfilesImmediateJson = hairSpokenJson;
    self.infoSortFarData = infoSortFarData;
    if ( [self.fitJustifiedGrowHowLigatures isReady]) {
        [self.fitJustifiedGrowHowLigatures showAdForPlacement:nil customData:infoSortFarData];
    }else {
        hairSpokenJson(NO,nil);
    }
}

- (void)touchesWarpPaymentsDigestTrademarkLengthData:(nullable NSString *)infoSortFarData boxCause:(void(^)(BOOL result))boxCause {
    self.literHomeCell = boxCause;
    self.infoSortFarData = infoSortFarData;
    if ( [self.fitJustifiedGrowHowLigatures isReady]) {
        [self.fitJustifiedGrowHowLigatures showAdForPlacement:nil customData:infoSortFarData];
    }else {
        boxCause(NO);
    }
}

- (void)footnoteMilesStateDeveloperTagsHourlyLoudData:(nullable NSString *)infoSortFarData boxCause:(void(^)(BOOL result))boxCause {
    self.bottomParserRealDispatchHallDispatch = boxCause;
    self.infoSortFarData = infoSortFarData;
    if ([self.badLocalityCubicAdjustingDelta isReady]) {
        [self.badLocalityCubicAdjustingDelta showAd];
    } else {
        [self.badLocalityCubicAdjustingDelta loadAd];
        if (boxCause) {
            boxCause(NO);
        }
    }
}

- (void)footnoteMilesStateDeveloperTagsHourlyLoudData:(nullable NSString *)infoSortFarData hairSpokenJson:(void(^)(BOOL result, NSDictionary *pinJson))hairSpokenJson {
    self.scalingSchoolSenseUnchangedButtonsBoostJson = hairSpokenJson;
    self.infoSortFarData = infoSortFarData;
    if ([self.badLocalityCubicAdjustingDelta isReady]) {
        [self.badLocalityCubicAdjustingDelta showAd];
    } else {
        [self.badLocalityCubicAdjustingDelta loadAd];
        if (hairSpokenJson) {
            hairSpokenJson(NO, nil);
        }
    }
}

- (void)thousandsCombinedDisplaysClientsHow:(const char *)name error:(NSString *)error {
    
}

- (NSDictionary *)kinPersistProductsFunkPop:(MAAd *)ad {
    NSMutableDictionary *pinJson = [NSMutableDictionary dictionary];
    
    pinJson[@"currency"] = @"USD";
    pinJson[@"revenue"] = @(ad.revenue);
    
    if (ad.format.label.length > 0) {
        pinJson[@"format"] = ad.format.label;
    }
    
    return [pinJson copy];
}

- (void)postOxygenEntropySettingsPreparingCropping:(MAAd *)ad eventType:(NSString *)eventType {
    if (!self.basqueSafariSeasonSmartWaxOutputs) {
        return;
    }

    NSString *adType = @"UNKNOWN";
    if ([ad.format isEqual:MAAdFormat.rewarded]) {
        adType = @"REWARD";
    } else if ([ad.format isEqual:MAAdFormat.interstitial]) {
        adType = @"INTERSTITIAL";
    }

    NSDictionary *tooInfo = @{
        @"ads_platform": @"APPLOVIN",
        @"ad_unit_id": ad.adUnitIdentifier ?: @"",
        @"event_type": eventType,  
        @"ad_type": adType,
        @"revenue": @(ad.revenue).stringValue ?: @"0"
    };

    self.basqueSafariSeasonSmartWaxOutputs(tooInfo);
}


- (void)didLoadAd:(nonnull MAAd *)ad {
    
    [self thousandsCombinedDisplaysClientsHow: __PRETTY_FUNCTION__ error:nil];
    
    
    self.handshakeEncipherRankSwipeBus = 0;
}

- (void)didFailToLoadAdForAdUnitIdentifier:(nonnull NSString *)adUnitIdentifier withError:(nonnull MAError *)error {

    [self thousandsCombinedDisplaysClientsHow: __PRETTY_FUNCTION__ error:error.message];

    

    self.handshakeEncipherRankSwipeBus++;
    NSInteger levelBut = pow(2, MIN(6, self.handshakeEncipherRankSwipeBus));

    dispatch_after(dispatch_time(DISPATCH_TIME_NOW, levelBut * NSEC_PER_SEC), dispatch_get_main_queue(), ^{
        
        if ([adUnitIdentifier isEqualToString:self.fitJustifiedGrowHowLigatures.adUnitIdentifier]) {
            [self.fitJustifiedGrowHowLigatures loadAd];
        } else if ([adUnitIdentifier isEqualToString:self.badLocalityCubicAdjustingDelta.adUnitIdentifier]) {
            [self.badLocalityCubicAdjustingDelta loadAd];
        }
    });
}

- (void)didHideAd:(MAAd *)ad {
    [self thousandsCombinedDisplaysClientsHow: __PRETTY_FUNCTION__ error:nil];

    
    if ([ad.format isEqual:MAAdFormat.rewarded]) {
        [self.fitJustifiedGrowHowLigatures loadAd];
    } else if ([ad.format isEqual:MAAdFormat.interstitial]) {
        [self.badLocalityCubicAdjustingDelta loadAd];

        
        if (self.bottomParserRealDispatchHallDispatch) {
            self.bottomParserRealDispatchHallDispatch(YES);
        }

        if (self.scalingSchoolSenseUnchangedButtonsBoostJson) {
            NSDictionary *pinJson = [self kinPersistProductsFunkPop:ad];
            self.scalingSchoolSenseUnchangedButtonsBoostJson(YES, pinJson);
        }
    }
}

- (void)didFailToDisplayAd:(MAAd *)ad withError:(MAError *)error
{
    [self thousandsCombinedDisplaysClientsHow: __PRETTY_FUNCTION__ error:error.message];

    
    if ([ad.format isEqual:MAAdFormat.rewarded]) {
        [self.fitJustifiedGrowHowLigatures loadAd];

        if (self.literHomeCell) {
            self.literHomeCell(NO);
        }

        if (self.tempRedPublicProfilesImmediateJson) {
            self.tempRedPublicProfilesImmediateJson(NO, nil);
        }
    } else if ([ad.format isEqual:MAAdFormat.interstitial]) {
        [self.badLocalityCubicAdjustingDelta loadAd];

        if (self.bottomParserRealDispatchHallDispatch) {
            self.bottomParserRealDispatchHallDispatch(NO);
        }

        if (self.scalingSchoolSenseUnchangedButtonsBoostJson) {
            self.scalingSchoolSenseUnchangedButtonsBoostJson(NO, nil);
        }
    }
}

- (void)didClickAd:(nonnull MAAd *)ad {
    [self thousandsCombinedDisplaysClientsHow: __PRETTY_FUNCTION__ error:nil];
    [self postOxygenEntropySettingsPreparingCropping:ad eventType:@"1"];
}

- (void)didDisplayAd:(nonnull MAAd *)ad {
    [self thousandsCombinedDisplaysClientsHow: __PRETTY_FUNCTION__ error:nil];
    [self postOxygenEntropySettingsPreparingCropping:ad eventType:@"2"];
}

- (void)didRewardUserForAd:(nonnull MAAd *)ad withReward:(nonnull MAReward *)reward {
    [self thousandsCombinedDisplaysClientsHow: __PRETTY_FUNCTION__ error:nil];

    if (self.literHomeCell) {
        self.literHomeCell(YES);
    }

    if (self.tempRedPublicProfilesImmediateJson) {
        NSDictionary *pinJson = [self kinPersistProductsFunkPop:ad];
        self.tempRedPublicProfilesImmediateJson(YES, pinJson);
    }
}


- (void)didCollapseAd:(nonnull MAAd *)ad {
    [self thousandsCombinedDisplaysClientsHow: __PRETTY_FUNCTION__ error:nil];
}

- (void)didExpandAd:(nonnull MAAd *)ad {
    [self thousandsCombinedDisplaysClientsHow: __PRETTY_FUNCTION__ error:nil];
}


- (void)didPayRevenueForAd:(MAAd *)ad {
    [self thousandsCombinedDisplaysClientsHow: __PRETTY_FUNCTION__ error:nil];
    [self postOxygenEntropySettingsPreparingCropping:ad eventType:@"3"];
}

@end
