public void OnBeginTimerCommand(BeginTimerCommand command)
        {
            if (insideLoop)
            {
                loopCommands.Add(command);
                return;
            }

            // Already timer running
            if (stopwatch != null)
            {
                Console.WriteLine(
                    "[{0}] Timer already running",
                    DateTime.Now.ToString("HH:mm:ss"));
            }
            else
            {
                Console.WriteLine(
                    "[{0}] Timer started",
                    DateTime.Now.ToString("HH:mm:ss"));
                stopwatch = Stopwatch.StartNew();
            }
        }
Пример #2
0
 private void Awake()
 {
     BeginTimerCommand = GetComponent <BeginTimerCommand>();
 }