How to try account linking in demo

You can implement the following features by linking a player’s account on different platforms to the main account:

  • automatic player identification on different platforms
  • manage a single cross-platform inventory on different platforms

Use demo scenes to check the linking of platform accounts to the main account for a preset Publisher Account project.

Note
You can link only one account of each platform to the main account.

To try account linking in a demo project:

  1. Go to your Unity project.
  2. Set up the demo scene to log in to the application via the platform account:
    1. In the main menu, go to Window > Xsolla > Edit Settings.
    2. Set the following parameters in the Inspector panel:
      1. Specify Publishing platform. The selected value must be different from Xsolla and None.
      2. Change Username from console.

  1. Start the Xsollus demo scene from the Assets > Xsolla > DemoCommon > Scene folder.

  1. Click User account and then Account linking in the demo scene. The demo project will open in the default browser to simulate the start of the application on another platform.

  1. Click Create an account.

  1. Specify email and password. Click Accept and create.

  1. Select an item in the catalog and click Buy on Xsolla. Purchase the item using one of the test bank cards. Close the receipt.

  1. Click on the email at the top of the screen to open the menu. Click Inventory. Make sure that the purchased item is available in the inventory.

  1. Click Get code. Click Request the code in the opened window. Write down the received account linking code.

  1. Go to the demo scene in Unity.
  2. Enter the received account linking code (see step 9) and click Confirm.

  1. Now the platform account is linked to the main account. Make sure that the purchased item is available in the inventory in the Unity demo scene.

  1. Since this account is already linked to the main account, you can get the account linking code from it. Click Get account link. Write down the received code.

  1. Set up the demo scene to log in to the application via another platform account (see step 2). The Publishing platform should be different from the one selected in step 2.
  2. Start the Xsollus demo scene from the Assets > Xsolla > DemoCommon > Scene folder.

  1. Make sure the player’s inventory is empty.
  2. Click Account linking. Stay in the Unity demo scene.

  1. Enter the received account linking code (see step 13) and click Confirm.

  1. Now the account from the new platform is also linked to the main account. Make sure that the purchased item is available in the inventory of the Unity demo scene.

Follow the recipe to configure account linking for your project.

Was this article helpful?
Thank you!
Is there anything we can improve? Message
We’re sorry to hear that
Please explain why this article wasn’t helpful to you. Message
Thank you for your feedback!
We’ll review your message and use it to help us improve your experience.
Rate this page
Rate this page
Is there anything we can improve?

Don’t want to answer

Thank you for your feedback!
Last updated: April 28, 2022

Found a typo or other text error? Select the text and press Ctrl+Enter.

Report a problem
We always review our content. Your feedback helps us improve it.
Provide an email so we can follow up
Thank you for your feedback!