DayZ 1.26
DayZ Explorer by KGB
Загрузка...
Поиск...
Не найдено
Класс ScriptConsoleGeneralTab
+ Граф наследования:ScriptConsoleGeneralTab:

Защищенные члены

void ScriptConsoleGeneralTab (Widget root, ScriptConsole console, Widget button, ScriptConsoleTabBase parent=null)
 
void ~ScriptConsoleGeneralTab ()
 
void Init ()
 
void RefreshDateWidgets (int year, int month, int day, int hour, int minute)
 
bool IsLocationNameAvailable (string name)
 
void LateInit ()
 
void Teleport (PlayerBase player, vector position)
 
void ProcessTeleportText (PlayerBase player)
 
array< floatTextToNumbersArray (string text)
 
void RefreshLocations ()
 
string GetCurrentLocationName ()
 
vector GetCurrentLocationPos ()
 
void GetCurrentPositionData (out LocationParams data)
 
bool IsCurrentPositionCustom ()
 
int GetCurrentPositionIndex ()
 
bool IsCurrentPositionValid ()
 
void UpdateHudDebugSetting ()
 
void RefreshPlayerPosEditBoxes ()
 
void UpdateTime (bool slider_used)
 
void UpdateMousePos ()
 
void SetMapPos (vector pos)
 
void SetDir (vector dir)
 
vector GetMapPos ()
 
override bool OnMouseButtonDown (Widget w, int x, int y, int button)
 
override bool OnKeyDown (Widget w, int x, int y, int key)
 
override bool OnChange (Widget w, int x, int y, bool finished)
 
override bool OnItemSelected (Widget w, int x, int y, int row, int column, int oldRow, int oldColumn)
 
override bool OnDoubleClick (Widget w, int x, int y, int button)
 
override bool OnClick (Widget w, int x, int y, int button)
 
override void OnRPCEx (int rpc_type, ParamsReadContext ctx)
 
override void Update (float timeslice)
 

Защищенные данные

const string NUMERIC_LETTERS = "0123456789.-"
 
vector m_MapPos
 
bool m_PlayerPosRefreshBlocked
 
ref array< ref RemotePlayerStatDebugm_PlayerDebugStats = new array<ref RemotePlayerStatDebug>
 
MissionGameplay m_MissionGameplay
 
PluginDeveloper m_Developer
 
SliderWidget m_TimeSlider
 
ref Timer m_LateInit = new Timer()
 
bool m_UpdatePlayerPositions
 
bool m_InitialOpen = true
 
EditBoxWidget m_TeleportHeading
 
EditBoxWidget m_TeleportXYZ
 
EditBoxWidget m_DateYear
 
EditBoxWidget m_DateMonth
 
EditBoxWidget m_DateDay
 
EditBoxWidget m_DateHour
 
EditBoxWidget m_DateMinute
 
ButtonWidget m_LocationAddButton
 
ButtonWidget m_LocationRemoveButton
 
ButtonWidget m_TeleportButton
 
ButtonWidget m_ButtonCopyPos
 
ButtonWidget m_DiagDrawButton
 
ButtonWidget m_DiagToggleButton
 
CheckBoxWidget m_LogsEnabled
 
CheckBoxWidget m_HudDCharStats
 
CheckBoxWidget m_HudDCharLevels
 
CheckBoxWidget m_HudDCharStomach
 
CheckBoxWidget m_HudDCharModifiers
 
CheckBoxWidget m_HudDCharAgents
 
CheckBoxWidget m_HudDCharDebug
 
CheckBoxWidget m_HudDFreeCamCross
 
CheckBoxWidget m_HudDVersion
 
CheckBoxWidget m_HudDHealth
 
CheckBoxWidget m_ShowOthers
 
CheckBoxWidget m_HudDTemperature
 
MapWidget m_DebugMapWidget
 
TextWidget m_PlayerCurPos
 
TextWidget m_PlayerCurDir
 
TextWidget m_MouseCurPos
 
TextWidget m_PlayerMouseDiff
 
TextListboxWidget m_DiagToggleTextListbox
 
TextListboxWidget m_PositionsListbox
 
TextListboxWidget m_DiagDrawmodeTextListbox
 
TextListboxWidget m_HelpTextListboxWidget
 

Статические защищенные данные

vector m_LastEditPos = vector.Zero
 
vector m_LastEditDir = vector.Zero
 
static float DEBUG_MAP_ZOOM = 1
 
static bool SHOW_OTHERS = 0
 

Закрытые статические данные

static int m_ObjectsScope = 2
 

Дополнительные унаследованные члены

- Закрытые члены унаследованные от ScriptConsoleTabBase
void ScriptConsoleTabBase (Widget root, ScriptConsole console, Widget button, ScriptConsoleTabBase parent=null)
 
void Init (int id)
 
int GetID ()
 
Widget GetRoot ()
 
bool IsSelected ()
 
void Select (bool select, ScriptConsoleTabBase selectedHandler)
 
void OnSelected ()
 
void Show (bool show, ScriptConsoleTabBase selectedHandler)
 
Widget GetButton ()
 
void Update (float timeslice)
 
bool OnChange (Widget w, int x, int y, bool finished)
 
bool OnClick (Widget w, int x, int y, int button)
 
bool OnItemSelected (Widget w, int x, int y, int row, int column, int oldRow, int oldColumn)
 
bool OnKeyDown (Widget w, int x, int y, int key)
 
bool OnDoubleClick (Widget w, int x, int y, int button)
 
void OnRPCEx (int rpc_type, ParamsReadContext ctx)
 
bool OnMouseButtonDown (Widget w, int x, int y, int button)
 
bool OnKeyPress (Widget w, int x, int y, int key)
 
void AddItemToClipboard (TextListboxWidget text_listbox_widget)
 
- Закрытые данные унаследованные от ScriptConsoleTabBase
int m_Id
 
bool m_IsSelected
 
bool m_IsShiftDown
 
Widget m_ParentRoot
 
Widget m_Root
 
Widget m_Button
 
ScriptConsole m_ScriptConsole
 
ScriptConsoleTabBase m_Parent
 
PluginConfigDebugProfile m_ConfigDebugProfile
 
PluginConfigDebugProfileFixed m_ConfigDebugProfileFixed
 

Подробное описание

Конструктор(ы)

◆ ScriptConsoleGeneralTab()

void ScriptConsoleGeneralTab ( Widget root,
ScriptConsole console,
Widget button,
ScriptConsoleTabBase parent = null )
inlineprotected
70 {
71 m_MissionGameplay = MissionGameplay.Cast(GetGame().GetMission());
72
73 m_DiagToggleTextListbox = TextListboxWidget.Cast(root.FindAnyWidget("DiagToggle"));
74 m_DiagToggleButton = ButtonWidget.Cast(root.FindAnyWidget("DiagToggleButton"));
75
76 m_DiagDrawmodeTextListbox = TextListboxWidget.Cast(root.FindAnyWidget("DiagDrawmode"));
77 m_DiagDrawButton = ButtonWidget.Cast(root.FindAnyWidget("DiagDrawButton"));
78
79 m_DebugMapWidget = MapWidget.Cast(root.FindAnyWidget("MapWidget"));
80
81 m_PositionsListbox = TextListboxWidget.Cast(root.FindAnyWidget("PositionsList"));
82 m_TeleportButton = ButtonWidget.Cast(root.FindAnyWidget("ButtonTeleport"));
83 m_ButtonCopyPos = ButtonWidget.Cast(root.FindAnyWidget("Button_CopyPos"));
84
85 m_TeleportHeading = EditBoxWidget.Cast(root.FindAnyWidget("TeleportHeading"));
86 m_TeleportXYZ = EditBoxWidget.Cast(root.FindAnyWidget("TeleportXYZ"));
87 m_PlayerCurPos = TextWidget.Cast(root.FindAnyWidget("PlayerPosLabel"));
88 m_PlayerCurDir = TextWidget.Cast(root.FindAnyWidget("PlayerDirLabel"));
89 m_PlayerMouseDiff = TextWidget.Cast(root.FindAnyWidget("PlayerMouseDiff"));
90 m_MouseCurPos = TextWidget.Cast(root.FindAnyWidget("MousePosLabel"));
91 m_LogsEnabled = CheckBoxWidget.Cast(root.FindAnyWidget("cbx_LogsEnabled"));
92 m_HudDCharStats = CheckBoxWidget.Cast(root.FindAnyWidget("cbx_CharacterStats"));
93 m_HudDCharLevels = CheckBoxWidget.Cast(root.FindAnyWidget("cbx_CharacterLevels"));
94 m_HudDCharStomach = CheckBoxWidget.Cast(root.FindAnyWidget("cbx_CharacterStomach"));
95 m_HudDCharModifiers = CheckBoxWidget.Cast(root.FindAnyWidget("cbx_CharacterModifiers"));
96 m_HudDCharAgents = CheckBoxWidget.Cast(root.FindAnyWidget("cbx_CharacterAgents"));
97 m_HudDCharDebug = CheckBoxWidget.Cast(root.FindAnyWidget("cbx_CharacterDebug"));
98 m_HudDFreeCamCross = CheckBoxWidget.Cast(root.FindAnyWidget("cbx_FreeCamCross"));
99 m_HudDTemperature = CheckBoxWidget.Cast(root.FindAnyWidget("cbx_Temp"));
100 m_HudDVersion = CheckBoxWidget.Cast(root.FindAnyWidget("cbx_Version"));
101 m_HudDHealth = CheckBoxWidget.Cast(root.FindAnyWidget("cbx_Health"));
102
103 m_LocationAddButton = ButtonWidget.Cast(root.FindAnyWidget("AddButton"));
104 //m_LocationAddButton.SetHandler(ToolTipEventHandler.GetInstance());
105 m_LocationRemoveButton = ButtonWidget.Cast(root.FindAnyWidget("RemoveButton"));
106
107 m_TimeSlider = SliderWidget.Cast(root.FindAnyWidget("TimeSlider"));
108 m_DateYear = EditBoxWidget.Cast(root.FindAnyWidget("DateYear"));
109 m_DateMonth = EditBoxWidget.Cast(root.FindAnyWidget("DateMonth"));
110 m_DateDay = EditBoxWidget.Cast(root.FindAnyWidget("DateDay"));
111 m_DateHour = EditBoxWidget.Cast(root.FindAnyWidget("DateHour"));
112 m_DateMinute = EditBoxWidget.Cast(root.FindAnyWidget("DateMinute"));
113
114
115 m_ShowOthers = CheckBoxWidget.Cast(root.FindAnyWidget("ShowOthersCheckbox"));
116
117 m_HelpTextListboxWidget = TextListboxWidget.Cast(root.FindAnyWidget("HelpTextListboxWidget"));
118 m_Developer = PluginDeveloper.Cast(GetPlugin(PluginDeveloper));
119
120 Init();
121 LateInit();
122
123 }
PluginBase GetPlugin(typename plugin_type)
Definition PluginManager.c:316
Definition EnWidgets.c:354
Definition gameplay.c:322
Definition EntityAI.c:95
TextListboxWidget m_DiagDrawmodeTextListbox
Definition ScriptConsoleGeneralTab.c:64
EditBoxWidget m_DateHour
Definition ScriptConsoleGeneralTab.c:31
SliderWidget m_TimeSlider
Definition ScriptConsoleGeneralTab.c:19
CheckBoxWidget m_HudDCharStats
Definition ScriptConsoleGeneralTab.c:42
MissionGameplay m_MissionGameplay
Definition ScriptConsoleGeneralTab.c:16
EditBoxWidget m_DateMinute
Definition ScriptConsoleGeneralTab.c:32
PluginDeveloper m_Developer
Definition ScriptConsoleGeneralTab.c:17
void Init()
Definition ScriptConsoleGeneralTab.c:134
CheckBoxWidget m_HudDTemperature
Definition ScriptConsoleGeneralTab.c:54
CheckBoxWidget m_ShowOthers
Definition ScriptConsoleGeneralTab.c:52
EditBoxWidget m_DateMonth
Definition ScriptConsoleGeneralTab.c:29
CheckBoxWidget m_HudDHealth
Definition ScriptConsoleGeneralTab.c:50
EditBoxWidget m_TeleportHeading
Definition ScriptConsoleGeneralTab.c:26
ButtonWidget m_LocationRemoveButton
Definition ScriptConsoleGeneralTab.c:35
EditBoxWidget m_TeleportXYZ
Definition ScriptConsoleGeneralTab.c:27
CheckBoxWidget m_HudDCharModifiers
Definition ScriptConsoleGeneralTab.c:45
CheckBoxWidget m_HudDCharStomach
Definition ScriptConsoleGeneralTab.c:44
CheckBoxWidget m_LogsEnabled
Definition ScriptConsoleGeneralTab.c:41
ButtonWidget m_TeleportButton
Definition ScriptConsoleGeneralTab.c:36
CheckBoxWidget m_HudDCharAgents
Definition ScriptConsoleGeneralTab.c:46
EditBoxWidget m_DateYear
Definition ScriptConsoleGeneralTab.c:28
TextWidget m_PlayerCurPos
Definition ScriptConsoleGeneralTab.c:57
TextWidget m_PlayerMouseDiff
Definition ScriptConsoleGeneralTab.c:60
CheckBoxWidget m_HudDCharLevels
Definition ScriptConsoleGeneralTab.c:43
ButtonWidget m_LocationAddButton
Definition ScriptConsoleGeneralTab.c:34
EditBoxWidget m_DateDay
Definition ScriptConsoleGeneralTab.c:30
CheckBoxWidget m_HudDCharDebug
Definition ScriptConsoleGeneralTab.c:47
ButtonWidget m_DiagToggleButton
Definition ScriptConsoleGeneralTab.c:39
TextListboxWidget m_HelpTextListboxWidget
Definition ScriptConsoleGeneralTab.c:65
void LateInit()
Definition ScriptConsoleGeneralTab.c:216
TextWidget m_PlayerCurDir
Definition ScriptConsoleGeneralTab.c:58
TextListboxWidget m_DiagToggleTextListbox
Definition ScriptConsoleGeneralTab.c:62
CheckBoxWidget m_HudDFreeCamCross
Definition ScriptConsoleGeneralTab.c:48
CheckBoxWidget m_HudDVersion
Definition ScriptConsoleGeneralTab.c:49
ButtonWidget m_ButtonCopyPos
Definition ScriptConsoleGeneralTab.c:37
MapWidget m_DebugMapWidget
Definition ScriptConsoleGeneralTab.c:55
TextWidget m_MouseCurPos
Definition ScriptConsoleGeneralTab.c:59
ButtonWidget m_DiagDrawButton
Definition ScriptConsoleGeneralTab.c:38
TextListboxWidget m_PositionsListbox
Definition ScriptConsoleGeneralTab.c:63
Definition EnWidgets.c:220
proto native CGame GetGame()

Перекрестные ссылки GetGame(), GetPlugin(), Init(), LateInit(), m_ButtonCopyPos, m_DateDay, m_DateHour, m_DateMinute, m_DateMonth, m_DateYear, m_DebugMapWidget, m_Developer, m_DiagDrawButton, m_DiagDrawmodeTextListbox, m_DiagToggleButton, m_DiagToggleTextListbox, m_HelpTextListboxWidget, m_HudDCharAgents, m_HudDCharDebug, m_HudDCharLevels, m_HudDCharModifiers, m_HudDCharStats, m_HudDCharStomach, m_HudDFreeCamCross, m_HudDHealth, m_HudDTemperature, m_HudDVersion, m_LocationAddButton, m_LocationRemoveButton, m_LogsEnabled, m_MissionGameplay, m_MouseCurPos, m_PlayerCurDir, m_PlayerCurPos, m_PlayerMouseDiff, m_PositionsListbox, m_ShowOthers, m_TeleportButton, m_TeleportHeading, m_TeleportXYZ и m_TimeSlider.

◆ ~ScriptConsoleGeneralTab()

void ~ScriptConsoleGeneralTab ( )
inlineprotected
126 {
128
131 plugin_remote_client.RequestPlayerInfo(PlayerBase.Cast(GetGame().GetPlayer()), 0);
132 }
PlayerBase GetPlayer()
Definition ModifierBase.c:51
proto native float GetScale()
Definition PlayerBaseClient.c:2
static bool SHOW_OTHERS
Definition ScriptConsoleGeneralTab.c:8
static float DEBUG_MAP_ZOOM
Definition ScriptConsoleGeneralTab.c:7

Перекрестные ссылки DEBUG_MAP_ZOOM, GetGame(), GetPlayer(), GetPlugin(), MapWidget::GetScale(), m_DebugMapWidget и SHOW_OTHERS.

Методы

◆ GetCurrentLocationName()

string GetCurrentLocationName ( )
inlineprotected
385 {
386 string name;
389 if (prms)
390 name =prms.param1;
391 return name;
392 }
PlayerSpawnPresetDiscreteItemSetSlotData name
one set for cargo
void GetCurrentPositionData(out LocationParams data)
Definition ScriptConsoleGeneralTab.c:403

Перекрестные ссылки GetCurrentPositionData() и name.

Используется в OnClick().

◆ GetCurrentLocationPos()

vector GetCurrentLocationPos ( )
inlineprotected
394 {
397 if (prms)
398 return prms.param3;
399 else
400 return vector.Zero;
401 }
Definition EnConvert.c:106
static const vector Zero
Definition EnConvert.c:110

Перекрестные ссылки GetCurrentPositionData() и vector::Zero.

Используется в OnClick(), OnDoubleClick() и OnItemSelected().

◆ GetCurrentPositionData()

void GetCurrentPositionData ( out LocationParams data)
inlineprotected
404 {
405 if (m_PositionsListbox.GetSelectedRow() != -1)
406 {
407 m_PositionsListbox.GetItemData(m_PositionsListbox.GetSelectedRow(), 0, data);
408 }
409 }

Перекрестные ссылки m_PositionsListbox.

Используется в GetCurrentLocationName(), GetCurrentLocationPos() и IsCurrentPositionCustom().

◆ GetCurrentPositionIndex()

int GetCurrentPositionIndex ( )
inlineprotected
422 {
423 return m_PositionsListbox.GetSelectedRow();
424 }

Перекрестные ссылки m_PositionsListbox.

Используется в OnClick() и OnItemSelected().

◆ GetMapPos()

vector GetMapPos ( )
inlineprotected
523 {
524 return m_MapPos;
525 }
vector m_MapPos
Definition ScriptConsoleGeneralTab.c:11

Перекрестные ссылки m_MapPos.

Используется в OnClick() и Update().

◆ Init()

void Init ( )
inlineprotected
135 {
136
137
138
139 // Update checkbox Character Values
140 m_HudDCharStats.SetChecked(m_ConfigDebugProfile.GetCharacterStatsVisible());
141 m_HudDCharLevels.SetChecked(m_ConfigDebugProfile.GetCharacterLevelsVisible());
142 m_HudDCharStomach.SetChecked(m_ConfigDebugProfile.GetCharacterStomachVisible());
143 m_HudDCharModifiers.SetChecked(m_ConfigDebugProfile.GetCharacterModifiersVisible());
144 m_HudDCharAgents.SetChecked(m_ConfigDebugProfile.GetCharacterAgentsVisible());
145 m_HudDCharDebug.SetChecked(m_ConfigDebugProfile.GetCharacterDebugVisible());
146 m_HudDFreeCamCross.SetChecked(m_ConfigDebugProfile.GetFreeCameraCrosshairVisible());
147 m_HudDVersion.SetChecked(m_ConfigDebugProfile.GetVersionVisible());
148 m_HudDTemperature.SetChecked(m_ConfigDebugProfile.GetTempVisible());
149 m_HudDHealth.SetChecked(m_ConfigDebugProfile.GetHealthVisible());
150
151
152 m_LogsEnabled.SetChecked(m_ConfigDebugProfile.GetLogsEnabled());
153
155 GetGame().GetDiagModeNames(diag_names);
156 int i;
157 for (i = 0; i < diag_names.Count(); i++)
158 {
159 m_DiagToggleTextListbox.AddItem(diag_names.Get(i), NULL, 0);
160 }
161
162 GetGame().GetDiagDrawModeNames(diag_names);
163 for (i = 0; i < diag_names.Count(); i++)
164 {
165 m_DiagDrawmodeTextListbox.AddItem(diag_names.Get(i), NULL, 0);
166 }
168
170
171 if (GetGame().GetPlayer())
172 {
174 m_DebugMapWidget.SetMapPos(GetGame().GetPlayer().GetWorldPosition());
175 }
177 m_TeleportXYZ.SetText(m_LastEditPos.ToString(true));
180
181 m_LateInit.Run(0.05, this, "LateInit", null, false);
182
184 GetGame().GetWorld().GetDate(year,month, day, hour, minute);
186 }
proto native void SetMapPos(vector worldPos)
proto native void SetScale(float scale)
vector m_LastEditDir
Definition ScriptConsoleGeneralTab.c:5
void RefreshDateWidgets(int year, int month, int day, int hour, int minute)
Definition ScriptConsoleGeneralTab.c:189
vector m_LastEditPos
Definition ScriptConsoleGeneralTab.c:4
ref Timer m_LateInit
Definition ScriptConsoleGeneralTab.c:20
void RefreshLocations()
Definition ScriptConsoleGeneralTab.c:366
PluginConfigDebugProfile m_ConfigDebugProfile
Definition ScriptConsoleTabBase.c:11
Result for an object found in CGame.IsBoxCollidingGeometryProxy.
Definition IsBoxCollidingGeometryProxyClasses.c:28
proto string ToString(bool beautify=true)
Vector to string.
array< string > TStringArray
Definition EnScript.c:685

Перекрестные ссылки DEBUG_MAP_ZOOM, GetGame(), GetPlayer(), ScriptConsoleTabBase::m_ConfigDebugProfile, m_DebugMapWidget, m_DiagDrawmodeTextListbox, m_DiagToggleTextListbox, m_HudDCharAgents, m_HudDCharDebug, m_HudDCharLevels, m_HudDCharModifiers, m_HudDCharStats, m_HudDCharStomach, m_HudDFreeCamCross, m_HudDHealth, m_HudDTemperature, m_HudDVersion, m_LastEditDir, m_LastEditPos, m_LateInit, m_LogsEnabled, m_TeleportHeading, m_TeleportXYZ, RefreshDateWidgets(), RefreshLocations(), MapWidget::SetMapPos(), MapWidget::SetScale(), vector::ToString(), UpdateHudDebugSetting() и vector::Zero.

Используется в ScriptConsoleGeneralTab().

◆ IsCurrentPositionCustom()

bool IsCurrentPositionCustom ( )
inlineprotected
412 {
415 if (prms)
416 return prms.param2;
417 else
418 return false;
419 }

Перекрестные ссылки GetCurrentPositionData().

◆ IsCurrentPositionValid()

bool IsCurrentPositionValid ( )
inlineprotected
427 {
428 return (m_PositionsListbox.GetSelectedRow() != -1);
429 }

Перекрестные ссылки m_PositionsListbox.

Используется в OnClick() и OnItemSelected().

◆ IsLocationNameAvailable()

bool IsLocationNameAvailable ( string name)
inlineprotected
201 {
202 int count = m_PositionsListbox.GetNumItems();
203 for (int i = 0; i < count; i++)
204 {
206 m_PositionsListbox.GetItemData(i,0,data);
207 if (data.param1 == name)
208 return false;
209 }
210 return true;
211 }

Перекрестные ссылки m_PositionsListbox и name.

◆ LateInit()

void LateInit ( )
inlineprotected
217 {
218 m_ShowOthers.SetChecked(SHOW_OTHERS);
219
221 {
222 int prevRow = m_ConfigDebugProfile.GetSpawnLocIndex();
223 if (prevRow < m_PositionsListbox.GetNumItems())
224 m_PositionsListbox.SelectRow(prevRow);
225
226 }
229 {
230 plugin_remote_client.RequestPlayerInfo(PlayerBase.Cast(GetGame().GetPlayer()), 1);
232 }
233
234 }
bool m_UpdatePlayerPositions
Definition ScriptConsoleGeneralTab.c:22

Перекрестные ссылки GetGame(), GetPlayer(), GetPlugin(), ScriptConsoleTabBase::m_ConfigDebugProfile, m_PositionsListbox, m_ShowOthers, m_UpdatePlayerPositions и SHOW_OTHERS.

Используется в ScriptConsoleGeneralTab().

◆ OnChange()

override bool OnChange ( Widget w,
int x,
int y,
bool finished )
inlineprotected
562 {
563 super.OnChange(w, x, y, finished);
564
565 if (w == m_ShowOthers && GetGame().GetPlayer())
566 {
568 if (m_ShowOthers.IsChecked())
569 {
570 plugin_remote_client.RequestPlayerInfo(PlayerBase.Cast(GetGame().GetPlayer()), 1);
572 SHOW_OTHERS = true;
573 }
574 else
575 {
576 plugin_remote_client.RequestPlayerInfo(PlayerBase.Cast(GetGame().GetPlayer()), 0);
578 SHOW_OTHERS = false;
579 }
580 return true;
581 }
582 else if (w == m_TimeSlider || w == m_DateDay || w == m_DateYear || w == m_DateMonth || w == m_DateHour || w == m_DateMinute)
583 {
585 return true;
586 }
587
588 return false;
589 }
Icon x
Icon y
void UpdateTime(bool slider_used)
Definition ScriptConsoleGeneralTab.c:447

Перекрестные ссылки GetGame(), GetPlayer(), GetPlugin(), m_DateDay, m_DateHour, m_DateMinute, m_DateMonth, m_DateYear, m_ShowOthers, m_TimeSlider, m_UpdatePlayerPositions, SHOW_OTHERS, UpdateTime(), x и y.

◆ OnClick()

override bool OnClick ( Widget w,
int x,
int y,
int button )
inlineprotected
652 {
653 super.OnClick(w, x, y, button);
654
655 int i;
657
658 PluginDeveloper module_dev = PluginDeveloper.Cast(GetPlugin(PluginDeveloper));
659
660 if (w == m_PositionsListbox)
661 {
662
664
666 {
668 }
669
670 return true;
671 }
672 else if (w == m_TeleportButton)
673 {
675 return true;
676 }
677 else if (w == m_ButtonCopyPos)
678 {
679 if (m_IsShiftDown)
680 {
681 GetGame().CopyToClipboard(GetMapPos().ToString(false));
682 return true;
683 }
684
685
686 GetGame().CopyToClipboard(GetMapPos().ToString() + " " + GetGame().GetPlayer().GetDirection().ToString());
687 return true;
688 }
689 else if (w == m_LogsEnabled)
690 {
691 //Log("m_LogsEnabled: "+ToString(m_LogsEnabled.IsChecked()));
692
694 {
695 m_ConfigDebugProfile.SetLogsEnabled(m_LogsEnabled.IsChecked());
697 }
698
699 return true;
700 }
701 else if (w == m_HudDCharStats)
702 {
704 {
705 m_ConfigDebugProfile.SetCharacterStatsVisible(m_HudDCharStats.IsChecked());
706 }
707
708 // Refresh UI by new settings
709 m_MissionGameplay.GetHudDebug().RefreshByLocalProfile();
710
711 return true;
712 }
713 else if (w == m_HudDCharLevels)
714 {
716 {
717 m_ConfigDebugProfile.SetCharacterLevelsVisible(m_HudDCharLevels.IsChecked());
718 }
719
720 // Refresh UI by new settings
721 m_MissionGameplay.GetHudDebug().RefreshByLocalProfile();
722
723 return true;
724 }
725 else if (w == m_HudDCharStomach)
726 {
728 {
729 m_ConfigDebugProfile.SetCharacterStomachVisible(m_HudDCharStomach.IsChecked());
730 }
731
732 // Refresh UI by new settings
733 m_MissionGameplay.GetHudDebug().RefreshByLocalProfile();
734
735 return true;
736 }
737 else if (w == m_HudDVersion)
738 {
740 {
741 m_ConfigDebugProfile.SetVersionVisible(m_HudDVersion.IsChecked());
742 }
743
744 // Refresh UI by new settings
745 m_MissionGameplay.GetHudDebug().RefreshByLocalProfile();
746
747 return true;
748 }
749 else if (w == m_HudDTemperature)
750 {
752 {
753 m_ConfigDebugProfile.SetTempVisible(m_HudDTemperature.IsChecked());
754 }
755
756 // Refresh UI by new settings
757 m_MissionGameplay.GetHudDebug().RefreshByLocalProfile();
758
759 return true;
760 }
761 else if (w == m_HudDHealth)
762 {
764 {
765 m_ConfigDebugProfile.SetHealthVisible(m_HudDHealth.IsChecked());
766 }
767
768 // Refresh UI by new settings
769 m_MissionGameplay.GetHudDebug().RefreshByLocalProfile();
770
771 return true;
772 }
773 else if (w == m_HudDCharModifiers)
774 {
776 {
777 m_ConfigDebugProfile.SetCharacterModifiersVisible(m_HudDCharModifiers.IsChecked());
778 }
779
780 // Refresh UI by new settings
781 m_MissionGameplay.GetHudDebug().RefreshByLocalProfile();
782
783 return true;
784 }
785 else if (w == m_HudDCharAgents)
786 {
788 {
789 m_ConfigDebugProfile.SetCharacterAgentsVisible(m_HudDCharAgents.IsChecked());
790 }
791
792 // Refresh UI by new settings
793 m_MissionGameplay.GetHudDebug().RefreshByLocalProfile();
794
795 return true;
796 }
797 else if (w == m_HudDCharDebug)
798 {
800 {
801 m_ConfigDebugProfile.SetCharacterDebugVisible(m_HudDCharDebug.IsChecked());
802 }
803
804 // Refresh UI by new settings
805 m_MissionGameplay.GetHudDebug().RefreshByLocalProfile();
806
807 return true;
808 }
809 else if (w == m_HudDFreeCamCross)
810 {
812 {
813 m_ConfigDebugProfile.SetFreeCameraCrosshairVisible(m_HudDFreeCamCross.IsChecked());
814 }
815
816 // Refresh UI by new settings
817 m_MissionGameplay.GetHudDebug().RefreshByLocalProfile();
818
819 GetGame().GetCallQueue(CALL_CATEGORY_SYSTEM).Call(GetGame().GetMission().RefreshCrosshairVisibility);
820
821 return true;
822 }
823
824 else if (w == m_DiagToggleButton)
825 {
826 int toggle_row_index = m_DiagToggleTextListbox.GetSelectedRow();
827 bool toggle_state = GetGame().GetDiagModeEnable(toggle_row_index);
828 GetGame().SetDiagModeEnable(toggle_row_index, !toggle_state);
829 return true;
830 }
831 else if (w == m_DiagDrawButton)
832 {
833 int draw_row_index = m_DiagDrawmodeTextListbox.GetSelectedRow();
834 GetGame().SetDiagDrawMode(draw_row_index);
835 return true;
836 }
837 // TOUCHED THIS
838 else if (w == m_LocationAddButton)
839 {
840 ScriptConsoleAddLocation menu = ScriptConsoleAddLocation.Cast(g_Game.GetUIManager().EnterScriptedMenu(MENU_LOC_ADD, m_ScriptConsole));
841 menu.SetPosition(GetMapPos());
842 return true;
843 }
844 else if (w == m_LocationRemoveButton)
845 {
846 m_ConfigDebugProfile.CustomLocationsRemove(GetCurrentLocationName());
848 return true;
849 }
850 return false;
851 }
DayZGame g_Game
Definition DayZGame.c:3815
proto string ToString()
void RefreshCrosshairVisibility()
Definition HudDebug.c:244
Definition Debug.c:600
static void SetLogsEnabled(bool enable)
Definition Debug.c:639
vector GetMapPos()
Definition ScriptConsoleGeneralTab.c:522
bool IsCurrentPositionValid()
Definition ScriptConsoleGeneralTab.c:426
int GetCurrentPositionIndex()
Definition ScriptConsoleGeneralTab.c:421
void ProcessTeleportText(PlayerBase player)
Definition ScriptConsoleGeneralTab.c:243
string GetCurrentLocationName()
Definition ScriptConsoleGeneralTab.c:384
vector GetCurrentLocationPos()
Definition ScriptConsoleGeneralTab.c:393
ScriptConsole m_ScriptConsole
Definition ScriptConsoleTabBase.c:9
bool m_IsShiftDown
Definition ScriptConsoleTabBase.c:5
const int MENU_LOC_ADD
Definition constants.c:170
const int CALL_CATEGORY_SYSTEM
Definition tools.c:8

Перекрестные ссылки CALL_CATEGORY_SYSTEM, g_Game, GetCurrentLocationName(), GetCurrentLocationPos(), GetCurrentPositionIndex(), GetGame(), GetMapPos(), GetPlayer(), GetPlugin(), IsCurrentPositionValid(), m_ButtonCopyPos, ScriptConsoleTabBase::m_ConfigDebugProfile, m_DiagDrawButton, m_DiagDrawmodeTextListbox, m_DiagToggleButton, m_DiagToggleTextListbox, m_HudDCharAgents, m_HudDCharDebug, m_HudDCharLevels, m_HudDCharModifiers, m_HudDCharStats, m_HudDCharStomach, m_HudDFreeCamCross, m_HudDHealth, m_HudDTemperature, m_HudDVersion, ScriptConsoleTabBase::m_IsShiftDown, m_LocationAddButton, m_LocationRemoveButton, m_LogsEnabled, m_MissionGameplay, m_PositionsListbox, ScriptConsoleTabBase::m_ScriptConsole, m_TeleportButton, MENU_LOC_ADD, ProcessTeleportText(), RefreshCrosshairVisibility(), RefreshLocations(), LogManager::SetLogsEnabled(), ToString(), x и y.

◆ OnDoubleClick()

override bool OnDoubleClick ( Widget w,
int x,
int y,
int button )
inlineprotected
615 {
616 super.OnDoubleClick(w, x, y, button);
618
619 if (w == m_DebugMapWidget)
620 {
622 float pos_y_a = GetGame().SurfaceY(screen_to_map[0], screen_to_map[2]);
623 float pos_y_b = GetGame().SurfaceRoadY(screen_to_map[0], screen_to_map[2]);
624 float pos_y = Math.Max(pos_y_a, pos_y_b);
625 screen_to_map[1] = pos_y;
627 return true;
628 }
629
630 if (w == m_PositionsListbox)
631 {
634 return true;
635 }
636
637 if (w == m_TeleportHeading)
638 {
639 EditBoxWidget.Cast(w).SetText("");
640 return true;
641 }
642
643 if (w == m_TeleportXYZ)
644 {
645 EditBoxWidget.Cast(w).SetText("");
646 return true;
647 }
648 return false;
649 }
proto native vector ScreenToMap(vector screenPos)
Definition EnMath.c:7
void Teleport(PlayerBase player, vector position)
Definition ScriptConsoleGeneralTab.c:236
proto native vector Vector(float x, float y, float z)
Vector constructor from components.
static proto float Max(float x, float y)
Returns bigger of two given values.

Перекрестные ссылки GetCurrentLocationPos(), GetGame(), GetPlayer(), m_DebugMapWidget, m_Developer, m_PositionsListbox, m_TeleportHeading, m_TeleportXYZ, Math::Max(), MapWidget::ScreenToMap(), Teleport(), Vector(), x и y.

◆ OnItemSelected()

override bool OnItemSelected ( Widget w,
int x,
int y,
int row,
int column,
int oldRow,
int oldColumn )
inlineprotected
592 {
593 super.OnItemSelected(w, x, y, row, column, oldRow, oldColumn);
594 if (w == m_PositionsListbox)
595 {
596 if (m_InitialOpen)
597 {
598 m_InitialOpen = false;
599 return true;
600 }
601
603 m_TeleportXYZ.SetText(position.ToString());
605 {
607 }
608
609 return true;
610 }
611 return false;
612 }
bool m_InitialOpen
Definition ScriptConsoleGeneralTab.c:23

Перекрестные ссылки GetCurrentLocationPos(), GetCurrentPositionIndex(), IsCurrentPositionValid(), ScriptConsoleTabBase::m_ConfigDebugProfile, m_InitialOpen, m_PositionsListbox, m_TeleportXYZ, x и y.

◆ OnKeyDown()

override bool OnKeyDown ( Widget w,
int x,
int y,
int key )
inlineprotected
556 {
557 super.OnKeyDown(w, x, y, key);
558 return false;
559 }

Перекрестные ссылки x и y.

◆ OnMouseButtonDown()

override bool OnMouseButtonDown ( Widget w,
int x,
int y,
int button )
inlineprotected
528 {
529 super.OnMouseButtonDown(w,x,y,button);
530
531 if (w == m_DebugMapWidget)
532 {
533 if (button == 0)
534 {
536 int mouseX, mouseY;
539 mousePos[0] = mouseX;
540 mousePos[1] = mouseY;
542 worldPos[1] = GetGame().SurfaceY(worldPos[0], worldPos[2]);
543
545 }
546 else if (button == 1 && GetGame().GetPlayer())
547 {
548 SetMapPos(GetGame().GetPlayer().GetWorldPosition());
549 }
550 }
551 return true;
552 }
bool m_PlayerPosRefreshBlocked
Definition ScriptConsoleGeneralTab.c:12
void SetMapPos(vector pos)
Definition ScriptConsoleGeneralTab.c:511
proto void GetMousePos(out int x, out int y)

Перекрестные ссылки GetGame(), GetMousePos(), GetPlayer(), m_DebugMapWidget, m_PlayerPosRefreshBlocked, MapWidget::ScreenToMap(), SetMapPos(), x и y.

◆ OnRPCEx()

override void OnRPCEx ( int rpc_type,
ParamsReadContext ctx )
inlineprotected
854 {
855 super.OnRPCEx(rpc_type, ctx);
856 #ifdef DIAG_DEVELOPER
857 switch (rpc_type)
858 {
859 case ERPCs.DEV_PLAYER_DEBUG_DATA:
860 {
862 break;
863 }
864 }
865 #endif
866 }
ERPCs
Definition ERPCs.c:2
ref array< ref RemotePlayerStatDebug > m_PlayerDebugStats
Definition ScriptConsoleGeneralTab.c:14

Перекрестные ссылки m_PlayerDebugStats.

◆ ProcessTeleportText()

void ProcessTeleportText ( PlayerBase player)
inlineprotected
244 {
245 bool doTeleport, doSetDir;
246 vector pos, dir;
247 string text = m_TeleportXYZ.GetText();
248 string textDir = m_TeleportHeading.GetText();
249
251 if (numbersPos.Count() != 0)
252 {
253 if (numbersPos.Count() == 1)
254 {
255 pos = vector.Zero;
256 }
257 else if (numbersPos.Count() == 2)
258 {
259 pos = Vector(numbersPos[0], GetGame().SurfaceY(numbersPos[0], numbersPos[1]), numbersPos[1]);
260 }
261 else if (numbersPos.Count() <= 5)
262 {
263 pos = Vector(numbersPos[0], numbersPos[1], numbersPos[2]);
264 }
265 else if (numbersPos.Count() > 5)
266 {
267 pos = Vector(numbersPos[0], numbersPos[1], numbersPos[2]);
268 dir = Vector(numbersPos[3], numbersPos[4], numbersPos[5]);
269
270 Teleport(player, pos);
271 m_LastEditPos = pos;
273
274 m_Developer.SetDirection(player, dir);
275 m_LastEditDir = dir;
277
278 return;
279 }
280
281 doTeleport = true;
282 }
283 else
285
287 if (numbersDir.Count() != 0)
288 {
289 if (numbersDir.Count() == 1)
290 {
291 dir = vector.Zero;
292 }
293 else if (numbersDir.Count() == 2)
294 {
295 dir = Vector(numbersDir[0], 0, numbersDir[1]);
296 }
297 else if (numbersDir.Count() <= 5)
298 {
299 dir = Vector(numbersDir[0], numbersDir[1], numbersDir[2]);
300 }
301 else if (numbersDir.Count() > 5)
302 {
303 pos = Vector(numbersDir[0], numbersDir[1], numbersDir[2]);
304 dir = Vector(numbersDir[3], numbersDir[4], numbersDir[5]);
305
306 Teleport(player, pos);
307 m_LastEditPos = pos;
309
310 m_Developer.SetDirection(player, dir);
311 m_LastEditDir = dir;
313
314 return;
315 }
316
317 doSetDir = true;
318 }
319 else
321
322 if (doTeleport)
323 {
324 Teleport(player, pos);
325 m_LastEditPos = pos;
326 }
327
328 if (doSetDir)
329 {
330 m_Developer.SetDirection(player, dir);
331 m_LastEditDir = dir;
332 }
333 }
array< float > TextToNumbersArray(string text)
Definition ScriptConsoleGeneralTab.c:335

Перекрестные ссылки GetGame(), m_Developer, m_LastEditDir, m_LastEditPos, m_TeleportHeading, m_TeleportXYZ, Teleport(), TextToNumbersArray(), vector::ToString(), Vector() и vector::Zero.

Используется в OnClick().

◆ RefreshDateWidgets()

void RefreshDateWidgets ( int year,
int month,
int day,
int hour,
int minute )
inlineprotected
190 {
191 float time01 = Math.InverseLerp(0,60*24 - 1, (hour * 60) + minute);
192 m_DateYear.SetText(year.ToString());
193 m_DateMonth.SetText(month.ToString());
194 m_DateDay.SetText(day.ToString());
195 m_DateHour.SetText(hour.ToString());
196 m_DateMinute.SetText(minute.ToString());
197 m_TimeSlider.SetCurrent(time01 * 100);
198 }
static proto float InverseLerp(float a, float b, float value)
Calculates the linear value that produces the interpolant value within the range [a,...

Перекрестные ссылки Math::InverseLerp(), m_DateDay, m_DateHour, m_DateMinute, m_DateMonth, m_DateYear и m_TimeSlider.

Используется в Init() и UpdateTime().

◆ RefreshLocations()

void RefreshLocations ( )
inlineprotected
367 {
368 m_PositionsListbox.ClearItems();
369
371 m_ConfigDebugProfile.GetLocationsData(locData,true);
372 m_ConfigDebugProfileFixed.GetLocationsData(locData,false);
373 foreach (LocationParams dta: locData)
374 {
375 string name = dta.param1;
376 if (!dta.param2)
377 {
378 name = "[" + name + "]";
379 }
380 m_PositionsListbox.AddItem(name,dta,0);
381 }
382 }
PluginConfigDebugProfileFixed m_ConfigDebugProfileFixed
Definition ScriptConsoleTabBase.c:12

Перекрестные ссылки ScriptConsoleTabBase::m_ConfigDebugProfile, ScriptConsoleTabBase::m_ConfigDebugProfileFixed, m_PositionsListbox и name.

Используется в Init() и OnClick().

◆ RefreshPlayerPosEditBoxes()

void RefreshPlayerPosEditBoxes ( )
inlineprotected
434 {
435 if (!GetGame().GetPlayer())
436 {
437 return;
438 }
439
440 vector playerPos = GetGame().GetPlayer().GetPosition();
442
443 vector playerDir = GetGame().GetPlayer().GetDirection();
445 }
void SetDir(vector dir)
Definition ScriptConsoleGeneralTab.c:517

Перекрестные ссылки GetGame(), GetPlayer(), SetDir() и SetMapPos().

Используется в Update().

◆ SetDir()

void SetDir ( vector dir)
inlineprotected
518 {
519 m_PlayerCurDir.SetText("Direction: "+ MiscGameplayFunctions.TruncateToS(dir[0]) +", "+ MiscGameplayFunctions.TruncateToS(dir[1]) +", "+ MiscGameplayFunctions.TruncateToS(dir[2]));
520 }

Перекрестные ссылки m_PlayerCurDir.

Используется в RefreshPlayerPosEditBoxes().

◆ SetMapPos()

void SetMapPos ( vector pos)
inlineprotected
512 {
513 m_MapPos = pos;
514 m_PlayerCurPos.SetText("Position: "+ MiscGameplayFunctions.TruncateToS(pos[0]) +", "+ MiscGameplayFunctions.TruncateToS(pos[1]) +", "+ MiscGameplayFunctions.TruncateToS(pos[2]));
515 }

Перекрестные ссылки m_MapPos и m_PlayerCurPos.

Используется в OnMouseButtonDown() и RefreshPlayerPosEditBoxes().

◆ Teleport()

void Teleport ( PlayerBase player,
vector position )
inlineprotected
237 {
238 if (position[1] == 0)
239 position[1] = GetGame().SurfaceY(position[0], position[2]);
240 m_Developer.Teleport(player, position);
241 }

Перекрестные ссылки GetGame() и m_Developer.

Используется в OnDoubleClick() и ProcessTeleportText().

◆ TextToNumbersArray()

array< float > TextToNumbersArray ( string text)
inlineprotected
336 {
338 int length = text.Length();
339 int numberStart = -1;
340 int numberLen;
341
342 for (int i = 0; i < length; i++) // find numbers and move them to array
343 {
344 string letter = text.Get(i);
345
346 if (numberStart == -1 && NUMERIC_LETTERS.Contains(letter) && letter != ".") // search for number
347 numberStart = i;
348
349 if (numberStart != -1 && (!NUMERIC_LETTERS.Contains(letter) || (letter == "-" && numberStart != i))) // search for number end
350 {
352 numbers.Insert(text.Substring(numberStart, numberLen).ToFloat());
353 numberStart = -1;
354 }
355 else if (numberStart != -1 && (i + 1 == length)) // last letter
356 {
357 numberLen = i - numberStart + 1;
358 numbers.Insert(text.Substring(numberStart, numberLen).ToFloat());
359 numberStart = -1;
360 }
361 }
362
363 return numbers;
364 }
const string NUMERIC_LETTERS
Definition ScriptConsoleGeneralTab.c:10

Перекрестные ссылки NUMERIC_LETTERS.

Используется в ProcessTeleportText().

◆ Update()

override void Update ( float timeslice)
inlineprotected
869 {
870 super.Update(timeslice);
871
873
875
877 {
879 {
880 if (rpd.m_Player != player)
881 {
882 vector dir = rpd.m_Pos - player.GetWorldPosition();
883 dir[1] = 0;
884 string dist = ((int)dir.Length()).ToString();
885 string text = rpd.m_Name + " " +dist +"m.";
886 m_DebugMapWidget.AddUserMark(rpd.m_Pos, text , COLOR_BLUE,"\\dz\\gear\\navigation\\data\\map_tree_ca.paa");
887 }
888 }
889 }
890 if (player)
891 {
892 vector playerPos = player.GetWorldPosition();
893 m_DebugMapWidget.AddUserMark(playerPos,"You", COLOR_RED,"\\dz\\gear\\navigation\\data\\map_tree_ca.paa");
894 if (playerPos != GetMapPos())
895 m_DebugMapWidget.AddUserMark(GetMapPos(),"Pos", COLOR_BLUE,"\\dz\\gear\\navigation\\data\\map_tree_ca.paa");
896 }
900
901
902 foreach (MapMarker marker: ScriptConsole.m_MarkedEntities)
903 {
904 m_DebugMapWidget.AddUserMark(marker.GetMarkerPos(),marker.GetMarkerText(), marker.GetMarkerColor(), MapMarkerTypes.GetMarkerTypeFromID(marker.GetMarkerIcon()));
905 }
906 }
Param3 int
void RemotePlayerStatDebug(PlayerBase player)
Definition RemotePlayerStatDebug.c:16
Definition InventoryItem.c:1163
Definition MapMarkersInfo.c:2
static string GetMarkerTypeFromID(int id)
Definition MapMarkersInfo.c:36
proto native void AddUserMark(vector pos, string text, int color, string texturePath)
proto native void ClearUserMarks()
void RefreshPlayerPosEditBoxes()
Definition ScriptConsoleGeneralTab.c:433
void UpdateMousePos()
Definition ScriptConsoleGeneralTab.c:486
proto native float Length()
Returns length of vector (magnitude)
const int COLOR_BLUE
Definition constants.c:66
const int COLOR_RED
Definition constants.c:64

Перекрестные ссылки MapWidget::AddUserMark(), MapWidget::ClearUserMarks(), COLOR_BLUE, COLOR_RED, GetGame(), GetMapPos(), MapMarkerTypes::GetMarkerTypeFromID(), GetPlayer(), vector::Length(), m_DebugMapWidget, m_PlayerDebugStats, m_PlayerPosRefreshBlocked, m_UpdatePlayerPositions, RefreshPlayerPosEditBoxes(), RemotePlayerStatDebug(), ToString() и UpdateMousePos().

◆ UpdateHudDebugSetting()

void UpdateHudDebugSetting ( )
protected

Используется в Init().

◆ UpdateMousePos()

void UpdateMousePos ( )
inlineprotected
487 {
488 int x,y;
489 GetMousePos(x,y);
491 mousePos[0] = x;
492 mousePos[1] = y;
494 worldPos[1] = GetGame().SurfaceY(worldPos[0], worldPos[2]);
495
496 if (m_MouseCurPos)
497 {
498 m_MouseCurPos.SetText("Mouse: "+ MiscGameplayFunctions.TruncateToS(worldPos[0]) +", "+ MiscGameplayFunctions.TruncateToS(worldPos[1]) +", "+ MiscGameplayFunctions.TruncateToS(worldPos[2]));
499 }
501 {
502 vector playerPos = GetGame().GetPlayer().GetWorldPosition();
503 //playerPos[1] = 0;
504 float dst = (worldPos - playerPos).Length();
505
506 m_PlayerMouseDiff.SetText("Distance: " + MiscGameplayFunctions.TruncateToS(dst));
507 }
508 }

Перекрестные ссылки GetGame(), GetMousePos(), GetPlayer(), m_DebugMapWidget, m_MouseCurPos, m_PlayerMouseDiff, MapWidget::ScreenToMap(), x и y.

Используется в Update().

◆ UpdateTime()

void UpdateTime ( bool slider_used)
inlineprotected
448 {
450 int year, month, day, hour, minute;
451
452 year = m_DateYear.GetText().ToInt();
453 month = m_DateMonth.GetText().ToInt();
454 day = m_DateDay.GetText().ToInt();
455
456 if (slider_used)
457 {
458 int time_minutes = Math.Lerp(0, (24*60) - 1, m_TimeSlider.GetCurrent()/100);
459 hour = time_minutes / 60;
460 minute = time_minutes % 60;
461 }
462 else
463 {
464 hour = m_DateHour.GetText().ToInt();
465 minute = m_DateMinute.GetText().ToInt();
466 }
467
468 p5.param1 = year;
469 p5.param2 = month;
470 p5.param3 = day;
471 p5.param4 = hour;
472 p5.param5 = minute;
473
475 GetGame().GetWorld().SetDate(year, month, day, hour, minute);
476
477 g_Game.GetMission().GetOnTimeChanged().Invoke();
478
479 if (GetGame().GetPlayer())
480 {
481 GetGame().GetPlayer().RPCSingleParam(ERPCs.DEV_RPC_SET_TIME, p5, true);
482 }
483 }
static proto float Lerp(float a, float b, float time)
Linearly interpolates between 'a' and 'b' given 'time'.

Перекрестные ссылки g_Game, GetGame(), GetPlayer(), Math::Lerp(), m_DateDay, m_DateHour, m_DateMinute, m_DateMonth, m_DateYear, m_TimeSlider и RefreshDateWidgets().

Используется в OnChange().

Поля

◆ DEBUG_MAP_ZOOM

float DEBUG_MAP_ZOOM = 1
staticprotected

Используется в Init() и ~ScriptConsoleGeneralTab().

◆ m_ButtonCopyPos

ButtonWidget m_ButtonCopyPos
protected

Используется в OnClick() и ScriptConsoleGeneralTab().

◆ m_DateDay

EditBoxWidget m_DateDay
protected

◆ m_DateHour

EditBoxWidget m_DateHour
protected

◆ m_DateMinute

EditBoxWidget m_DateMinute
protected

◆ m_DateMonth

EditBoxWidget m_DateMonth
protected

◆ m_DateYear

EditBoxWidget m_DateYear
protected

◆ m_DebugMapWidget

◆ m_Developer

PluginDeveloper m_Developer
protected

◆ m_DiagDrawButton

ButtonWidget m_DiagDrawButton
protected

Используется в OnClick() и ScriptConsoleGeneralTab().

◆ m_DiagDrawmodeTextListbox

TextListboxWidget m_DiagDrawmodeTextListbox
protected

Используется в Init(), OnClick() и ScriptConsoleGeneralTab().

◆ m_DiagToggleButton

ButtonWidget m_DiagToggleButton
protected

Используется в OnClick() и ScriptConsoleGeneralTab().

◆ m_DiagToggleTextListbox

TextListboxWidget m_DiagToggleTextListbox
protected

Используется в Init(), OnClick() и ScriptConsoleGeneralTab().

◆ m_HelpTextListboxWidget

TextListboxWidget m_HelpTextListboxWidget
protected

Используется в ScriptConsoleGeneralTab().

◆ m_HudDCharAgents

CheckBoxWidget m_HudDCharAgents
protected

Используется в Init(), OnClick() и ScriptConsoleGeneralTab().

◆ m_HudDCharDebug

CheckBoxWidget m_HudDCharDebug
protected

Используется в Init(), OnClick() и ScriptConsoleGeneralTab().

◆ m_HudDCharLevels

CheckBoxWidget m_HudDCharLevels
protected

Используется в Init(), OnClick() и ScriptConsoleGeneralTab().

◆ m_HudDCharModifiers

CheckBoxWidget m_HudDCharModifiers
protected

Используется в Init(), OnClick() и ScriptConsoleGeneralTab().

◆ m_HudDCharStats

CheckBoxWidget m_HudDCharStats
protected

Используется в Init(), OnClick() и ScriptConsoleGeneralTab().

◆ m_HudDCharStomach

CheckBoxWidget m_HudDCharStomach
protected

Используется в Init(), OnClick() и ScriptConsoleGeneralTab().

◆ m_HudDFreeCamCross

CheckBoxWidget m_HudDFreeCamCross
protected

Используется в Init(), OnClick() и ScriptConsoleGeneralTab().

◆ m_HudDHealth

CheckBoxWidget m_HudDHealth
protected

Используется в Init(), OnClick() и ScriptConsoleGeneralTab().

◆ m_HudDTemperature

CheckBoxWidget m_HudDTemperature
protected

Используется в Init(), OnClick() и ScriptConsoleGeneralTab().

◆ m_HudDVersion

CheckBoxWidget m_HudDVersion
protected

Используется в Init(), OnClick() и ScriptConsoleGeneralTab().

◆ m_InitialOpen

bool m_InitialOpen = true
protected

Используется в OnItemSelected().

◆ m_LastEditDir

vector m_LastEditDir = vector.Zero
staticprotected

Используется в Init() и ProcessTeleportText().

◆ m_LastEditPos

vector m_LastEditPos = vector.Zero
staticprotected

Используется в Init() и ProcessTeleportText().

◆ m_LateInit

ref Timer m_LateInit = new Timer()
protected

Используется в Init().

◆ m_LocationAddButton

ButtonWidget m_LocationAddButton
protected

Используется в OnClick() и ScriptConsoleGeneralTab().

◆ m_LocationRemoveButton

ButtonWidget m_LocationRemoveButton
protected

Используется в OnClick() и ScriptConsoleGeneralTab().

◆ m_LogsEnabled

CheckBoxWidget m_LogsEnabled
protected

Используется в Init(), OnClick() и ScriptConsoleGeneralTab().

◆ m_MapPos

vector m_MapPos
protected

Используется в GetMapPos() и SetMapPos().

◆ m_MissionGameplay

MissionGameplay m_MissionGameplay
protected

Используется в OnClick() и ScriptConsoleGeneralTab().

◆ m_MouseCurPos

TextWidget m_MouseCurPos
protected

Используется в ScriptConsoleGeneralTab() и UpdateMousePos().

◆ m_ObjectsScope

int m_ObjectsScope = 2
staticprivate

◆ m_PlayerCurDir

TextWidget m_PlayerCurDir
protected

Используется в ScriptConsoleGeneralTab() и SetDir().

◆ m_PlayerCurPos

TextWidget m_PlayerCurPos
protected

Используется в ScriptConsoleGeneralTab() и SetMapPos().

◆ m_PlayerDebugStats

Используется в OnRPCEx() и Update().

◆ m_PlayerMouseDiff

TextWidget m_PlayerMouseDiff
protected

Используется в ScriptConsoleGeneralTab() и UpdateMousePos().

◆ m_PlayerPosRefreshBlocked

bool m_PlayerPosRefreshBlocked
protected

Используется в OnMouseButtonDown() и Update().

◆ m_PositionsListbox

◆ m_ShowOthers

CheckBoxWidget m_ShowOthers
protected

Используется в LateInit(), OnChange() и ScriptConsoleGeneralTab().

◆ m_TeleportButton

ButtonWidget m_TeleportButton
protected

Используется в OnClick() и ScriptConsoleGeneralTab().

◆ m_TeleportHeading

EditBoxWidget m_TeleportHeading
protected

◆ m_TeleportXYZ

EditBoxWidget m_TeleportXYZ
protected

◆ m_TimeSlider

SliderWidget m_TimeSlider
protected

◆ m_UpdatePlayerPositions

bool m_UpdatePlayerPositions
protected

Используется в LateInit(), OnChange() и Update().

◆ NUMERIC_LETTERS

const string NUMERIC_LETTERS = "0123456789.-"
protected

Используется в TextToNumbersArray().

◆ SHOW_OTHERS

bool SHOW_OTHERS = 0
staticprotected

Используется в LateInit(), OnChange() и ~ScriptConsoleGeneralTab().


Объявления и описания членов класса находятся в файле: