↳ Ads

AirConsole

new AirConsole(opts) → {AirConsoleObject}

Your gateway object to AirConsole. There are getter and setter functions for all properties. Do not access properties of this object directly.
Parameters:
Name Type Description
opts AirConsole~Config Constructor config, see bellow.
Source:
Returns:
The AirConsole object.
Type
AirConsoleObject

Methods

(abstract) onAdComplete(ad_was_shown)

Gets called when an advertisement is finished or no advertisement was shown.
Parameters:
Name Type Description
ad_was_shown boolean True iff an ad was shown and onAdShow was called.
Source:

(abstract) onAdShow()

Gets called if a fullscreen advertisement is shown on this screen. In case this event gets called, please mute all sounds.
Source:

showAd()

Requests that AirConsole shows a multiscreen advertisment. Can only be called by the AirConsole.SCREEN. onAdShow is called on all connected devices if an advertisement is shown (in this event please mute all sounds). onAdComplete is called on all connected devices when the advertisement is complete or no advertisement was shown.
Source: