DayZ 1.27
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено

◆ PerformMapChange()

void ActionUnfoldMapCB::PerformMapChange ( )
inlineprivate

См. определение в файле ActionUnfoldMap.c строка 116

117 {
118 if (m_ActionData.m_Player.IsSwimming() || m_ActionData.m_Player.IsClimbing() || m_ActionData.m_Player.IsFalling() || m_ActionData.m_Player.IsClimbingLadder() || m_ActionData.m_Player.IsUnconscious() || m_ActionData.m_Player.IsRestrained())
119 return;
120
121 ItemMap chernomap = ItemMap.Cast(m_ActionData.m_Player.GetItemInHands());
122 if (chernomap)
123 {
124 if (!m_ActionData.m_Player.IsMapOpen() && !m_MapFolding)
125 {
126 if (m_CancelCondition) //do not open when cancelling in progress
127 return;
128
129 chernomap.SetMapStateOpen(true, m_ActionData.m_Player);
130
131 if (!GetGame().IsMultiplayer() || GetGame().IsServer())
132 {
133 //chernomap.SyncMapMarkers();
134 }
135
136 if (!GetGame().IsDedicatedServer())
137 {
138 UIManager m_UIManager;
139 UIScriptedMenu mapMenu;
140 m_UIManager = GetGame().GetUIManager();
141 m_UIManager.CloseAll();
142 if (!CfgGameplayHandler.GetUse3DMap())
143 {
144 mapMenu = m_UIManager.EnterScriptedMenu(MENU_MAP, null);
145 mapMenu.InitMapItem(chernomap);
146 mapMenu.LoadMapMarkers();
148 }
149 else
150 {
151 GetGame().GetMission().AddActiveInputExcludes({"loopedactions"});
152 }
153
154 GetGame().GetMission().AddActiveInputRestriction(EInputRestrictors.MAP);
155 }
156 }
157 else if (m_ActionData.m_Player.IsMapOpen())
158 {
159 chernomap.SetMapStateOpen(false, m_ActionData.m_Player);
160 m_MapFolding = true;
161 m_ActionData.m_Player.SetMapOpen(false);
162 }
163 }
164 }
ActionData m_ActionData
Определения AnimatedActionBase.c:3
bool m_CancelCondition
Определения ActionUnfoldMap.c:5
bool m_MapFolding
Определения ActionUnfoldMap.c:3
proto native UIManager GetUIManager()
proto native Mission GetMission()
void AddActiveInputRestriction(int restrictor)
void AddActiveInputExcludes(array< string > excludes)
proto native UIScriptedMenu EnterScriptedMenu(int id, UIMenuPanel parent)
Create & open menu with specific id (see MenuID) and set its parent.
bool CloseAll()
Close all opened menus.
Определения UIManager.c:78
override void LoadMapMarkers()
Определения MapMenu.c:322
override void InitMapItem(EntityAI item)
Определения MapMenu.c:168
proto native CGame GetGame()
const int MENU_MAP
Определения constants.c:191

Перекрестные ссылки Mission::AddActiveInputExcludes(), Mission::AddActiveInputRestriction(), UIManager::CloseAll(), UIManager::EnterScriptedMenu(), GetGame(), CGame::GetMission(), CGame::GetUIManager(), CfgGameplayHandler::GetUse3DMap(), UIScriptedMenu::InitMapItem(), UIScriptedMenu::LoadMapMarkers(), ActionBaseCB::m_ActionData, m_CancelCondition, m_MapFolding и MENU_MAP.

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