Hi Felgo,
Yeah, it looks like like I found another one 🙂
It’s Rewarded video with AdMob.
When you use more than one rewarded video elements, and loading video on second RewardedVideo, then listener is triggered on first video.
I think this behavior is incorrect.
As always, simple example.
Please check if this behaves in wrong way for you as well.
Expected behavior: when you click the button listener on secondVideo.onRewardedVideoReceived should be trigger but listener on firstVideo is triggered instead.
Didn’t test other listener but this issue is maybe not specific to this one only.
Of course you need to provide license and two valid AdMob unit ids, but different.
import Felgo 3.0
import QtQuick 2.0
import Felgo 3.0
import "pages"
import "helper"
GameWindow {
id: gameWindow
activeScene: scene
screenWidth: 640
screenHeight: 960
licenseKey: "<your-license-key>"
Scene {
id: scene
width: 320
height: 480
Rectangle {
id: rectangle
anchors.fill: parent
color: "grey"
}
SimpleButton {
anchors.centerIn: parent
width: 150
height: 150
text: 'Click me'
onClicked: {
secondVideo.loadRewardedVideo()
}
}
AdMobRewardedVideo {
id: firstVideo
adUnitId: '<your-unit-id-1>''
onRewardedVideoFailedToReceive: {
console.log('========= Failed to receive the video at FIRST VIDEO')
}
onRewardedVideoReceived: {
console.log('========= Received the video at FIRST VIDEO')
}
}
AdMobRewardedVideo {
id: secondVideo
adUnitId: '<your-unit-id-2>'
onRewardedVideoFailedToReceive: {
console.log('========= Failed to receive the video at SECOND VIDEO')
}
onRewardedVideoReceived: {
console.log('========= Received the video at SECOND VIDEO')
}
}
}
}