Unity ads not working

I implemented unit ads into my game and they worked fine but have suddenly stopped working. I believe it is due to a scripting error however no errors have occured.My game is targeted to Android. I have updated unity and attempted to use the unity ad plug in can some one help me?I am new to the program thanks.

script
using UnityEngine.Advertisements;
using UnityEngine.UI;
using UnityEngine;

public class ADS : MonoBehaviour
{
public Text Gems;
public GameObject cube;
public int money;

private void Start()

{
money = PlayerPrefs.GetInt(“money”);
}

public void ShowAd()
{
if (Advertisement.IsReady())
{
Advertisement.Show(“rewardedVideo”,new ShowOptions(){resultCallback = HandleAdResult});
}
}

private void HandleAdResult(ShowResult result)
{
switch (result)
{
case ShowResult.Finished:
pickup();
Debug.Log("+5 ");
break;
case ShowResult.Skipped:
pickup();
Debug.Log(“AD skipped”);
break;
case ShowResult.Failed:
pickup();
Debug.Log(“AD failed”);
break;
}
}
private void pickup()
{
money += 5;
PlayerPrefs.SetInt(“money”, money);
PlayerPrefs.Save();
Gems.text = money + " ";

}
}

Hi there @Mufaro-games

I am sorry that this has happened - if you could provide me with some more info then I can help you.

Which version of Unity are you using?
Did you make any changes?
Do you get test ads?
Are ads working in the editor?

Thanks

Thank you for replying so swiftly .I am using unity version 5.6.0f3 64bit . i was being displayed test ads and my build had displayed real ads but whilst working on my game unity had crashed when i reloaded unity it asked me to refresh access so i did since then it has not bee working. I tried tweeking the settings on the services tab but nothing improved .In the editor the ads don’t work.

Oh no!

Have you tried using the Asset Store Package and integrating that instead of the services window?

:slight_smile:

Yes. Thank you for trying to help.

@Mufaro-games is it now working?

No

@Mufaro-games

Please, can you submit a ticket form from https://dashboard.unityads.unity3d.com?

I would like to see a build of your game and full project for testing purposes.

Feel free to put my name at the top of the ticket and I will pick it up straight away :slight_smile:

i attempted to submit the ticket but it came up eith errors . i also tried to compress the file. it could not be emaild either.

@Mufaro-games hmm, that’s strange.

What kind of errors are you getting? Can you screenshot them and PM me?

Thanks

@Mufaro-games it’s probably because the file size is too big.

I will PM you details for cloud sharing