public static void SaveInTime() { if (TheGame.GetComponent <GameData>() != null) { TheGame.GetComponent <GameData>().ResetTimeToSave(); } }
public static void Save() { if (TheGame.GetComponent <GameData>() != null) { TheGame.GetComponent <GameData>().SaveToFile(); } }
public static String GetNameSprite(TypeDataModel typeData) { var info = TheGame.GetComponent <GameDataModel>(); if (info == null) { return(null); } return(info._data[typeData].GetNameSprite()); }
public static List <IGameDataParticleModel> GetData(TypeDataModel typeData) { var info = TheGame.GetComponent <GameDataModel>(); if (info == null) { return(null); } return(info._data[typeData].GetData()); }
public static void AddActionForRewardVideo(Action onActionGetReward) { var ads = TheGame.GetComponent <Admob>(); if (ads == null) { return; } ads.OnActionRewardedUser = onActionGetReward; }
public static void ShowRewardVideo() { var ads = TheGame.GetComponent <Admob>(); if (ads == null) { return; } ads.ShowRewardedAd(); }
public static void LoadingBanner() { var ads = TheGame.GetComponent <Admob>(); if (ads == null) { return; } ads.RequestBanner(); }
public static void LoadingRewardVideo() { var ads = TheGame.GetComponent <Admob>(); if (ads == null) { return; } ads.RequestRewardBasedVideo(); ads.RequestBanner(); }
public void Save() { if (TheGame.GetComponent <GamePlayer>() == null) { return; } _playerDataModel = TheGame.GetComponent <GamePlayer>().GetPlayerData(); _playerDataModel.langId = (int)Lang.Instance.CurLang; var serializedOutput = JsonUtility.ToJson(_playerDataModel); FileUtils.SaveTextToFile(_fileName, serializedOutput); Debug.Log("Save Game"); }
public static PlayerDataModel GetPlayerData() { var p = TheGame.GetComponent <GameData>(); if (p == null) { return(null); } if (p._playerDataModel == null) { p._playerDataModel = new PlayerDataModel(); p._playerDataModel.Init(); } return(p._playerDataModel); }
public void SaveGame() { TheGame.GetComponent <GameData>().SaveTime(); }
public override void Init() { var playerData = TheGame.GetComponent <GameData>().GetPlayerData(); _playerDataModel = playerData; }