Я получаю эту ошибку:
Активы \ Найти пары \ Scripts \ AdsManager.cs (54,43): ошибка CS1503: Аргумент 1: невозможно преобразовать из «GoogleMobileAds.Api.InterstitialAd» в «строку»
со следующим кодом:
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using GoogleMobileAds.Api;
public class AdsManager : MonoBehaviour
{
public static AdsManager instance;
private string appID = "ca-app-pub-3940256099942544~3347511713";
private BannerView bannerView;
private string bannerID = "ca-app-pub-3940256099942544/6300978111";
private InterstitialAd fullScreenAd;
private string fullScreenAdID = "ca-app-pub-3940256099942544/1033173712";
private void Awake()
{
if (instance == null)
{
instance = this;
}
else
{
Destroy(this);
}
}
private void Start()
{
RequestFullScreenAd();
}
public void RequestBanner()
{
bannerView = new BannerView(bannerID, AdSize.Banner, AdPosition.Bottom);
AdRequest request = new AdRequest.Builder().Build();
bannerView.LoadAd(request);
bannerView.Show();
}
public void HideBanner()
{
bannerView.Hide();
}
public void RequestFullScreenAd()
{
fullScreenAd = new InterstitialAd(fullScreenAd);
AdRequest request = new AdRequest.Builder().Build();
fullScreenAd.LoadAd(request);
}
public void ShowFullScreenAd()
{
if (fullScreenAd.IsLoaded())
{
fullScreenAd.Show();
}
else
{
Debug.Log("Full Screen Ad Not Loaded");
}
}
}
Я получаю эту ошибку:
Активы \ Найти пары \ Scripts \ AdsManager.cs (54,43): ошибка CS1503: Аргумент 1: невозможно преобразовать из «GoogleMobileAds.Api.InterstitialAd» в «строку»
Мне нужна помощь, плз