Can anyone help me clarify a few lines of code. This is code taken from another post written by Edwin van Poeijer (http://www.cocos2d-x.org/boards/6/topics/20664?r=24543#message-24543)
for implementing In App Purchasing. Edwin created the binds; I am trying to understand them.
This is taken from the file IOS_BillingManager.mm file
- (void) initialize{
if ([SKPaymentQueue canMakePayments]) {
if (self.billingAvailableCallback)
{
// Init the rest
[[SKPaymentQueue defaultQueue] addTransactionObserver:self];
(self.billingAvailableCallback);
}
}
else
{
;
}
}
what does@ if(self.billingAvailableCallback)* do? is this not redundant because
[SKPaymentQueue canMakePayments]@ does the same thing, right? Is the code implementing IAP for Android at the same time?
Also what is @ ;@ ? I dont understand what this does.
If i wanted to implement this in iOS only there should be no problem calling functions from the IOS_GoogleBilling.mm file correct?