Banner

There are some advertisement settings in the playgama-bridge-config.json file

Playgama Bridge Config

Is Banner Supported

Check if the platform supports displaying banner ads. Use this to determine if you can include banner advertisements in your game.

Bridge.advertisement.is_banner_supported

Ensure that in-game banners are not displayed during gameplay on CrazyGames. Please refer to Advertisement - CrazyGames Documentation.

Show Banner

Display a banner ad within your game to generate revenue through advertising.

var position = Bridge.BannerPosition.BOTTOM # optional, 'TOP' | 'BOTTOM', default = 'BOTTOM'
var placement = "test_placement" # optional
Bridge.advertisement.show_banner(position, placement)

Hide Banner

Hide the currently displayed banner ad when it is no longer needed.

Bridge.advertisement.hide_banner()

Monitor the state of the banner ad (loading, shown, hidden, failed) to manage its display and troubleshoot issues.

Bridge.advertisement.banner_state

Returns the current state of the banner. Possible values: loading, shown, hidden, failed.

# To track banner state changes, connect to the signal
func _ready():
    Bridge.advertisement.connect("banner_state_changed", self, "_on_banner_state_changed")

func _on_banner_state_changed(state):
    print(state)

Last updated