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

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

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

class  ActionTurnOffTransmitterCB
 

Функции

ActionTurnOffTransmitterCB ActionSingleUseBaseCB ActionTurnOffTransmitter ()
 
override void CreateActionComponent ()
 
override bool HasProneException ()
 
override bool ActionCondition (PlayerBase player, ActionTarget target, ItemBase item)
 
override void OnExecuteServer (ActionData action_data)
 

Функции

◆ ActionCondition()

override bool ActionCondition ( PlayerBase player,
ActionTarget target,
ItemBase item )
26 {
27 if (item.IsTransmitter())
28 {
29 return item.HasEnergyManager() && item.GetCompEM().IsWorking();
30 }
31
32 return false;
33 }
Definition EntityAI.c:95

◆ ActionTurnOffTransmitter()

ActionTurnOffTransmitterCB ActionSingleUseBaseCB ActionTurnOffTransmitter ( )
12 {
13 m_CallbackClass = ActionTurnOffTransmitterCB;
14 m_CommandUID = DayZPlayerConstants.CMD_ACTIONMOD_ITEM_OFF;
15 m_CommandUIDProne = DayZPlayerConstants.CMD_ACTIONFB_ITEM_OFF;
16 m_StanceMask = DayZPlayerConstants.STANCEMASK_CROUCH | DayZPlayerConstants.STANCEMASK_ERECT;
17 m_Text = "#turn_off";
18 }
int m_CommandUIDProne
Definition ActionBase.c:32
int m_CommandUID
Definition ActionBase.c:31
int m_StanceMask
Definition ActionBase.c:33
Definition ActionTurnOffTransmitter.c:2
DayZPlayerConstants
defined in C++
Definition dayzplayer.c:602

Используется в ActionConstructor::RegisterActions(), ItemMegaphone::SetActions(), ItemRadio::SetActions() и ItemTransmitter::SetActions().

◆ CreateActionComponent()

override void CreateActionComponent ( )
12 {
13 m_CallbackClass = ActionTurnOffTransmitterCB;
14 m_CommandUID = DayZPlayerConstants.CMD_ACTIONMOD_ITEM_OFF;
15 m_CommandUIDProne = DayZPlayerConstants.CMD_ACTIONFB_ITEM_OFF;

Перекрестные ссылки m_CommandUID, m_CommandUIDProne и m_StanceMask.

◆ HasProneException()

override bool HasProneException ( )
21 {
22 return true;
23 }

◆ OnExecuteServer()

override void OnExecuteServer ( ActionData action_data)
36 {
37 action_data.m_MainItem.GetCompEM().SwitchOff();
38 }