Unhappy In App Purchase - Help on Last stage - downloading content

Discussion in 'Public Game Developers Forum' started by iamDeondrae, Aug 17, 2013.

  1. iamDeondrae

    iamDeondrae New Member

    Aug 17, 2013
    1
    0
    0
    #1 iamDeondrae, Aug 17, 2013
    Last edited: Aug 17, 2013
    i have successfully implemented IAP into my app however i am having a problem figuring out where the user is supposed to find the purchased content after they pay.

    Using my test account when i click the buy button, it marks the IAP with a tick as if to show that its bought but then from there i cant find the content...


    Can someone assist me as to what i need to add to my code and storyboard so the user is able to access their purchased content.... (The content will be several short videos available to the user through IAP)

    From what i have read through all the tutorials, i think the code im missing is this:

    -(void)paymentQueue:(SKPaymentQueue *)queue updatedDownloads:(NSArray *)downloads
    {
    for (SKDownload *download in downloads)
    {
    switch (download.downloadState) {
    case SKDownloadStateActive:
    NSLog(@"Download progress = %f",
    download.progress);
    NSLog(@"Download time = %f",
    download.timeRemaining);
    break;
    case SKDownloadStateFinished:
    // Download is complete. Content file URL is at
    // path referenced by download.contentURL. Move
    // it somewhere safe, unpack it and give the user
    // access to it
    break;
    default:
    break;
    }
    }
    }

    However i also need a method to transfer the completed downloads back into the app and then link a view controller to those downloads/purchased content (How do i do this?)
     

Share This Page