Last active
February 12, 2023 12:49
-
-
Save unitycoder/c609a99fc3f14b3553ed to your computer and use it in GitHub Desktop.
Measure time with Stopwatch Timer
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var stopwatch = new System.Diagnostics.Stopwatch(); | |
stopwatch.Start(); | |
// your function here.. | |
stopwatch.Stop(); | |
//Debug.Log("Timer: " + stopwatch.Elapsed); | |
Debug.Log("Timer: " + stopwatch.ElapsedMilliseconds); | |
stopwatch.Reset(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
using Time.time
https://gist.github.com/unitycoder/b7b451cf05dded78eb76