I want to see if the user completed a certain task in one second. I know that there are several ways to get time elapsed, but I am wondering what the most accurate way would be for this scenario. I want to get time elapsed ever since a certain time. For example, register a timer, and refer back to it later:
User does something
I check if user completed task in the one second timer
User does something again
I check if the user completed the task within the same one second timer that was running before. If not, make timer null.
User does something again
I check if user completed the task within one second timer. If not, make timer null.
I want to basically have one timer that runs for one second, as the user completes various tasks. After every task, I check whether or not the timer is still going. I don't want to use countdowntimer for this, as it is not accurate enough for one second. What method can I use for this?