iOS에서 인터스티셜 광고 구현
Implement interstitial ads in your iOS app. Load ad content, display it through Objective-C or Swift code, and use a delegate to handle ad events.
읽는 시간 1 minute최근 업데이트: a day ago
show
UnityAdsShowDelegate
다음 단계: iOS에서 보상형 광고 구현 기술 자료를 참조하여 구현 사항을 개선하십시오.// Implement a button that calls the show method when clicked: #pragma mark : Buttons - (IBAction)showInterstitialButton:(UIButton *)sender { [UnityAds show:self placementId:@"Interstitial_iOS" showDelegate:self]; } // Implement callbacks for events related to the show method: #pragma mark: UnityAdsShowDelegate - (void)unityAdsShowComplete:(NSString *)placementId withFinishState:(UnityAdsShowCompletionState)state { NSLog(@" - UnityAdsShowDelegate unityAdsShowComplete %@ %ld", placementId, state); } - (void)unityAdsShowFailed:(NSString *)placementId withError:(UnityAdsShowError)error withMessage:(NSString *)message { NSLog(@" - UnityAdsShowDelegate unityAdsShowFailed %@ %ld", message, error); // Optionally execute additional code, such as attempting to load another ad. } - (void)unityAdsShowStart:(NSString *)placementId { NSLog(@" - UnityAdsShowDelegate unityAdsShowStart %@", placementId); } - (void)unityAdsShowClick:(NSString *)placementId { NSLog(@" - UnityAdsShowDelegate unityAdsShowClick %@", placementId); }