cocos2d-x / plugin-x

Plugin-x is the plugin repository for cocos2d-x, it also provides a unified API for plugins.
71 stars 91 forks source link

Plugin-x iOS IAP Feedback, please give me responses #119

Open yagjak opened 9 years ago

yagjak commented 9 years ago

i'm using plugin-x iOS IAP , and this is my Feedback

  1. There's no implementation of configDeveloperInfo function, i have implemented it like this:
-(void) configDeveloperInfo: (NSMutableDictionary*) cpInfo{

    [self requestProducts :[cpInfo objectForKey:@"iapKey" ]];

}
  1. i can't call the restore function and there's no callback for it.
  2. Handling errors is not enough (no internet connection, IAP restriction,..)
  3. if my iPad was not connected, after trying to buy an item, if I connect it to the internet, plugin-x does not initialize the variable _paying to false, so we can't purchase items after this (until relaunching the app)
  4. i think that, there's mistake here :
typedef enum 
{
    kPaySuccess = 0,
    kPayFail,
    kPayCancel,
    kPayTimeOut,
} PayResultCode;

typedef enum {
    PaymentTransactionStatePurchased = 0,
    PaymentTransactionStateFailed,
    PaymentTransactionStateRestored,
    PaymentTransactionStateTimeout,
} IAPResult;

Why the third element isn't the same ? Thanks for this great work. and i hope that you will consider my Feedback as soon as possible.

ahlwong commented 9 years ago

Hi,

I found that the plugin-x framework, specifically for iOS IAPs, is pretty coarse in most areas and outright buggy in others. I found that I had to make extensive modifications to the SDK to get it to a point that made it usable. I addressed some of your concerns too in my corrections...

1) You have to create and implement your own restore function 2) Yes, you need to do your own error handling or augment what is there ... 4) The order is indeed incorrect