JCUtil.cs 361 B

1234567891011121314
  1. using System.Collections;
  2. using System.Collections.Generic;
  3. using UnityEngine;
  4. using System;
  5. public class JCUtil : MonoBehaviour
  6. {
  7. // Start is called before the first frame update
  8. public static long GetTimestamp()
  9. {
  10. TimeSpan ts = DateTime.Now.ToUniversalTime() - new DateTime(1970, 1, 1);
  11. return (long)ts.TotalMilliseconds;
  12. }
  13. }