added performance counter for think hook

This commit is contained in:
Evil Factory
2022-04-30 12:54:34 -03:00
parent 3f221c0d23
commit 0604a27efb

View File

@@ -924,9 +924,17 @@ namespace Barotrauma
SoundManager?.Update();
Stopwatch luaSw = new Stopwatch();
luaSw.Start();
GameMain.LuaCs.Update();
GameMain.LuaCs.Hook.Call("think");
luaSw.Stop();
PerformanceCounter.AddElapsedTicks("Think Hook", luaSw.ElapsedTicks);
Timing.Accumulator -= Timing.Step;
updateCount++;