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

◆ ActionCondition()

override bool ActionWorldFlagActionSwitch::ActionCondition ( PlayerBase player,
ActionTarget target,
ItemBase item )
inlineprivate

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

34 {
35 TerritoryFlag totem = TerritoryFlag.Cast( target.GetObject() );
36 if (!totem)
37 return false;
38
39 float state = totem.GetAnimationPhase("flag_mast");
40
41 if ( totem && totem.FindAttachmentBySlotName("Material_FPole_Flag") )
42 {
43 if ( player.GetFlagTendencyRaise() && state < 1 )
44 {
45 m_switch_to = true;
46 return true;
47 }
48 else if ( !player.GetFlagTendencyRaise() && state > 0 )
49 {
50 m_switch_to = false;
51 return true;
52 }
53 }
54 return false;
55 }

Перекрестные ссылки ActionTarget и m_switch_to.