Skip to main content
Version: 16.5.2 (current)

Class RewardedVideoAd

Declaration
public class RewardedVideoAd : IAdFullScreen, IAd, IAdLoadRetryHandler

Implements:
MatchinghamGames.VegasModule.IAdFullScreen, MatchinghamGames.VegasModule.IAd, MatchinghamGames.VegasModule.IAdLoadRetryHandler

Properties

Enabled

If rewarded video is enabled

Declaration
public bool Enabled { get; }

IsLoaded

If rewarded video is loaded

Declaration
public bool IsLoaded { get; }

IsLoading

If rewarded video is loading now

Declaration
public bool IsLoading { get; }

IsShowing

If rewarded video is showing now

Declaration
public bool IsShowing { get; }

RetryAttempt

Declaration
public int RetryAttempt { get; set; }

Data

Current data of the rewarded video

Declaration
public AdDTO Data { get; }

RevenueData

Current revenue data of the rewarded video

Declaration
public AdRevenueDTO RevenueData { get; }

ErrorData

Current error data of the rewarded video

Declaration
public AdErrorDTO ErrorData { get; }

Methods

Initialize()

Declaration
public void Initialize()

Load()

Load rewarded video manually

Declaration
public void Load()

Show(string)

Declaration
public void Show(string adTag)
Parameters
TypeName
System.StringadTag

Show(Action, Action, string)

Show rewarded video manually

Declaration
public void Show(Action onSuccessCallback = null, Action onFailCallback = null, string adTag = null)
Parameters
TypeNameDescription
System.ActiononSuccessCallbackAn action to be invoked, if user watches the rewarded video till the end.
System.ActiononFailCallbackAn action to be invoked, if user didn't watch or abort the rewarded video.
System.StringadTagTag of the rewarded video. If you don't have, leave it. Default is null.

Events

FailedToLoad

Invokes when rewarded video fails to load

Declaration
public event Action FailedToLoad
Event Type

System.Action

Loaded

Invokes when rewarded video is loaded

Declaration
public event Action Loaded
Event Type

System.Action

LoadedStatusChanged

Invokes when rewarded video load status is changed

Declaration
public event Action LoadedStatusChanged
Event Type

System.Action

FailedToShow

Invokes when rewarded video fails to be opened

Declaration
public event Action FailedToShow
Event Type

System.Action

Shown

Invokes when rewarded video is opened

Declaration
public event Action<AdDTO> Shown
Event Type

System.Action<MatchinghamGames.VegasModule.AdDTO>

Closed

Invokes when rewarded video is closed. Parameter is if user watched it or not

Declaration
public event Action<bool> Closed
Event Type

System.Action<System.Boolean>

Clicked

Invokes when rewarded video is clicked

Declaration
public event Action Clicked
Event Type

System.Action

AdDataObtained

Invokes when a rewarded video ad data is obtained

Declaration
public event Action<AdDTO> AdDataObtained
Event Type

System.Action<MatchinghamGames.VegasModule.AdDTO>

RevenueDataObtained

Invokes when a rewarded video ad revenue data is obtained

Declaration
public event Action<AdDTO, AdRevenueDTO> RevenueDataObtained
Event Type

System.Action<MatchinghamGames.VegasModule.AdDTO,MatchinghamGames.VegasModule.AdRevenueDTO>

ErrorDataObtained

Invokes when a rewarded video ad error data is obtained

Declaration
public event Action<AdDTO, AdErrorDTO> ErrorDataObtained
Event Type

System.Action<MatchinghamGames.VegasModule.AdDTO,MatchinghamGames.VegasModule.AdErrorDTO>

Implements