init
This commit is contained in:
37
Assets/AdManager/ShowReward.cs
Normal file
37
Assets/AdManager/ShowReward.cs
Normal file
@@ -0,0 +1,37 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
using UnityEngine.UI;
|
||||
|
||||
public class ShowReward : MonoBehaviour
|
||||
{
|
||||
public Text Result;
|
||||
bool sdkinitialize;
|
||||
// Start is called before the first frame update
|
||||
void Start()
|
||||
{
|
||||
|
||||
Result.text="Loaded";
|
||||
}
|
||||
|
||||
// Update is called once per frame
|
||||
void Update()
|
||||
{
|
||||
if(PlayerPrefs.GetInt ("reward", 0)==1){
|
||||
Result.text="Congratulation you got your reward";
|
||||
PlayerPrefs.SetInt ("reward", 0);
|
||||
Invoke("ClearText",10f);
|
||||
}else if(PlayerPrefs.GetInt ("reward", 0)==2){
|
||||
Result.text="Sorry! Video failed to load";
|
||||
PlayerPrefs.SetInt ("reward", 0);
|
||||
Invoke("ClearText",10f);
|
||||
}
|
||||
// if(AdManager._Instance.intestetialloaded){
|
||||
// Result.text="Intestetial Loaded";
|
||||
// }
|
||||
}
|
||||
|
||||
void ClearText(){
|
||||
// Result.text=" ";
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user