⬆️ ⬇️

I haven't taken checkers for a long time. Know, know how you play

The situation in the appStore for casual developers is changing rapidly.

2 years ago it was possible to earn by releasing a paid application at the same time as a free counterpart.

After the appearance of more than 100,000 programs in the store, this trick became ineffective.

A year ago, nimble guys began to lay out only free applications, but with purchases inside.

At the same time, the number of programs in the appStore exceeded 500,000.

In the near future (judging by the financial statements of 2012), only advertising inside the application will bring quick money.







Until last year, I used Apple’s branded advertising.

However, native iAd advertising works exclusively on the territory of the enemy.

To get money from players who do not live in the United States (which is at least 25%), you should screw ads from, say, Google, which will flicker where iAd does not work.

')

Under habracut, I will describe the AdWhirl mechanism that implements the display of banners from different manufacturers.

Sample code is taken from the immortal game of our beautiful childhood.







10 developer steps



Step times
Register a new application in tuna .

Do not forget to click the Set Up iAd Network button.

At the output, we get the Apple ID of the application and a link to the program in tuna.



Step two
Go to the Google AdMob website.

Click the Add site / app button, start an advertising campaign, for this we use the name of the application, a link to the application in tuna, for example, like this one and the Apple ID of the application from the first step. As a result, we obtain the adMob Advertising ID and download adMob SDK for iPhone / iPad.



Step three
Go to the site AdWhirl . Click the Add Application button, enter the application name and link in the fields. We include advertising companies iAd and adMob, for which we use Apple ID applications for iAd and advertising company ID for adMob. We set the advertisement update time (at least 15 seconds) and get the adWhirl ID of the company and a link to the adWhirl SDK for iPhone at the output.



Step four
Download adMob SDK, unpack and add the directory to the project of our application. Mouse.



Step five
Download adWhirl SDK, unpack and add the directory to the project of our application. Again with the mouse. Go to the adWhirl SDK directory, go to the C-files and throw away everything except the letters iAd and adMob in their names. Otherwise, the project will cease to be collected.



Step six
We add in application necessary for display of advertizing of library - frameworks. There are about 7 of them, the full list is contained in the readme file downloaded with the SDK. The libraries will include iAd.framework, sqlite3.lib, MessageUI.framework and others.



Step seven
Add text to the header of our main ViewController class



// ViewController.h // chapay // // Created by vadim bashurov on 22.01.12 // #import <UIKit/UIKit.h> #import "AdWhirlDelegateProtocol.h" // @class AdWhirlView; // @interface ViewController : UIViewController <AdWhirlDelegate> { AdWhirlView *adView; } // @property (nonatomic,retain) AdWhirlView *adView; - (void)adjustAdSize; @end 




The text is simple, the only ambush - I can not put an angle bracket, Habr eats it.

AdWhirlView is the element where the ads will run .



Our task is only to place AdWhirlView in such a place on the screen so that it is clicked more often. Rr-time and cent on our account. A million clicks - a million cents. OK, no?



Step eight
Add another text to the body of our main ViewController class.



 // ViewController.m // chapay // // Created by vadim bashurov on 22.01.12. // #import "ViewController.h" #import "AdWhirlView.h" //#import <iAd/iAd.h> @implementation ViewController @synthesize adView; // - (void)viewDidLoad { [super viewDidLoad]; self.adView = [AdWhirlView requestAdWhirlViewWithDelegate:self]; self.adView.autoresizingMask = UIViewAutoresizingFlexibleLeftMargin|UIViewAutoresizingFlexibleRightMargin; [self.view addSubview:self.adView]; } // #pragma mark AdWhirl - (NSString *)adWhirlApplicationKey { return @"6492f291f2214227a0af9983658704dd"; } // - (BOOL)adWhirlTestMode { return NO; } // - (void)adWhirlDidDismissFullScreenModal { NSLog(@"adWhirlDidDismissFullScreenModal"); } // - (UIViewController *)viewControllerForPresentingModalView { return self; } // - (void)adWhirlDidReceiveAd:(AdWhirlView *)adWhirlView { [self adjustAdSize]; } // - (void)adjustAdSize { [UIView beginAnimations:@"AdResize" context:nil]; [UIView setAnimationDuration:0.7]; CGSize adSize = [adView actualAdSize]; CGRect newFrame = adView.frame; newFrame.size.height = adSize.height; newFrame.size.width = adSize.width; newFrame.origin.x = (self.view.bounds.size.width - adSize.width)/2; newFrame.origin.y = self.view.bounds.size.height - adSize.height; adView.frame = newFrame; [UIView commitAnimations]; } @end 




Comments are not required - everything is transparent.



Step nine
We compile the application, remove errors, check the operation of advertising on a live device. We are waiting for the day, because adMob will not work immediately, we are checking our IDs and links to the application, which we entered in the registration fields.



Step ten
We post the binary code for verification in the appStore and after a couple of weeks by the grace of God we begin to receive daily financial reports on the website adWhirl or appfigures .



The whole process takes about 60 minutes.



According to the results of sales I can say
1) advertising on the iPhone brings in 2 times more money than purchases from the application;

2) advertising on the iPad brings 5 ​​times more money than buying from the application.



All happy groundhog day, peppers!

Source: https://habr.com/ru/post/137425/



All Articles