DayZ 1.29
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено
3_Game/DayZ/tools/Debug.c
См. документацию.
1class Debug
2{
3 private static const string LOG_DEBUG = "Debug";
4 private static const string LOG_DEBUG_ACTION = "Action";
5 private static const string LOG_DEBUG_SYMPTOM = "Symptom";
6 private static const string LOG_DEBUG_INV_MOVE = "Inv Move";
7 private static const string LOG_DEBUG_INV_RESERVATION = "Inv Rrsv";
8 private static const string LOG_DEBUG_INV_HFSM = "HFSM";
9 private static const string LOG_DEBUG_QUICKBAR = "Quickbar";
10 private static const string LOG_DEBUG_BASEBUILDING = "Base Building";
11 private static const string LOG_DEBUG_BLEEDING_CHANCES = "Bleeding";
12 private static const string LOG_DEBUG_TRIGGER = "Trigger";
13 private static const string LOG_DEBUG_PARTICLE = "Particle";
14 private static const string LOG_DEBUG_TF = "TestFramework";
15 private static const string LOG_DEBUG_WEIGHT = "Weight";
16 private static const string LOG_DEBUG_MELEE = "Melee";
17 private static const string LOG_DEBUG_WEATHER = "Weather";
18
19 private static const string LOG_INFO = "Info";
20 private static const string LOG_WARNING = "Warning";
21 private static const string LOG_ERROR = "Error";
22 private static const string LOG_DEFAULT = "n/a";
23
24 private static ref array<Shape> m_DebugShapes;
27
29 static CanvasWidget m_CanvasDebug;
30
31 static string GetDebugName(Managed entity)
32 {
33 if (!entity)
34 return "";
35
36 Object obj;
37 if (CastTo(obj, entity))
38 return obj.GetDebugNameNative();
39
40 return entity.GetDebugName();
41 }
42
43 static void InitCanvas()
44 {
46 {
47 m_DebugLayoutCanvas = g_Game.GetWorkspace().CreateWidgets("gui/layouts/debug/day_z_debugcanvas.layout");
48 m_CanvasDebug = CanvasWidget.Cast( m_DebugLayoutCanvas.FindAnyWidget( "CanvasWidget" ) );
49 }
50 }
51
52 static void ClearCanvas()
53 {
54 if (m_CanvasDebug)
55 m_CanvasDebug.Clear();
56 }
57
58 static void CanvasDrawLine(float x1, float y1, float x2, float y2, float width, int color)
59 {
60 InitCanvas();
61 m_CanvasDebug.DrawLine(x1, y1, x2, y2, width, color);
62 }
63
74
75 static void CanvasDrawPoint(float x1, float y1, int color)
76 {
77 CanvasDrawLine(x1, y1, x1+1, y1, 1, color);
78 }
79
86
87 static void DestroyAll()
88 {
92 }
93
94 static void DestroyAllShapes()
95 {
96 foreach (Shape debugShape : m_DebugShapes)
97 debugShape.Destroy();
98
99 m_DebugShapes.Clear();
100 }
101
102 static void DestroyAllTextSS()
103 {
104 m_DebugTextsSS.Clear();
105 }
106
107 static void DestroyAllTextWS()
108 {
109 m_DebugTextsWS.Clear();
110 }
111
112 static void RemoveShape(out Shape shape)
113 {
114 if (!shape)
115 return;
116
117 int nDebugShapes = m_DebugShapes.Count();
118 for (int i = 0; i < nDebugShapes; ++i)
119 {
120 Shape foundShape = m_DebugShapes.Get(i);
121
122 if (foundShape && foundShape == shape)
123 {
124 foundShape.Destroy();
125 m_DebugShapes.Remove(i); // Mandatory! Otherwise the Destroy() function causes crash!
126 shape = null;
127 return;
128 }
129 }
130 }
131
132 static void RemoveTextSS(out DebugTextScreenSpace text)
133 {
134 if (!text)
135 return;
136
137 int nDebugTextsSS = m_DebugTextsSS.Count();
138 for (int i = 0; i < nDebugTextsSS; ++i)
139 {
140 DebugTextScreenSpace foundText = m_DebugTextsSS.Get(i);
141
142 if (foundText && foundText == text)
143 {
144 foundText = null;
145 m_DebugTextsSS.Remove(i);
146 text = null;
147 return;
148 }
149 }
150 }
151
152 static void RemoveTextWS(out DebugTextWorldSpace text)
153 {
154 if (!text)
155 return;
156
157 int nDebugTextsWS = m_DebugTextsWS.Count();
158 for (int i = 0; i < nDebugTextsWS; ++i)
159 {
160 DebugTextWorldSpace foundText = m_DebugTextsWS.Get(i);
161
162 if (foundText && foundText == text)
163 {
164 foundText = null;
165 m_DebugTextsWS.Remove(i);
166 text = null;
167 return;
168 }
169 }
170 }
171
182 static void Log(string message = LOG_DEFAULT, string plugin = LOG_DEFAULT, string author = LOG_DEFAULT, string label = LOG_DEFAULT, string entity = LOG_DEFAULT)
183 {
184 LogMessage(LOG_DEBUG, plugin, entity, author, label, message);
185 }
186
187 static void ActionLog(string message = LOG_DEFAULT, string plugin = LOG_DEFAULT, string author = LOG_DEFAULT, string label = LOG_DEFAULT, string entity = LOG_DEFAULT)
188 {
189 LogMessage(LOG_DEBUG_ACTION, plugin, entity, author, label, message);
190 }
191
192 static void SymptomLog(string message = LOG_DEFAULT, string plugin = LOG_DEFAULT, string author = LOG_DEFAULT, string label = LOG_DEFAULT, string entity = LOG_DEFAULT)
193 {
194 LogMessage(LOG_DEBUG_SYMPTOM, plugin, entity, author, label, message);
195 }
196
197 static void InventoryMoveLog(string message = LOG_DEFAULT, string plugin = LOG_DEFAULT, string author = LOG_DEFAULT, string label = LOG_DEFAULT, string entity = LOG_DEFAULT)
198 {
199 LogMessage(LOG_DEBUG_INV_MOVE, plugin, entity, author, label, message);
200 }
201
202 static void InventoryReservationLog(string message = LOG_DEFAULT, string plugin = LOG_DEFAULT, string author = LOG_DEFAULT, string label = LOG_DEFAULT, string entity = LOG_DEFAULT)
203 {
204 LogMessage(LOG_DEBUG_INV_RESERVATION, plugin, entity, author, label, message);
205 }
206
207 static void InventoryHFSMLog(string message = LOG_DEFAULT, string plugin = LOG_DEFAULT, string author = LOG_DEFAULT, string label = LOG_DEFAULT, string entity = LOG_DEFAULT)
208 {
209 LogMessage(LOG_DEBUG_INV_HFSM, plugin, entity, author, label, message);
210 }
211
212 static void QuickbarLog(string message = LOG_DEFAULT, string plugin = LOG_DEFAULT, string author = LOG_DEFAULT, string label = LOG_DEFAULT, string entity = LOG_DEFAULT)
213 {
214 LogMessage(LOG_DEBUG_QUICKBAR, plugin, entity, author, label, message);
215 }
216
217 static void BaseBuildingLog(string message = LOG_DEFAULT, string plugin = LOG_DEFAULT, string author = LOG_DEFAULT, string label = LOG_DEFAULT, string entity = LOG_DEFAULT)
218 {
219 LogMessage(LOG_DEBUG_BASEBUILDING, plugin, entity, author, label, message);
220 }
221
222 static void BleedingChancesLog(string message = LOG_DEFAULT, string plugin = LOG_DEFAULT, string author = LOG_DEFAULT, string label = LOG_DEFAULT, string entity = LOG_DEFAULT)
223 {
224 LogMessage(LOG_DEBUG_BLEEDING_CHANCES, plugin, entity, author, label, message);
225 }
226
227 static void TriggerLog(string message = LOG_DEFAULT, string plugin = LOG_DEFAULT, string author = LOG_DEFAULT, string label = LOG_DEFAULT, string entity = LOG_DEFAULT)
228 {
229 LogMessage(LOG_DEBUG_TRIGGER, plugin, entity, author, label, message);
230 }
231
232 static void ParticleLog(string message = LOG_DEFAULT, Managed caller = null, string function = "", Managed entity = null)
233 {
234 LogMessage(LOG_DEBUG_PARTICLE, GetDebugName(caller), GetDebugName(entity), "", function, message);
235 }
236
237 static void TFLog(string message = LOG_DEFAULT, TestFramework caller = null, string function = "")
238 {
239 LogMessage(LOG_DEBUG_TF, GetDebugName(caller), "", "", function, message);
240 }
241
242 static void WeightLog(string message = LOG_DEFAULT, Managed caller = null, string function = "", Managed entity = null)
243 {
244 /*
245 LogMessage(LOG_DEBUG_WEIGHT, GetDebugName(caller), GetDebugName(entity), "", function, message);
246 */
247 }
248
249 static void MeleeLog(Entity entity, string message = LOG_DEFAULT, string plugin = LOG_DEFAULT, string author = LOG_DEFAULT, string label = LOG_DEFAULT)
250 {
251 string logMessage = string.Format("%1: %2", entity.GetSimulationTimeStamp(), message);
252 LogMessage(LOG_DEBUG_MELEE, plugin, GetDebugName(entity), author, label, logMessage);
253 }
254
255 static void WeatherLog(string message = LOG_DEFAULT, string plugin = LOG_DEFAULT, string author = LOG_DEFAULT, string label = LOG_DEFAULT, string entity = LOG_DEFAULT)
256 {
258 {
259 return;
260 }
261
262 LogMessage(LOG_DEBUG_WEATHER, plugin, entity, author, label, message);
263 }
264
275 static void LogInfo(string message = LOG_DEFAULT, string plugin = LOG_DEFAULT, string author = LOG_DEFAULT, string label = LOG_DEFAULT, string entity = LOG_DEFAULT)
276 {
277 LogMessage(LOG_INFO, plugin, entity, author, label, message);
278 }
279
290 static void LogWarning(string message = LOG_DEFAULT, string plugin = LOG_DEFAULT, string author = LOG_DEFAULT, string label = LOG_DEFAULT, string entity = LOG_DEFAULT)
291 {
292 LogMessage(LOG_WARNING, plugin, entity, author, label, message);
293 }
294
305 static void LogError(string message = LOG_DEFAULT, string plugin = LOG_DEFAULT, string author = LOG_DEFAULT, string label = LOG_DEFAULT, string entity = LOG_DEFAULT)
306 {
307 LogMessage(LOG_ERROR, plugin, entity, author, label, message);
308 }
309
310 static void LogArrayInt(array<int> arr = NULL, string plugin = LOG_DEFAULT, string author = LOG_DEFAULT, string label = LOG_DEFAULT, string entity = LOG_DEFAULT)
311 {
312 if (arr == null)
313 return;
314
315 int nArr = arr.Count();
316 for (int i = 0; i < nArr; ++i)
317 {
318 LogMessage(LOG_DEBUG, plugin, entity, author, label, arr.Get(i).ToString());
319 }
320 }
321
322 static void LogArrayString(array<string> arr = NULL, string plugin = LOG_DEFAULT, string author = LOG_DEFAULT, string label = LOG_DEFAULT, string entity = LOG_DEFAULT)
323 {
324 if (arr == null)
325 return;
326
327 int nArr = arr.Count();
328 for (int i = 0; i < nArr; ++i)
329 {
330 LogMessage(LOG_DEBUG, plugin, entity, author, label, arr.Get(i));
331 }
332 }
333
334 static void ReceivedLogMessageFromServer(string message)
335 {
337 {
338 return;
339 }
340
341 SaveLog(message);
342 }
343
344 static void ClearScriptLogs()
345 {
346 ClearLogs();
347 }
348
349 static Shape DrawBox(vector pos1, vector pos2, int color = 0x1fff7f7f)
350 {
351 return DrawBoxEx(pos1, pos2, color, ShapeFlags.TRANSP|ShapeFlags.NOZWRITE);
352 }
353
354 static Shape DrawBoxEx(vector pos1, vector pos2, int color = 0x1fff7f7f, ShapeFlags flags = ShapeFlags.TRANSP|ShapeFlags.NOZWRITE)
355 {
356 Shape shape = Shape.Create(ShapeType.BBOX, color, flags, pos1, pos2);
357 if (( flags & ShapeFlags.ONCE ) == 0)
358 m_DebugShapes.Insert(shape);
359 return shape;
360 }
361
362 static Shape DrawCube(vector pos, float size = 1, int color = 0x1fff7f7f)
363 {
364 vector min = pos;
365 vector max = pos;
366
367 float size_h = size * 0.5;
368
369 min[0] = min[0] - size_h;
370 min[1] = min[1] - size_h;
371 min[2] = min[2] - size_h;
372
373 max[0] = max[0] + size_h;
374 max[1] = max[1] + size_h;
375 max[2] = max[2] + size_h;
376
377 Shape shape = Shape.Create(ShapeType.DIAMOND, color, ShapeFlags.TRANSP|ShapeFlags.NOZWRITE, min, max);
378 m_DebugShapes.Insert(shape);
379 return shape;
380 }
381
382 static Shape DrawSphere(vector pos, float size = 1, int color = 0x1fff7f7f, ShapeFlags flags = ShapeFlags.TRANSP|ShapeFlags.NOOUTLINE)
383 {
384 Shape shape = Shape.CreateSphere(color, flags, pos, size);
385 if (( flags & ShapeFlags.ONCE ) == 0)
386 m_DebugShapes.Insert(shape);
387 return shape;
388 }
389
390 static Shape DrawFrustum(float horizontalAngle, float verticalAngle, float length, int color = 0x1fff7f7f, ShapeFlags flags = ShapeFlags.TRANSP|ShapeFlags.WIREFRAME)
391 {
392 Shape shape = Shape.CreateFrustum(horizontalAngle, verticalAngle, length, color, flags);
393 if (( flags & ShapeFlags.ONCE ) == 0)
394 m_DebugShapes.Insert(shape);
395 return shape;
396 }
397
398 static Shape DrawCylinder(vector pos, float radius, float height = 1, int color = 0x1fff7f7f, ShapeFlags flags = ShapeFlags.TRANSP|ShapeFlags.NOOUTLINE )
399 {
400 Shape shape = Shape.CreateCylinder(color, flags, pos, radius, height);
401 if (( flags & ShapeFlags.ONCE ) == 0)
402 m_DebugShapes.Insert(shape);
403 return shape;
404 }
405
406 static array<Shape> DrawCone(vector pos, float lenght, float halfAngle, float offsetAngle, int color = 0xFFFFFFFF, int flags = 0)
407 {
408 array<Shape> shapes = new array<Shape>;
409
410 vector endL, endR;
411 Math3D.ConePoints(pos, lenght, halfAngle, offsetAngle, endL, endR);
412
413 // Left side
414 shapes.Insert( Debug.DrawLine(pos, endL, color, flags) );
415 // Rigth side
416 shapes.Insert( Debug.DrawLine(pos, endR, color, flags) );
417 // Top side
418 shapes.Insert( Debug.DrawLine(endL, endR, color, flags) );
419 // Middle (height) line
420 shapes.Insert( Debug.DrawLine(pos, pos + Vector(Math.Cos(offsetAngle), 0, Math.Sin(offsetAngle)).Normalized() * lenght, color, flags) );
421
422 return shapes;
423 }
424
425 static void CleanupDrawShapes(array<Shape> shapes)
426 {
427 foreach (Shape shape : shapes)
428 Debug.RemoveShape(shape);
429
430 shapes.Clear();
431 }
432
434 {
435 foreach (DebugTextScreenSpace text : texts)
436 Debug.RemoveTextSS(text);
437
438 texts.Clear();
439 }
440
442 {
443 foreach (DebugTextWorldSpace text : texts)
444 Debug.RemoveTextWS(text);
445
446 texts.Clear();
447 }
448
461 static Shape DrawLine(vector from, vector to, int color = 0xFFFFFFFF, int flags = 0)
462 {
463 vector pts[2]
464 pts[0] = from;
465 pts[1] = to;
466
467 Shape shape = Shape.CreateLines(color, flags, pts, 2);
468 if (( flags & ShapeFlags.ONCE ) == 0)
469 m_DebugShapes.Insert(shape);
470 //m_DebugShapes.Debug();
471 return shape;
472 }
473
474 static Shape DrawLines(vector[] positions, int count, int color = 0xFFFFFFFF, int flags = 0)
475 {
476
477 Shape shape = Shape.CreateLines(color, flags, positions, count);
478 if (( flags & ShapeFlags.ONCE ) == 0)
479 m_DebugShapes.Insert(shape);
480 return shape;
481 }
482
483 static Shape DrawArrow(vector from, vector to, float size = 0.5, int color = 0xFFFFFFFF, int flags = 0)
484 {
485 Shape shape = Shape.CreateArrow(from, to, size, color, flags);
486 m_DebugShapes.Insert(shape);
487 return shape;
488 }
489
490
491
492 static DebugTextScreenSpace DrawTextSS(string text, float x, float y, float size = 20.0, int color = 0xFFFFFFFF, int bgColor = 0x00000000, DebugTextFlags flags = DebugTextFlags.DEFAULT, int priority = 1000)
493 {
494 DebugTextScreenSpace textSS = DebugTextScreenSpace.Create(text, flags, x, y, size, color, bgColor, priority);
495 if ((flags & DebugTextFlags.ONCE) == 0)
496 m_DebugTextsSS.Insert(textSS);
497
498 return textSS;
499 }
500
501 static DebugTextWorldSpace DrawTextWS(string text, vector position, float size = 20.0, int color = 0xFFFFFFFF, int bgColor = 0x00000000, DebugTextFlags flags = DebugTextFlags.DEFAULT, int priority = 1000)
502 {
503 DebugTextWorldSpace textWS = DebugTextWorldSpace.Create(text, flags, position[0], position[1], position[2], size, color, bgColor, priority);
504 if ((flags & DebugTextFlags.ONCE) == 0)
505 m_DebugTextsWS.Insert(textWS);
506
507 return textWS;
508 }
509
514 static void GetBaseConfigClasses( out TStringArray base_classes )
515 {
516 base_classes.Clear();
517 base_classes.Insert(CFG_VEHICLESPATH);
518 base_classes.Insert(CFG_WEAPONSPATH);
519 base_classes.Insert(CFG_MAGAZINESPATH);
520 base_classes.Insert(CFG_AMMO);
521 base_classes.Insert(CFG_WORLDS);
522 base_classes.Insert(CFG_SURFACES);
523 base_classes.Insert(CFG_SOUND_SETS);
524 base_classes.Insert(CFG_SOUND_SHADERS);
525 base_classes.Insert(CFG_NONAI_VEHICLES);
526 base_classes.Insert(CFG_SOUND_TABLES);
527 }
528
535 static void GetFiltredConfigClasses( string search_string, out TStringArray filtered_classes, bool only_public = true )
536 {
537 TStringArray searching_in = new TStringArray;
538 GetBaseConfigClasses( searching_in );
539
540 filtered_classes.Clear();
541
542 search_string.ToLower();
543
544 int nSearchingIn = searching_in.Count();
545 for ( int s = 0; s < nSearchingIn; ++s )
546 {
547 string config_path = searching_in.Get(s);
548
549 int objects_count = g_Game.ConfigGetChildrenCount(config_path);
550 for (int i = 0; i < objects_count; i++)
551 {
552 string childName;
553 g_Game.ConfigGetChildName(config_path, i, childName);
554
555 if ( only_public )
556 {
557 int scope = g_Game.ConfigGetInt( config_path + " " + childName + " scope" );
558 if ( scope == 0 )
559 {
560 continue;
561 }
562 }
563
564 string nchName = childName;
565 nchName.ToLower();
566
567 if ( nchName.Contains(search_string) != -1)
568 {
569 filtered_classes.Insert(childName);
570 }
571 }
572 }
573 }
574
575 //---------------------------------------------------------------
576 //-------private
577
578 private static bool m_EnabledLogs;
579
580 private static string LogMessage(string level, string plugin, string entity, string author, string label, string message)
581 {
582 if (g_Game == null || !LogManager.IsLogsEnable())
583 return string.Empty;
584
585 bool is_server_log = ( g_Game.IsServer() && g_Game.IsMultiplayer() );
586
587
588 // Formation output to external file
589 // %date{MM-dd HH:mm:ss} | %Enviroment | %Level | %Module | %Entity | %Author | %Label | %Message
590 string date = GetDate();
591 string env = "Client";
592 string msg = string.Empty;
593
594 if ( is_server_log )
595 {
596 env = "Server";
597 }
598
599 msg = string.Format("%1 | %2 | %3 | %4 | %5 | %6 | %7", date, env, level, plugin, entity, label, message);
600
601 if ( is_server_log )
602 {
603 SaveLog(msg);
604
605#ifdef DIAG_DEVELOPER // do not send log to clients on retail
606 Param1<string> msg_p = new Param1<string>(msg);
608#endif
609 }
610 else
611 {
612 SaveLog(msg);
613 }
614
615 return msg;
616 }
617
618 private static void SaveLog(string log_message)
619 {
620 if (log_message.Length() == 0)
621 return;
622
624#ifdef DIAG_DEVELOPER
625#ifndef SERVER
626 CachedObjectsParams.PARAM1_STRING.param1 = log_message;
628#endif
629#endif
630
632#ifdef DIAG_DEVELOPER
634#ifdef LOG_TO_FILE
635 FileHandle fileHandle = OpenFile(GetFileName(), FileMode.APPEND);
636 if (fileHandle != 0)
637 {
638 FPrintln(fileHandle, log_message);
639 CloseFile(fileHandle);
640 }
641#endif
642#endif
643
645#ifdef LOG_TO_RPT
646 PrintToRPT("" + log_message);
647#endif
648
650#ifdef LOG_TO_SCRIPT
651 Print(string.Format("%1", log_message));
652#endif
653 }
654
655 static void ClearLogs()
656 {
657 if (FileExist(GetFileName()))
658 {
659 FileHandle fileHandle = OpenFile(GetFileName(), FileMode.WRITE);
660 if (fileHandle == 0)
661 return;
662
663 FPrintln(fileHandle, "");
664 CloseFile(fileHandle);
665 }
666 }
667
668 static string GetFileName()
669 {
671 }
672
673 private static string GetDate()
674 {
675 int year;
676 int month;
677 int day;
678 int hour;
679 int minute;
680 int second;
681
682 GetYearMonthDay(year, month, day);
683 GetHourMinuteSecond(hour, minute, second);
684
685 string date = month.ToStringLen(2) + "-" + day.ToStringLen(2) + " " + hour.ToStringLen(2) + ":" + minute.ToStringLen(2) + ":" + second.ToStringLen(2);
686
687 return date;
688 }
689};
690
692{
693 static bool m_DoLogs;
699 static bool m_DoSyncLog;
700 static bool m_DoQuickbarLog;
702 static bool m_DoWeaponLog;
703 static bool m_DoWeatherLog;
705
706 static void Init()
707 {
708 #ifdef ENABLE_LOGGING
709 m_DoLogs = true;
710 #else
711 m_DoLogs = IsCLIParam("doLogs");
712 #endif
713
714 m_DoActionDebugLog = IsCLIParam("doActionLog");
715 m_DoSymptomDebugLog = IsCLIParam("doSymptomLog");
716 m_DoInventoryMoveLog = IsCLIParam("doInvMoveLog");
717 m_DoInventoryReservationLog = IsCLIParam("doInvReservLog");
718 m_DoInventoryHFSMLog = IsCLIParam("doInvHFSMLog");
719 m_DoSyncLog = IsCLIParam("doSyncLog");
720 m_DoQuickbarLog = IsCLIParam("doQuickbarLog");
721 m_DoBaseBuildingLog = IsCLIParam("doBaseBuildingLog");
722 m_DoWeaponLog = IsCLIParam("doWeaponLog");
723 m_DoWeatherLog = IsCLIParam("doWeatherLog");
724 }
725
726 static bool IsLogsEnable()
727 {
728 return m_DoLogs;
729 }
730
731 static void SetLogsEnabled(bool enable)
732 {
733 m_DoLogs = enable;
734 }
735
736 static bool IsActionLogEnable()
737 {
738 return m_DoActionDebugLog;
739 }
740
741 static void ActionLogEnable(bool enable)
742 {
743 m_DoActionDebugLog = enable;
744 }
745
747 {
749 }
750
751 static void InventoryMoveLogEnable(bool enable)
752 {
753 m_DoInventoryMoveLog = enable;
754 }
755
760
761 static void InventoryReservationLogEnable(bool enable)
762 {
764 }
765
767 {
769 }
770
771 static void InventoryHFSMLogEnable(bool enable)
772 {
773 m_DoInventoryHFSMLog = enable;
774 }
775
776 static bool IsSyncLogEnable()
777 {
778 return m_DoSyncLog;
779 }
780
781 static void SyncLogEnable(bool enable)
782 {
783 m_DoSyncLog = enable;
784 }
785
787 {
788 return m_DoQuickbarLog;
789 }
790
791 static void QuickbarLogEnable(bool enable)
792 {
793 m_DoQuickbarLog = enable;
794 }
795
797 {
798 return m_DoBaseBuildingLog;
799 }
800
801 static void BaseBuildingLogEnable(bool enable)
802 {
803 m_DoBaseBuildingLog = enable;
804 }
805
806 static bool IsSymptomLogEnable()
807 {
808 return m_DoSymptomDebugLog;
809 }
810
811 static void SymptomLogEnable(bool enable)
812 {
813 m_DoSymptomDebugLog = enable;
814 }
815
816 static bool IsWeaponLogEnable()
817 {
818 return m_DoWeaponLog;
819 }
820
821 static void WeaponLogEnable(bool enable)
822 {
823 m_DoWeaponLog = enable;
824 }
825
827 {
828 return m_DoWeatherLog;
829 }
830
832 {
834 }
835
836 static void BleedingChancesLogEnable(bool enable)
837 {
838 m_DoBleedingChanceLog = enable;
839 }
840}
841
842enum WeightDebugType
843{
844 NONE = 0,
849}
850
851class WeightDebug
852{
854 static WeightDebugType m_VerbosityFlags;
855
856 //-------------------------------------------------------------
858 {
859 if (!m_WeightDebugData.Get(entity))
860 {
861 WeightDebugData data = new WeightDebugData(entity);
862 m_WeightDebugData.Insert(entity,data);
863 return data;
864 }
865 return m_WeightDebugData.Get(entity);
866 }
867 //-------------------------------------------------------------
868 static void ClearWeightDebug()
869 {
870 m_WeightDebugData.Clear();
871 }
872 //-------------------------------------------------------------
873 static void PrintAll(EntityAI entity)
874 {
875 GameInventory inv = entity.GetInventory();
876 if (!inv)
877 return;
879 inv.EnumerateInventory(InventoryTraversalType.PREORDER, items);
880 int nItems = items.Count();
881 for(int i = 0; i < nItems; ++i)
882 {
883 EntityAI item = items.Get(i);
884 WeightDebugData data = m_WeightDebugData.Get(item);
885 if (data)
886 {
887 data.Output();
888 }
889 }
890 }
891 //-------------------------------------------------------------
892 static void SetVerbosityFlags(WeightDebugType type)
893 {
894 m_VerbosityFlags = type;
895 }
896}
897
899{
901 string m_Weight;
904 //-------------------------------------------------------------
906 {
907 m_Classname = entity.GetType();
908 m_InventoryDepth = entity.GetHierarchyLevel();
909 }
910 //-------------------------------------------------------------
911 void SetWeight(float weight)
912 {
913 m_Weight = weight.ToString();
914 }
915 //-------------------------------------------------------------
916 void SetCalcDetails(string details)
917 {
918 m_CalcDetails = details;
919 }
920
921 //-------------------------------------------------------------
922 void AddCalcDetails(string details)
923 {
924 m_CalcDetails += "+ "+details;
925 }
926 //-------------------------------------------------------------
927 void Output()
928 {
929 string spaces;
930 for(int i = 0; i < m_InventoryDepth;i++)
931 spaces+="--------";
932
933 Print(spaces+">" + m_Classname + " Overall entity weight: "+ m_Weight + " Calculation details:" + m_CalcDetails);
934 }
935 //-------------------------------------------------------------
936
937}
static void ClearWeightDebug()
Определения 3_Game/DayZ/tools/Debug.c:868
class LogManager RECALC_FORCED
static void PrintAll(EntityAI entity)
Определения 3_Game/DayZ/tools/Debug.c:873
static WeightDebugData GetWeightDebug(EntityAI entity)
Определения 3_Game/DayZ/tools/Debug.c:857
static void SetVerbosityFlags(WeightDebugType type)
Определения 3_Game/DayZ/tools/Debug.c:892
class LogManager SET_DIRTY_FLAG
class LogManager DUMP_STACK
class LogManager RECALC_DIRTY
static WeightDebugType m_VerbosityFlags
Определения 3_Game/DayZ/tools/Debug.c:854
class LogManager m_WeightDebugData
class LogManager EntityAI
map
Определения ControlsXboxNew.c:4
DayZGame g_Game
Определения DayZGame.c:3942
Dispatcher GetDispatcher()
Определения Dispatcher.c:20
const CallID CALL_ID_SEND_LOG
Определения Dispatcher.c:3
const CallID CALL_ID_SCR_CNSL_ADD_PRINT
Определения Dispatcher.c:6
Param CallMethod(CallID call_id, Param params)
Определения Dispatcher.c:36
Icon x
Icon y
void TestFramework()
Определения TestFramework.c:217
static ref Param1< string > PARAM1_STRING
Определения UtilityClasses.c:14
static ref array< Shape > m_DebugShapes
Определения 3_Game/DayZ/tools/Debug.c:24
static const string LOG_DEBUG_MELEE
Определения 3_Game/DayZ/tools/Debug.c:16
static const string LOG_DEBUG_BLEEDING_CHANCES
Определения 3_Game/DayZ/tools/Debug.c:11
static void CleanupTextsWS(array< ref DebugTextWorldSpace > texts)
Определения 3_Game/DayZ/tools/Debug.c:441
static void BaseBuildingLog(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Определения 3_Game/DayZ/tools/Debug.c:217
static const string LOG_DEBUG_INV_RESERVATION
Определения 3_Game/DayZ/tools/Debug.c:7
static void TFLog(string message=LOG_DEFAULT, TestFramework caller=null, string function="")
Определения 3_Game/DayZ/tools/Debug.c:237
static Shape DrawLines(vector[] positions, int count, int color=0xFFFFFFFF, int flags=0)
Определения 3_Game/DayZ/tools/Debug.c:474
static void InitCanvas()
Определения 3_Game/DayZ/tools/Debug.c:43
static void RemoveTextWS(out DebugTextWorldSpace text)
Определения 3_Game/DayZ/tools/Debug.c:152
static bool m_EnabledLogs
Определения 3_Game/DayZ/tools/Debug.c:578
static void QuickbarLog(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Определения 3_Game/DayZ/tools/Debug.c:212
static const string LOG_DEBUG_ACTION
Определения 3_Game/DayZ/tools/Debug.c:4
static void GetBaseConfigClasses(out TStringArray base_classes)
Returns some of base config classes strings like CfgVehicles, CfgWeapons, etc. for searching purposes...
Определения 3_Game/DayZ/tools/Debug.c:514
static const string LOG_DEBUG
Определения 3_Game/DayZ/tools/Debug.c:3
static CanvasWidget m_CanvasDebug
Определения 3_Game/DayZ/tools/Debug.c:29
static const string LOG_DEBUG_PARTICLE
Определения 3_Game/DayZ/tools/Debug.c:13
static void SymptomLog(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Определения 3_Game/DayZ/tools/Debug.c:192
static Shape DrawCylinder(vector pos, float radius, float height=1, int color=0x1fff7f7f, ShapeFlags flags=ShapeFlags.TRANSP|ShapeFlags.NOOUTLINE)
Определения 3_Game/DayZ/tools/Debug.c:398
static void DestroyAll()
Определения 3_Game/DayZ/tools/Debug.c:87
static DebugTextWorldSpace DrawTextWS(string text, vector position, float size=20.0, int color=0xFFFFFFFF, int bgColor=0x00000000, DebugTextFlags flags=DebugTextFlags.DEFAULT, int priority=1000)
Определения 3_Game/DayZ/tools/Debug.c:501
static void InventoryReservationLog(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Определения 3_Game/DayZ/tools/Debug.c:202
static void ParticleLog(string message=LOG_DEFAULT, Managed caller=null, string function="", Managed entity=null)
Определения 3_Game/DayZ/tools/Debug.c:232
static Shape DrawBox(vector pos1, vector pos2, int color=0x1fff7f7f)
Определения 3_Game/DayZ/tools/Debug.c:349
static ref array< ref DebugTextScreenSpace > m_DebugTextsSS
Определения 3_Game/DayZ/tools/Debug.c:25
static string GetFileName()
Определения 3_Game/DayZ/tools/Debug.c:668
static const string LOG_DEBUG_WEIGHT
Определения 3_Game/DayZ/tools/Debug.c:15
static const string LOG_DEBUG_TF
Определения 3_Game/DayZ/tools/Debug.c:14
static void LogWarning(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Prints debug message as warning message.
Определения 3_Game/DayZ/tools/Debug.c:290
static void CanvasDrawLine(float x1, float y1, float x2, float y2, float width, int color)
Определения 3_Game/DayZ/tools/Debug.c:58
static void ClearLogs()
Определения 3_Game/DayZ/tools/Debug.c:655
static void LogInfo(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Prints debug message with normal prio.
Определения 3_Game/DayZ/tools/Debug.c:275
static const string LOG_DEBUG_WEATHER
Определения 3_Game/DayZ/tools/Debug.c:17
static DebugTextScreenSpace DrawTextSS(string text, float x, float y, float size=20.0, int color=0xFFFFFFFF, int bgColor=0x00000000, DebugTextFlags flags=DebugTextFlags.DEFAULT, int priority=1000)
Определения 3_Game/DayZ/tools/Debug.c:492
static void BleedingChancesLog(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Определения 3_Game/DayZ/tools/Debug.c:222
static Shape DrawSphere(vector pos, float size=1, int color=0x1fff7f7f, ShapeFlags flags=ShapeFlags.TRANSP|ShapeFlags.NOOUTLINE)
Определения 3_Game/DayZ/tools/Debug.c:382
static void DestroyAllTextWS()
Определения 3_Game/DayZ/tools/Debug.c:107
static void GetFiltredConfigClasses(string search_string, out TStringArray filtered_classes, bool only_public=true)
Returns config classes containing search_string in name.
Определения 3_Game/DayZ/tools/Debug.c:535
static void RemoveTextSS(out DebugTextScreenSpace text)
Определения 3_Game/DayZ/tools/Debug.c:132
static void WeightLog(string message=LOG_DEFAULT, Managed caller=null, string function="", Managed entity=null)
Определения 3_Game/DayZ/tools/Debug.c:242
static void LogError(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Prints debug message as error message.
Определения 3_Game/DayZ/tools/Debug.c:305
static void MeleeLog(Entity entity, string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT)
Определения 3_Game/DayZ/tools/Debug.c:249
static Shape DrawFrustum(float horizontalAngle, float verticalAngle, float length, int color=0x1fff7f7f, ShapeFlags flags=ShapeFlags.TRANSP|ShapeFlags.WIREFRAME)
Определения 3_Game/DayZ/tools/Debug.c:390
static const string LOG_DEBUG_BASEBUILDING
Определения 3_Game/DayZ/tools/Debug.c:10
static const string LOG_DEBUG_TRIGGER
Определения 3_Game/DayZ/tools/Debug.c:12
static void SaveLog(string log_message)
Определения 3_Game/DayZ/tools/Debug.c:618
static const string LOG_DEBUG_QUICKBAR
Определения 3_Game/DayZ/tools/Debug.c:9
static Shape DrawCube(vector pos, float size=1, int color=0x1fff7f7f)
Определения 3_Game/DayZ/tools/Debug.c:362
static const string LOG_INFO
Определения 3_Game/DayZ/tools/Debug.c:19
static void ClearCanvas()
Определения 3_Game/DayZ/tools/Debug.c:52
static const string LOG_DEBUG_SYMPTOM
Определения 3_Game/DayZ/tools/Debug.c:5
static void ReceivedLogMessageFromServer(string message)
Определения 3_Game/DayZ/tools/Debug.c:334
static Shape DrawArrow(vector from, vector to, float size=0.5, int color=0xFFFFFFFF, int flags=0)
Определения 3_Game/DayZ/tools/Debug.c:483
static void TriggerLog(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Определения 3_Game/DayZ/tools/Debug.c:227
static void CleanupDrawShapes(array< Shape > shapes)
Определения 3_Game/DayZ/tools/Debug.c:425
static const string LOG_DEBUG_INV_MOVE
Определения 3_Game/DayZ/tools/Debug.c:6
static array< Shape > DrawCone(vector pos, float lenght, float halfAngle, float offsetAngle, int color=0xFFFFFFFF, int flags=0)
Определения 3_Game/DayZ/tools/Debug.c:406
static void CleanupTextsSS(array< ref DebugTextScreenSpace > texts)
Определения 3_Game/DayZ/tools/Debug.c:433
static void CanvasDrawPoint(float x1, float y1, int color)
Draws a "point" on the screen at x,y coordinates Debug.ClearCanvas(); for(int i = 0; i < 700;i++) { f...
Определения 3_Game/DayZ/tools/Debug.c:75
static const string LOG_WARNING
Определения 3_Game/DayZ/tools/Debug.c:20
static void InventoryHFSMLog(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Определения 3_Game/DayZ/tools/Debug.c:207
static string GetDate()
Определения 3_Game/DayZ/tools/Debug.c:673
static void DestroyAllShapes()
Определения 3_Game/DayZ/tools/Debug.c:94
static Shape DrawBoxEx(vector pos1, vector pos2, int color=0x1fff7f7f, ShapeFlags flags=ShapeFlags.TRANSP|ShapeFlags.NOZWRITE)
Определения 3_Game/DayZ/tools/Debug.c:354
static void WeatherLog(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Определения 3_Game/DayZ/tools/Debug.c:255
static void Log(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Prints debug message with normal prio.
Определения 3_Game/DayZ/tools/Debug.c:182
static void LogArrayInt(array< int > arr=NULL, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Определения 3_Game/DayZ/tools/Debug.c:310
static void ClearScriptLogs()
Определения 3_Game/DayZ/tools/Debug.c:344
static const string LOG_DEFAULT
Определения 3_Game/DayZ/tools/Debug.c:22
static ref array< ref DebugTextWorldSpace > m_DebugTextsWS
Определения 3_Game/DayZ/tools/Debug.c:26
static Widget m_DebugLayoutCanvas
Определения 3_Game/DayZ/tools/Debug.c:28
static void Init()
Определения 3_Game/DayZ/tools/Debug.c:80
static void LogArrayString(array< string > arr=NULL, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Определения 3_Game/DayZ/tools/Debug.c:322
static void InventoryMoveLog(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Определения 3_Game/DayZ/tools/Debug.c:197
static const string LOG_ERROR
Определения 3_Game/DayZ/tools/Debug.c:21
static void RemoveShape(out Shape shape)
Определения 3_Game/DayZ/tools/Debug.c:112
static string GetDebugName(Managed entity)
Определения 3_Game/DayZ/tools/Debug.c:31
static const string LOG_DEBUG_INV_HFSM
Определения 3_Game/DayZ/tools/Debug.c:8
static Shape DrawLine(vector from, vector to, int color=0xFFFFFFFF, int flags=0)
Определения 3_Game/DayZ/tools/Debug.c:461
static string LogMessage(string level, string plugin, string entity, string author, string label, string message)
DEPRECATED.
Определения 3_Game/DayZ/tools/Debug.c:580
static void ActionLog(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Определения 3_Game/DayZ/tools/Debug.c:187
static void DestroyAllTextSS()
Определения 3_Game/DayZ/tools/Debug.c:102
Определения 3_Game/DayZ/tools/Debug.c:2
static proto DebugTextScreenSpace Create(string text, DebugTextFlags flags, float x, float y, float size=20.0, int color=0xFFFFFFFF, int bgColor=0x00000000, int priority=1000)
static proto DebugTextWorldSpace Create(string text, DebugTextFlags flags, float x, float y, float z, float size=20.0, int color=0xFFFFFFFF, int bgColor=0x00000000, int priority=1000)
Param CallMethod(CallID call_id, Param params)
Определения Dispatcher.c:15
Определения Camera.c:2
proto native bool EnumerateInventory(InventoryTraversalType tt, out array< EntityAI > items)
enumerate inventory using traversal type and filling items array
script counterpart to engine's class Inventory
static void InventoryHFSMLogEnable(bool enable)
Определения 3_Game/DayZ/tools/Debug.c:771
static void InventoryReservationLogEnable(bool enable)
Определения 3_Game/DayZ/tools/Debug.c:761
static void SymptomLogEnable(bool enable)
Определения 3_Game/DayZ/tools/Debug.c:811
static void SyncLogEnable(bool enable)
Определения 3_Game/DayZ/tools/Debug.c:781
static bool IsWeaponLogEnable()
Определения 3_Game/DayZ/tools/Debug.c:816
static bool m_DoSyncLog
Определения 3_Game/DayZ/tools/Debug.c:699
static void BleedingChancesLogEnable(bool enable)
Определения 3_Game/DayZ/tools/Debug.c:836
static bool m_DoActionDebugLog
Определения 3_Game/DayZ/tools/Debug.c:694
static bool m_DoLogs
Определения 3_Game/DayZ/tools/Debug.c:693
static bool m_DoInventoryHFSMLog
Определения 3_Game/DayZ/tools/Debug.c:698
static void WeaponLogEnable(bool enable)
Определения 3_Game/DayZ/tools/Debug.c:821
static void Init()
Определения 3_Game/DayZ/tools/Debug.c:706
static bool m_DoSymptomDebugLog
Определения 3_Game/DayZ/tools/Debug.c:695
static bool IsBaseBuildingLogEnable()
Определения 3_Game/DayZ/tools/Debug.c:796
static bool m_DoInventoryReservationLog
Определения 3_Game/DayZ/tools/Debug.c:697
static bool IsWeatherLogEnabled()
Определения 3_Game/DayZ/tools/Debug.c:826
static void SetLogsEnabled(bool enable)
Определения 3_Game/DayZ/tools/Debug.c:731
static bool IsInventoryReservationLogEnable()
Определения 3_Game/DayZ/tools/Debug.c:756
static bool IsSymptomLogEnable()
Определения 3_Game/DayZ/tools/Debug.c:806
static bool IsSyncLogEnable()
Определения 3_Game/DayZ/tools/Debug.c:776
static bool IsInventoryHFSMLogEnable()
Определения 3_Game/DayZ/tools/Debug.c:766
static bool IsLogsEnable()
Определения 3_Game/DayZ/tools/Debug.c:726
static bool m_DoBleedingChanceLog
Определения 3_Game/DayZ/tools/Debug.c:704
static bool m_DoBaseBuildingLog
Определения 3_Game/DayZ/tools/Debug.c:701
static void QuickbarLogEnable(bool enable)
Определения 3_Game/DayZ/tools/Debug.c:791
static void ActionLogEnable(bool enable)
Определения 3_Game/DayZ/tools/Debug.c:741
static void InventoryMoveLogEnable(bool enable)
Определения 3_Game/DayZ/tools/Debug.c:751
static bool m_DoWeatherLog
Определения 3_Game/DayZ/tools/Debug.c:703
static bool IsBleedingChancesLogEnable()
Определения 3_Game/DayZ/tools/Debug.c:831
static bool IsInventoryMoveLogEnable()
Определения 3_Game/DayZ/tools/Debug.c:746
static bool IsActionLogEnable()
Определения 3_Game/DayZ/tools/Debug.c:736
static void BaseBuildingLogEnable(bool enable)
Определения 3_Game/DayZ/tools/Debug.c:801
static bool m_DoWeaponLog
Определения 3_Game/DayZ/tools/Debug.c:702
static bool IsQuickbarLogEnable()
Определения 3_Game/DayZ/tools/Debug.c:786
static bool m_DoInventoryMoveLog
Определения 3_Game/DayZ/tools/Debug.c:696
static bool m_DoQuickbarLog
Определения 3_Game/DayZ/tools/Debug.c:700
TODO doc.
Определения EnScript.c:118
Определения EnMath3D.c:28
Определения EnMath.c:7
Определения ObjectTyped.c:2
string m_Weight
Определения 3_Game/DayZ/tools/Debug.c:901
string m_CalcDetails
Определения 3_Game/DayZ/tools/Debug.c:903
void AddCalcDetails(string details)
Определения 3_Game/DayZ/tools/Debug.c:922
string m_Classname
Определения 3_Game/DayZ/tools/Debug.c:900
void SetCalcDetails(string details)
Определения 3_Game/DayZ/tools/Debug.c:916
void Output()
Определения 3_Game/DayZ/tools/Debug.c:927
void SetWeight(float weight)
Определения 3_Game/DayZ/tools/Debug.c:911
void WeightDebugData(EntityAI entity)
Определения 3_Game/DayZ/tools/Debug.c:905
int m_InventoryDepth
Определения 3_Game/DayZ/tools/Debug.c:902
Определения EnWidgets.c:190
Result for an object found in CGame.IsBoxCollidingGeometryProxy.
proto string ToString(bool simple=true)
Определения CachedEquipmentStorage.c:4
Определения EnConvert.c:119
override string GetDebugName()
Определения dayzplayer.c:1173
InventoryTraversalType
tree traversal type, for more see http://en.wikipedia.org/wiki/Tree_traversal
Определения gameplay.c:6
const string CFG_FILE_SCRIPT_LOG_EXT
Определения 3_Game/DayZ/constants.c:248
proto void Print(void var)
Prints content of variable to console/log.
DebugTextFlags
Определения DebugTextFlags.c:8
proto void PrintToRPT(void var)
Prints content of variable to RPT file (performance warning - each write means fflush!...
ShapeType
Определения EnDebug.c:116
ShapeFlags
Определения EnDebug.c:126
class DiagMenu Shape
don't call destructor directly. Use Destroy() instead
array< string > TStringArray
Определения EnScript.c:712
FileMode
Определения EnSystem.c:383
proto void CloseFile(FileHandle file)
Close the File.
proto FileHandle OpenFile(string name, FileMode mode)
Opens File.
int[] FileHandle
Определения EnSystem.c:390
proto bool FileExist(string name)
Check existence of file.
proto void FPrintln(FileHandle file, void var)
Write to file and add new line.
proto native vector Vector(float x, float y, float z)
Vector constructor from components.
static proto void ConePoints(vector origin, float length, float halfAngle, float angleOffset, out vector leftPoint, out vector rightPoint)
Calculates the points of a right 2D cone in 3D space.
static proto float Cos(float angle)
Returns cosinus of angle in radians.
static proto float Sin(float angle)
Returns sinus of angle in radians.
const string CFG_SOUND_SETS
Определения 3_Game/DayZ/constants.c:228
const string CFG_AMMO
Определения 3_Game/DayZ/constants.c:223
const string CFG_VEHICLESPATH
Определения 3_Game/DayZ/constants.c:220
const string CFG_NONAI_VEHICLES
Определения 3_Game/DayZ/constants.c:229
const string CFG_SOUND_SHADERS
Определения 3_Game/DayZ/constants.c:227
const string CFG_SOUND_TABLES
Определения 3_Game/DayZ/constants.c:230
const string CFG_SURFACES
Определения 3_Game/DayZ/constants.c:225
const string CFG_WEAPONSPATH
Определения 3_Game/DayZ/constants.c:221
const string CFG_WORLDS
Определения 3_Game/DayZ/constants.c:224
const string CFG_MAGAZINESPATH
Определения 3_Game/DayZ/constants.c:222
@ NONE
body is not in simulation, nor in collision world
Определения SimulationState.c:15
proto native int Length()
Returns length of string.
bool Contains(string sample)
Returns true if sample is substring of string.
Определения EnString.c:286
static const string Empty
Определения EnString.c:7
static proto string Format(string fmt, void param1=NULL, void param2=NULL, void param3=NULL, void param4=NULL, void param5=NULL, void param6=NULL, void param7=NULL, void param8=NULL, void param9=NULL)
Gets n-th character from string.
proto int ToLower()
Changes string to lowercase. Returns length.
proto void GetYearMonthDay(out int year, out int month, out int day)
Returns system date.
proto void GetHourMinuteSecond(out int hour, out int minute, out int second)
Returns system time.
proto native bool IsCLIParam(string param)
Returns if command line argument is present.