Go To Console

Use Personalized Offer SDK

Prerequisite

Personalized offers are only available for TENTUPLAY SDK v2021.2, or later versions, so please check your SDK version.
Before sending personalized offers via the console, please download the SDK and follow the installation process described below.

Learn More About Creating a Project

TPPersonalizedOfferController

When the ShowOffer method is called TPPersonalizedOfferController will call Offers respective of each player (player_uuid) and display it on the Canvas.

  • ShowOfferis a method of the TPPersonalizedOffer class,
    TPPersonalizedOffer is the class for displaying TENTUPLAY’s personalized offers.
Learn More About TPPersonalizedOffer

Utilizing in Unity

TPPersonalizedOfferController.prefab can be found in the location below, -and contains TPPersonalizedOfferController.cs script as a component.

  • Assets/TentuPlay/TPPersonalizedOfferTemplates/TPPersonalizedOfferController.prefab

Move TPPersonalizedOfferController game object to Canvas.

Utilize tpPersonalizedOfferController GameObject parameter value to call ShowOffer.
After, TENTUPLAY will automatically show the offer.

Example Code

public void ShowPersonalizedOffer()
    {
        TPPersonalizedOffer myTPOffer = new TPPersonalizedOffer();

        StartCoroutine(
            myTPOffer.ShowOffer(tpPersonalizedOfferController, player_uuid, "en", (response=> {}), offer_id:offer_id));
    }

Example Image

[An image of a personalized offer]

When ShowOffer is called, TentuPlayOffer_landscape or TentuPlayOffer_portrait will be created on the Canvas as a child of TPPersonalizedOfferController (TPPersonalizedOfferController.ShowOffer) and the image entered into the console will become a Texture/Raw Image of OfferImage (differs by version).

Learn more about TPPersonalizedOffer



[An image of TentuplayOffer_landscape created as a child of TPPersonalizedOfferController]

Offer UI

An explanation for the components TentuPlayOffer_landscape, TentuPlayOffer_portrait

TentuPlayOffer_landscape.prefab

GUI

Scripts

- MessageController: A script for opening and closing messages
- TentuPlayOffer: a TENTUPLAY script for personalized offers.


Message Image: OfferImage

GUI

While the default image size in the console is set at 580x896px, this can be changed by selecting a new size in OfferImage

※ Default Size
- TentuPlayOffer_landscape: 640x400
- TentuPlayOffer_portrait: 400x640

Scripts

TentuPlayOffer.GoToOfferEvent in On Click()

※ There is a separate OfferButton in the Unity 2017 SDK, so please check your SDK version.


CloseButton

GUI

Scripts

TentuPlayOffer.CloseOfferEvent in On Click()

Do you need help?

Do you have questions? Join TENTUPLAY Discord if you have any questions.