DayZ 1.27
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено
EnProfiler.c
См. документацию.
1
6
19
38
54
57
60
73{
103 static proto void Enable(bool enable, bool immediate = false, bool sessionReset = true);
104
114 static proto int IsEnabled();
115
124 static bool IsEnabledD()
125 {
126 return (IsEnabled() & EnProfilerEnabledFlags.DIAG);
127 }
128
138 static bool IsEnabledP()
139 {
140 return (IsEnabled() & EnProfilerEnabledFlags.SCRP);
141 }
142
152 static bool IsEnabledC()
153 {
154 return (IsEnabled() & EnProfilerEnabledFlags.SCRC);
155 }
156
172 static proto void SortData();
173
193 static proto void ResetSession(bool fullReset = false);
194
195
196
201
223 static proto int SetFlags(int flags, bool sessionReset = true);
224
238 static proto int GetFlags();
239
258 static proto bool IsFlagsSet(int flags);
259
276 static proto int AddFlags(int flags, bool sessionReset = true);
277
294 static proto int RemoveFlags(int flags, bool sessionReset = true);
295
311 static proto int ClearFlags(bool sessionReset = true);
312
314
315
316
321
333 static proto void SetModule(EnProfilerModule module, bool sessionReset = true);
334
344
354 static proto owned string ModuleToName(EnProfilerModule module);
355
378 static proto bool NameToModule(string moduleName, out EnProfilerModule module);
379
381
382
383
398 static proto void SetInterval(int interval, bool sessionReset = true);
399
408 static proto int GetInterval();
409
410
411
427 static proto void SetTimeResolution(int resolution);
428
437 static proto int GetTimeResolution();
438
439
440
463 static proto void EnableAverage(bool enable);
464
473 static proto bool IsAverage();
474
475
476
484 static proto void Dump();
485
486
487
492
501 static proto int GetGameFrame();
502
512 static proto int GetSessionFrame();
513
523 static proto int GetTotalFrames();
524
534 static proto int GetProfiledSessionFrames();
535
545 static proto int GetProfiledFrames();
546
548
549
550
557
574 static proto void GetTimePerClass(notnull out array<ref EnProfilerTimeClassPair> outArr, int count = int.MAX);
575
586 static proto void GetAllocationsPerClass(notnull out array<ref EnProfilerCountClassPair> outArr, int count = int.MAX);
587
598 static proto void GetInstancesPerClass(notnull out array<ref EnProfilerCountClassPair> outArr, int count = int.MAX);
599
610 static proto void GetTimePerFunc(notnull out array<ref EnProfilerTimeFuncPair> outArr, int count = int.MAX);
611
622 static proto void GetCountPerFunc(notnull out array<ref EnProfilerCountFuncPair> outArr, int count = int.MAX);
623
625
626
627
632
652 static proto float GetTimeOfClass(typename clss, bool immediate = false);
653
664 static proto int GetAllocationsOfClass(typename clss, bool immediate = false);
665
676 static proto int GetInstancesOfClass(typename clss, bool immediate = false);
677
689 static proto float GetTimeOfFunc(string funct, typename clss, bool immediate = false);
690
701 static proto float GetTimeOfFuncG(string funct, bool immediate = false);
702
714 static proto int GetCountOfFunc(string funct, typename clss, bool immediate = false);
715
726 static proto int GetCountOfFuncG(string funct, bool immediate = false);
727
729
730
731
736
746 {
747 // I only care if it is actually profiling right now, so C
748 bool wasEnabled = IsEnabledC();
749
750 if (!wasEnabled)
751 {
752 // I want the data, and I want it now, so immediate
753 Enable(true, true);
754 }
755
756 return wasEnabled;
757 }
758
760};
761
const int MAX
Определения EnConvert.c:27
Set of methods for accessing script profiling data.
Определения EnProfiler.c:73
Определения PPEConstants.c:68
Result for an object found in CGame.IsBoxCollidingGeometryProxy.
ERROR
Определения EnDebug.c:2
@ ALL
Mask of all events.
Определения EnEntity.c:110
static proto int GetTimeResolution()
Get the currently set time resolution.
static proto void EnableAverage(bool enable)
Enable/disable returning calculated averages.
static proto EnProfilerModule GetModule()
Get the currently profiled module.
static proto int GetInterval()
Get the currently set interval.
static proto void GetTimePerFunc(notnull out array< ref EnProfilerTimeFuncPair > outArr, int count=int.MAX)
Obtain [SD] for Time Per Function.
Param2< int, string > EnProfilerCountFuncPair
Определения EnProfiler.c:59
Param2< float, string > EnProfilerTimeFuncPair
Определения EnProfiler.c:58
static proto int GetProfiledSessionFrames()
Get the total amount of frames profiled in this profiling session.
Param2< int, typename > EnProfilerCountClassPair
Определения EnProfiler.c:56
EnProfilerEnabledFlags
There are 3 states which can be toggled that governs whether script profiling is enabled or not.
Определения EnProfiler.c:44
@ DIAG
Script profiling UI is enabled in WIN+ALT debug menu, when this is true, it will override SCRP.
Определения EnProfiler.c:48
@ SCRP
It has been set to being always enabled through EnProfiler (SCRipt Profiler)
Определения EnProfiler.c:50
@ NONE
No flags.
Определения EnProfiler.c:11
@ SCRC
Whether profiling is currently truly happening (SCRipt Context)
Определения EnProfiler.c:52
static proto int GetAllocationsOfClass(typename clss, bool immediate=false)
Obtain [SD] or [PD] regarding the allocations of a specific class.
static proto float GetTimeOfClass(typename clss, bool immediate=false)
Obtain [SD] or [PD] regarding the time a specific class consumed.
static proto int GetCountOfFunc(string funct, typename clss, bool immediate=false)
Obtain [SD] or [PD] regarding the amount of times a specific function was called.
static proto int GetFlags()
Get the currently used flags across the API.
static proto float GetTimeOfFuncG(string funct, bool immediate=false)
Obtain [SD] or [PD] regarding the time consumed by a specific global function.
static proto int ClearFlags(bool sessionReset=true)
Remove all flags from the currently used set of EnProfilerFlags across the API.
static proto float GetTimeOfFunc(string funct, typename clss, bool immediate=false)
Obtain [SD] or [PD] regarding the time consumed by a specific function.
static proto void SetTimeResolution(int resolution)
Set the resolution of the fetched Time data.
static proto void GetCountPerFunc(notnull out array< ref EnProfilerCountFuncPair > outArr, int count=int.MAX)
Obtain [SD] for Count Per Function.
static proto void SortData()
The internal sorting that happens at the end of the frame (so it is NOT necessary to call this manual...
static proto void SetModule(EnProfilerModule module, bool sessionReset=true)
Set the module to be profiled.
static proto void GetInstancesPerClass(notnull out array< ref EnProfilerCountClassPair > outArr, int count=int.MAX)
Obtain [SD] for Instances Per Class.
static proto owned string ModuleToName(EnProfilerModule module)
Helper to convert EnProfilerModule to string.
static proto int GetTotalFrames()
Get the total amount of frames across all profiling session.
static proto void ResetSession(bool fullReset=false)
Perform [SR], clearing SessionFrame, ProfiledSessionFrames, [SD] and [PD] (except for [CI])
static proto bool IsAverage()
Check if returning of average data is enabled.
static proto int GetProfiledFrames()
Get the total amount of frames profiled across all profiling session.
Param2< float, typename > EnProfilerTimeClassPair
Определения EnProfiler.c:55
static bool IsEnabledP()
Return if script profiling is enabled through EnProfiler.
Определения EnProfiler.c:138
static proto void GetAllocationsPerClass(notnull out array< ref EnProfilerCountClassPair > outArr, int count=int.MAX)
Obtain [SD] for Allocations Per Class.
static bool IsEnabledC()
Return if script profiling is actually turned on inside of the script context.
Определения EnProfiler.c:152
static proto int GetInstancesOfClass(typename clss, bool immediate=false)
Obtain [SD] or [PD] regarding the [CI] of a specific class.
static proto int GetGameFrame()
Get the total amount of frames passed.
EnProfilerFlags
Flags that influences the behaviour of the EnProfiler API, applied through ...Flags functions.
Определения EnProfiler.c:9
@ RECURSIVE
Whether to profile child modules.
Определения EnProfiler.c:15
@ RESET
When present, will reset [PD] on sorting, otherwise will accumulate on top of it.
Определения EnProfiler.c:13
static proto void GetTimePerClass(notnull out array< ref EnProfilerTimeClassPair > outArr, int count=int.MAX)
Obtain [SD] for Time Per Class.
static proto int SetFlags(int flags, bool sessionReset=true)
Override the currently used set of EnProfilerFlags across the API.
static proto void Enable(bool enable, bool immediate=false, bool sessionReset=true)
Enable the gathering of script profiling data.
EnProfilerModule
Current base scripted modules.
Определения EnProfiler.c:22
@ WORLD
4_World
Определения EnProfiler.c:30
@ CORE
1_Core
Определения EnProfiler.c:24
@ GAMELIB
2_GameLib
Определения EnProfiler.c:26
@ MISSION_CUSTOM
init.c
Определения EnProfiler.c:34
@ GAME
3_Game
Определения EnProfiler.c:28
@ MISSION
5_Mission
Определения EnProfiler.c:32
static proto bool NameToModule(string moduleName, out EnProfilerModule module)
Convert string to EnProfilerModule.
static bool RequestImmediateData()
Helper method to ascertain the profiler will record [PD] right after this call.
Определения EnProfiler.c:745
static proto void Dump()
Print out [SD] to script log.
static proto bool IsFlagsSet(int flags)
Check if the flags are set.
static proto int GetSessionFrame()
Get the total amount of frames in this profiling session.
static proto int RemoveFlags(int flags, bool sessionReset=true)
Remove flags from the currently used set of EnProfilerFlags across the API.
static bool IsEnabledD()
Return if script profiling is enabled through [DM].
Определения EnProfiler.c:124
static proto void SetInterval(int interval, bool sessionReset=true)
Set the interval for the [SD] to update.
static proto int IsEnabled()
Return if script profiling is enabled.
static proto int GetCountOfFuncG(string funct, bool immediate=false)
Obtain [SD] or [PD] regarding the amount of times a specific function was called.
static proto int AddFlags(int flags, bool sessionReset=true)
Add flags to the currently used set of EnProfilerFlags across the API.