• Discuss all the things!

    154 Topics
    556 Posts

    Thank you for the responses. Based on the discussion, we've implemented the following:

    Product default price: standard App Store price Promotion price override: "Not for Sale" (priceId: -2) — workaround to pass console validation requiring a price difference Purchase verification: server-to-server (S2S) VERIFY_PURCHASE, no explicit promotionId in the request Promotion gating: via GetEligiblePromotions() on the client

    We're observing that the purchased counter increments correctly after purchase, and the promotion does not reappear after app restart.

    We believe the reason automatic attribution works without calling CachePurchasePayloadContext() is that we set Apple's appAccountToken (a UUID embedded in the StoreKit 2 signed transaction) to the brainCloud profileId before initiating the native IAP purchase. When brainCloud receives the JWS receipt during S2S VERIFY_PURCHASE, it can extract the appAccountToken, identify the user, look up their active promotions, and increment the counter automatically.

    Two quick questions:

    Is this understanding correct — does brainCloud use the appAccountToken in the StoreKit 2 JWS to perform automatic promotion attribution, making CachePurchasePayloadContext() unnecessary in this flow? When we extend this to Android (Google Play), there is no equivalent of appAccountToken in the receipt. What is the recommended approach to ensure promotion attribution works correctly in that case — should we call CachePurchasePayloadContext() before the purchase, or is there another mechanism?
  • Suggestions for improvements, new features, etc.

    43 Topics
    138 Posts

    Dear @dbgtdbz2 ,

    About your feature request #1, “Please allow specifying items as conditions for purchasing virtual or bundle items."

    I have developed a mockup for this feature.

    If we add your Prerequisite Items request to the system as shown, will this work for your needs?

    Note that in this implementation, the prerequisite requirement applies only to a Virtual Currency transaction. PrereqItemsMockup.png

    Please let me know at your convenience,
    Regards,
    John H
    -Design

  • Questions specific to particular APIs, libraries, etc.

    63 Topics
    260 Posts

    It's been resolved. Thank you for your response!

  • General cloud code discussions...

    35 Topics
    149 Posts

    Q1: The removed player is completely excluded from reward calculation, so if the deletion happens before the job runs, that player is never iterated over and receives no rank or rewards.
    Q2: Yes, the modified score will be used. The job always reads live state. Note that whether the score actually gets modified depends on the leaderboard type (e.g., for the LOW_VALUE type, only updates if the new score is less than the existing)
    Q3: No backfilling, the next joiner goes to the latest instance, not the freed spot in ^2. No loop over earlier instances (^1, ^2) ever happens. The next joiner goes to ^3 (or ^4 if ^3 is full). The freed spot in ^2 stays empty permanently.

  • brainCloud's online learning tutorials and examples.

    3 Topics
    3 Posts

    brainCloud developers have just release several playable builds of our famous examples! See our cool features in action. Find them at https://getbraincloud.com/demos for Windows, Mac, online and mobile.

brainCloud 5 is alive!

brainCloud 5 features Portal-X (our next-gen portal), Integrated Forums (you found them), our new Bootcamp training videos, and more!

Join the discussion here!

brainCloud Bootcamp!
brainCloud's new video learning portal is now online! Go check out brainCloud BootCamp!

Need to report a defect?
Use the chat widget from the Design Portal - or send an email to support at getbraincloud.com. Thanks!