Пример #1
0
    public void Update()
    {
        long num = (long)(ELSingleton <XmlSettings> .Instance.dailyPuzzleConfig.timeSpan * (float)(ELSingleton <ApplicationSettings> .Instance.DeploymentSettings.isDebug ? 60 : 86400));

        if (DateLast == long.MaxValue)
        {
            DateLast = ELUtils.GetEpochTime() - num;
        }
        IsAvailable = (ELUtils.GetEpochTime() - DateLast > num);
    }
Пример #2
0
    public bool ShowRewardedVideo(bool aIsExecute)
    {
        long timeSpan = GetTimeSpan();
        bool num      = ELUtils.GetEpochTime() - RewardedVideoAdDateLast >= timeSpan && ELSingleton <AdsManager> .Instance.ShowRewardedVideoAd(AdsManager.AdType.FreeCoins, aIsExecute);

        if (num & aIsExecute)
        {
            rewardedVideoAdDateLast = ELUtils.GetEpochTime();
            ELSingleton <ApplicationSettings> .Instance.Save();
        }
        return(num);
    }
Пример #3
0
 public long GetTimeSpan()
 {
     return((long)(ELSingleton <XmlSettings> .Instance.dailyPuzzleConfig.timeSpan * (float)(ELSingleton <ApplicationSettings> .Instance.DeploymentSettings.isDebug ? 60 : 86400)) - ELUtils.GetEpochTime() + DateLast);
 }
Пример #4
0
 private void SetupNextTime()
 {
     IsAvailable = false;
     DateLast    = ELUtils.GetEpochTime();
     ELSingleton <ApplicationSettings> .Instance.Save();
 }
Пример #5
0
 public long GetRewardedVideoTimeSpan()
 {
     return(GetTimeSpan() - ELUtils.GetEpochTime() + rewardedVideoAdDateLast);
 }