Unity中确定时间是否在一定范围内

 DateTime DateReg = Convert.ToDateTime(RegTime);
        DateTime MaxDate = Convert.ToDateTime(MaxTime);
        DateTime MinDate = Convert.ToDateTime(MinTime);
        if (!((NowTime.CompareTo(MinDate) >= 0 && NowTime.CompareTo(MaxDate) <= 0)
            && (DateReg.CompareTo(MinDate) >= 0 && DateReg.CompareTo(MaxDate) <= 0)))
        {
            Application.Quit();

        }

  

上一篇:Java中“==”、“compareTo()”和“equals()”的区别


下一篇:android上是否存在支持ping,吞吐量等的现有性能评估库?