DayZ 1.26
DayZ Explorer by KGB
Загрузка...
Поиск...
Не найдено
Файл ActionManagerBase.c

См. исходные тексты.

Структуры данных

class  array< ref TSelectableActionInfo >
 

Функции

void ActionManagerBase (PlayerBase player)
 
ActionBase GetRunningAction ()
 returns -1 when no action is running or RELOAD,MECHANISM, ....
 
ItemBase GetRunningActionMainitem ()
 
void EnableActions (bool enable)
 
void Update (int pCurrentCommandID)
 
void OnSyncJuncture (int pJunctureID, ParamsReadContext pCtx)
 
ActionTarget FindActionTarget ()
 
void StartDeliveredAction ()
 
static ActionBase GetActionVariant (typename actionName)
 
static ActionBase GetAction (typename actionName)
 
static ActionBase GetAction (int actionID)
 
ActionBase GetContinuousAction ()
 
ActionBase GetSingleUseAction ()
 
TSelectableActionInfoArray GetSelectableActions ()
 
int GetSelectedActionIndex ()
 
 GetSelectedActionCategory ()
 
void SelectFirstActionCategory ()
 
void SelectNextActionCategory ()
 
void SelectPrevActionCategory ()
 
void SelectNextAction ()
 
void SelectPrevAction ()
 
void RequestEndAction ()
 
void EndActionInput ()
 
bool IsSelectableActionsChanged ()
 
bool ActionPossibilityCheck (int pCurrentCommandID)
 
void SetActionContext (ActionTarget target, ItemBase item)
 
int GetActionState (ActionBase action)
 
void OnContinuousStart ()
 
void OnContinuousCancel ()
 
void OnSingleUse ()
 
void Interrupt ()
 
void LocalInterrupt ()
 
void OnInteractAction ()
 
void OnInstantAction (typename user_action_type, Param data=null)
 
void OnActionEnd ()
 
void OnJumpStart ()
 
bool OnInputUserDataProcess (int userDataType, ParamsReadContext ctx)
 
float GetActionComponentProgress ()
 
int GetActionState ()
 
ActionReciveData GetReciveData ()
 

Переменные

class TSelectableActionInfoArray extends array< ref TSelectableActionInfom_Player
 
ActionTarget m_TestedActionTarget
 
ItemBase m_TestedActionItem
 
ActionBase m_PrimaryAction
 
ActionTarget m_PrimaryActionTarget
 
ItemBase m_PrimaryActionItem
 
ActionBase m_SecondaryAction
 
ActionTarget m_SecondaryActionTarget
 
ItemBase m_SecondaryActionItem
 
bool m_PrimaryActionEnabled
 
bool m_SecondaryActionEnabled
 
bool m_TertiaryActionEnabled
 
ref TSelectableActionInfoArray m_SelectableActions
 
int m_SelectedActionIndex
 
bool m_SelectableActionsHasChanged
 
bool m_Interrupted
 
static ref array< ref ActionBasem_ActionsArray
 
static ref map< typename, ActionBasem_ActionNameActionMap
 
bool m_ActionWantEndRequest
 
bool m_ActionInputWantEnd
 
bool m_ActionsEnabled
 
bool m_ActionsAvaibale
 
bool m_IsRestrictedLookLimits
 
int m_PendingActionAcknowledgmentID
 
ref ActionData m_CurrentActionData
 

Функции

◆ ActionManagerBase()

void ActionManagerBase ( PlayerBase player)
protected
64 {
66 if (m_Player)
67 {
71
73
75 m_Interrupted = false;
76
78 if (!m_ActionsArray)
79 {
80 ac.ConstructActions(m_ActionsArray, m_ActionNameActionMap);
81 }
82
85 }
86
87 m_ActionsEnabled = true;
88 m_ActionsAvaibale = true;
89 }
bool m_Interrupted
Definition ActionManagerBase.c:49
ref ActionData m_CurrentActionData
Definition ActionManagerBase.c:61
bool m_ActionsEnabled
Definition ActionManagerBase.c:54
bool m_SelectableActionsHasChanged
Definition ActionManagerBase.c:48
bool m_ActionsAvaibale
Definition ActionManagerBase.c:55
int m_SelectedActionIndex
Definition ActionManagerBase.c:47
bool m_ActionInputWantEnd
Definition ActionManagerBase.c:53
ref TSelectableActionInfoArray m_SelectableActions
Definition ActionManagerBase.c:46
static ref array< ref ActionBase > m_ActionsArray
Definition ActionManagerBase.c:50
int m_PendingActionAcknowledgmentID
Definition ActionManagerBase.c:59
bool m_ActionWantEndRequest
Definition ActionManagerBase.c:52
class TSelectableActionInfoArray extends array< ref TSelectableActionInfo > m_Player
static ref map< typename, ActionBase > m_ActionNameActionMap
Definition ActionManagerBase.c:51
Definition ActionConstructor.c:2
Definition EntityAI.c:95

Перекрестные ссылки m_ActionInputWantEnd, m_ActionNameActionMap, m_ActionsArray, m_ActionsAvaibale, m_ActionsEnabled, m_ActionWantEndRequest, m_CurrentActionData, m_Interrupted, m_PendingActionAcknowledgmentID, m_Player, m_SelectableActions, m_SelectableActionsHasChanged и m_SelectedActionIndex.

◆ ActionPossibilityCheck()

bool ActionPossibilityCheck ( int pCurrentCommandID)
protected
245 {
246 if (!m_ActionsEnabled || m_Player.IsSprinting() || m_Player.IsUnconscious() || m_Player.GetCommandModifier_Action() || m_Player.GetCommand_Action() || m_Player.IsEmotePlaying())
247 return false;
248
249 if (m_Player.GetWeaponManager().IsRunning() || m_Player.GetThrowing().IsThrowingAnimationPlaying() || m_Player.GetDayZPlayerInventory().IsProcessing() || m_Player.IsItemsToDelete() || m_Player.IsRolling())
250 return false;
251
252 return (pCurrentCommandID == DayZPlayerConstants.COMMANDID_ACTION || pCurrentCommandID == DayZPlayerConstants.COMMANDID_MOVE || pCurrentCommandID == DayZPlayerConstants.COMMANDID_SWIM || pCurrentCommandID == DayZPlayerConstants.COMMANDID_LADDER || pCurrentCommandID == DayZPlayerConstants.COMMANDID_VEHICLE);
253 }
DayZPlayerConstants
defined in C++
Definition dayzplayer.c:602

Перекрестные ссылки DayZPlayer::GetDayZPlayerInventory(), DayZPlayer::GetThrowing(), DayZPlayer::GetWeaponManager(), WeaponManager::IsRunning(), DayZPlayerImplementThrowing::IsThrowingAnimationPlaying(), m_ActionsEnabled и m_Player.

Используется в ActionManagerClient::ActionStart(), ActionManagerClient::Update() и ActionManagerServer::Update().

◆ EnableActions()

void EnableActions ( bool enable)
protected
108 {
110 }

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

◆ EndActionInput()

void EndActionInput ( )
protected

◆ FindActionTarget()

ActionTarget FindActionTarget ( )
protected

◆ GetAction() [1/2]

static ActionBase GetAction ( int actionID)
staticprotected
205 {
206 return m_ActionsArray.Get(actionID);
207 }

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

◆ GetAction() [2/2]

static ActionBase GetAction ( typename actionName )
staticprotected
197 {
200
201 return null;
202 }

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

◆ GetActionComponentProgress()

float GetActionComponentProgress ( )
protected
314 {
316 return m_CurrentActionData.m_Action.GetProgress(m_CurrentActionData);
317
318 return 0.0;
319 }

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

◆ GetActionState() [1/2]

int GetActionState ( )
protected
322 {
324 return m_CurrentActionData.m_Action.GetState(m_CurrentActionData);
325
326 return UA_NONE;
327 }
const int UA_NONE
Definition constants.c:439

Перекрестные ссылки m_CurrentActionData и UA_NONE.

◆ GetActionState() [2/2]

int GetActionState ( ActionBase action)
protected
264 {
266 {
267 return m_CurrentActionData.m_State;
268 }
269 return UA_NONE;
270 }

Перекрестные ссылки m_CurrentActionData и UA_NONE.

◆ GetActionVariant()

static ActionBase GetActionVariant ( typename actionName )
staticprotected
181 {
183 {
186
187 new_action.CreateConditionComponents();
188 new_action.SetID(base_action.GetID());
189 new_action.SetInput(base_action.GetInput());
190
191 return new_action;
192 }
193 return null;
194 }
Definition ActionBase.c:53

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

◆ GetContinuousAction()

ActionBase GetContinuousAction ( )
protected
210 {
211 return m_PrimaryAction;
212 }
ActionBase m_PrimaryAction
Definition ActionManagerBase.c:37

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

◆ GetReciveData()

ActionReciveData GetReciveData ( )
protected
330 {
331 return null;
332 }

◆ GetRunningAction()

ActionBase GetRunningAction ( )
protected

returns -1 when no action is running or RELOAD,MECHANISM, ....

92 {
94 return m_CurrentActionData.m_Action;
95
96 return null;
97 }

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

Используется в ManBase::CanBeRestrained(), ActionManagerClient::FindContextualUserActions(), ManBase::HeadingModel() и ManBase::OnQuickBarSingleUse().

◆ GetRunningActionMainitem()

ItemBase GetRunningActionMainitem ( )
protected
100 {
102 return m_CurrentActionData.m_MainItem;
103
104 return null;
105 }

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

◆ GetSelectableActions()

TSelectableActionInfoArray GetSelectableActions ( )
protected
220 {
221 return m_SelectableActions;
222 }

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

◆ GetSelectedActionCategory()

GetSelectedActionCategory ( )
protected

◆ GetSelectedActionIndex()

int GetSelectedActionIndex ( )
protected
225 {
227 }

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

◆ GetSingleUseAction()

ActionBase GetSingleUseAction ( )
protected
215 {
216 return m_SecondaryAction;
217 }
ActionBase m_SecondaryAction
Definition ActionManagerBase.c:40

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

◆ Interrupt()

void Interrupt ( )
protected

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

◆ IsSelectableActionsChanged()

bool IsSelectableActionsChanged ( )
protected
239 {
241 }

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

◆ LocalInterrupt()

void LocalInterrupt ( )
protected
281 {
283 m_CurrentActionData.m_Action.Interrupt(m_CurrentActionData);
284 else
285 m_Interrupted = false;
286 }

Перекрестные ссылки m_CurrentActionData и m_Interrupted.

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

◆ OnActionEnd()

void OnActionEnd ( )
protected
292 {
294 {
296 Debug.ActionLog("n/a", m_CurrentActionData.m_Action.ToString() , "n/a", "OnActionEnd", m_CurrentActionData.m_Player.ToString());
297 Debug.ActionLog("Action data cleared ", this.ToString() , "n/a", "ActionEnd", m_CurrentActionData.m_Player.ToString());
298 }
300 m_CurrentActionData.m_Action.ActionCleanup(m_CurrentActionData);
302
303 m_Player.ResetActionEndInput();
304 }
proto string ToString()
Definition Debug.c:14
static void ActionLog(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Definition Debug.c:141
Definition Debug.c:600
static bool IsActionLogEnable()
Definition Debug.c:644

Перекрестные ссылки Debug::ActionLog(), LogManager::IsActionLogEnable(), m_CurrentActionData, m_Player и ToString().

◆ OnContinuousCancel()

void OnContinuousCancel ( )
protected

◆ OnContinuousStart()

void OnContinuousStart ( )
protected

◆ OnInputUserDataProcess()

bool OnInputUserDataProcess ( int userDataType,
ParamsReadContext ctx )
protected
309 {
310 return false;
311 }

◆ OnInstantAction()

void OnInstantAction ( typename user_action_type ,
Param data = null )
protected

◆ OnInteractAction()

void OnInteractAction ( )
protected

◆ OnJumpStart()

void OnJumpStart ( )
protected

◆ OnSingleUse()

void OnSingleUse ( )
protected

◆ OnSyncJuncture()

void OnSyncJuncture ( int pJunctureID,
ParamsReadContext pCtx )
protected
157 {
159 switch (pJunctureID)
160 {
165 break;
170 break;
172 m_Interrupted = true;
173 break;
174 }
175 }
Definition DayZPlayerSyncJunctures.c:5
static const int SJ_ACTION_ACK_ACCEPT
Definition DayZPlayerSyncJunctures.c:12
static const int SJ_ACTION_INTERRUPT
Definition DayZPlayerSyncJunctures.c:8
static const int SJ_ACTION_ACK_REJECT
Definition DayZPlayerSyncJunctures.c:13
const int UA_AM_ACCEPTED
Definition constants.c:454
const int UA_AM_REJECTED
Definition constants.c:455

Перекрестные ссылки m_CurrentActionData, m_Interrupted, m_PendingActionAcknowledgmentID, DayZPlayerSyncJunctures::SJ_ACTION_ACK_ACCEPT, DayZPlayerSyncJunctures::SJ_ACTION_ACK_REJECT, DayZPlayerSyncJunctures::SJ_ACTION_INTERRUPT, UA_AM_ACCEPTED и UA_AM_REJECTED.

◆ RequestEndAction()

void RequestEndAction ( )
protected

◆ SelectFirstActionCategory()

void SelectFirstActionCategory ( )
protected

◆ SelectNextAction()

void SelectNextAction ( )
protected
496 {
497 if(m_SelectActions.Count())
498 {
501 {
503 }
504 }
505 }
int m_selectedActionIndex
Definition ActionInput.c:293
ActionInput m_SelectActions

Перекрестные ссылки m_SelectActions и m_selectedActionIndex.

◆ SelectNextActionCategory()

void SelectNextActionCategory ( )
protected

◆ SelectPrevAction()

void SelectPrevAction ( )
protected
508 {
509 if(m_SelectActions.Count())
510 {
512 if(0 > m_selectedActionIndex )
513 {
515 }
516 }
517 }

Перекрестные ссылки m_SelectActions и m_selectedActionIndex.

◆ SelectPrevActionCategory()

void SelectPrevActionCategory ( )
protected

◆ SetActionContext()

void SetActionContext ( ActionTarget target,
ItemBase item )
protected
256 {
259 }
ActionTarget m_TestedActionTarget
Definition ActionManagerBase.c:34
ItemBase m_TestedActionItem
Definition ActionManagerBase.c:35

Перекрестные ссылки m_TestedActionItem и m_TestedActionTarget.

Используется в ActionManagerClient::FindContextualUserActions().

◆ StartDeliveredAction()

void StartDeliveredAction ( )
protected

◆ Update()

void Update ( int pCurrentCommandID)
protected
113 {
115 {
116 if (m_Interrupted)
117 {
119 }
121 {
122 m_CurrentActionData.m_Action.OnUpdate(m_CurrentActionData);
123 }
124 }
125 else if (m_Interrupted)
126 {
127 m_Interrupted = false;
128 }
129
130 if (m_CurrentActionData) // again, can be nulled meanwhile
131 {
133 if (action && action.IsFullBody(m_Player) && action.IsCameraLockOnPerform())
134 {
136 {
137 Vector2 angleUD = action.GetCameraUDAngle();
138
140 m_Player.SetLookLimits(angleUD.x, angleUD.y, -160, 160);
141 m_Player.SetAimLimits(angleUD.x, angleUD.y, -180, 180);
142 }
143
144 return;
145 }
146 }
147
149 {
151 m_Player.SetLookLimits(-85, 85, -160, 160);
152 m_Player.SetAimLimits(-85, 85, -180, 180);
153 }
154 }
void LocalInterrupt()
Definition ActionManagerBase.c:280
bool m_IsRestrictedLookLimits
Definition ActionManagerBase.c:56
Definition ActionContinuousBase.c:121
Definition Vector2.c:2
const int UA_AM_PENDING
Definition constants.c:453

Перекрестные ссылки LocalInterrupt(), m_CurrentActionData, m_Interrupted, m_IsRestrictedLookLimits, m_Player, UA_AM_ACCEPTED, UA_AM_PENDING и UA_AM_REJECTED.

Переменные

◆ m_ActionInputWantEnd

◆ m_ActionNameActionMap

ref map<typename, ActionBase> m_ActionNameActionMap
staticprotected

Используется в ActionManagerBase(), GetAction() и GetActionVariant().

◆ m_ActionsArray

ref array<ref ActionBase> m_ActionsArray
staticprotected

◆ m_ActionsAvaibale

◆ m_ActionsEnabled

bool m_ActionsEnabled
protected

◆ m_ActionWantEndRequest

◆ m_CurrentActionData

◆ m_Interrupted

◆ m_IsRestrictedLookLimits

bool m_IsRestrictedLookLimits
protected

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

◆ m_PendingActionAcknowledgmentID

◆ m_Player

◆ m_PrimaryAction

ActionBase m_PrimaryAction
protected

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

◆ m_PrimaryActionEnabled

bool m_PrimaryActionEnabled
protected

◆ m_PrimaryActionItem

ItemBase m_PrimaryActionItem
protected

◆ m_PrimaryActionTarget

ActionTarget m_PrimaryActionTarget
protected

◆ m_SecondaryAction

ActionBase m_SecondaryAction
protected

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

◆ m_SecondaryActionEnabled

bool m_SecondaryActionEnabled
protected

◆ m_SecondaryActionItem

ItemBase m_SecondaryActionItem
protected

◆ m_SecondaryActionTarget

ActionTarget m_SecondaryActionTarget
protected

◆ m_SelectableActions

ref TSelectableActionInfoArray m_SelectableActions
protected

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

◆ m_SelectableActionsHasChanged

bool m_SelectableActionsHasChanged
protected

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

◆ m_SelectedActionIndex

int m_SelectedActionIndex
protected

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

◆ m_TertiaryActionEnabled

bool m_TertiaryActionEnabled
protected

◆ m_TestedActionItem

ItemBase m_TestedActionItem
protected

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

◆ m_TestedActionTarget

ActionTarget m_TestedActionTarget
protected

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