DayZ Scripts
v1.21.156300 ยท Jun 20, 2023
 
Loading...
Searching...
No Matches
ActionViewCompass.c
Go to the documentation of this file.
2{
3 override void CreateActionComponent()
4 {
6 //EnableStateChangeCallback();
7 }
8
9 override void OnStateChange(int pOldState, int pCurrentState)
10 {
11 //Print("pOldState = " + pOldState);
12 //Print("pCurrentState = " + pCurrentState);
13
14 if (pOldState != STATE_LOOP_LOOP)
15 return;
16
18 {
19 //ActionViewOptics.Cast(m_ActionData.m_Action).ExitOptics( ItemOptics.Cast(m_ActionData.m_MainItem), m_ActionData.m_Player );
20 }
21 }
22};
23
25{
27 {
29 m_CommandUID = DayZPlayerConstants.CMD_ACTIONMOD_OPENITEM_ONCE;
30 m_CommandUIDProne = DayZPlayerConstants.CMD_ACTIONFB_OPENITEM_ONCE;
31 m_Text = "#use_compas";
32 }
33
35 {
38 }
39
40 override bool HasProgress()
41 {
42 return false;
43 }
44
45 override bool HasTarget()
46 {
47 return false;
48 }
49
50 override bool HasProneException()
51 {
52 return true;
53 }
54
55 override bool ActionCondition( PlayerBase player, ActionTarget target, ItemBase item )
56 {
57 return item.IsOpen();
58 }
59
60 /*override void OnCompleteServer( ActionData action_data )
61 {
62 if (action_data.m_Player)
63 {
64 string message = Rangefinder.Cast( action_data.m_MainItem ).DoMeasurement(action_data.m_Player);
65 SendMessageToClient(action_data.m_Player,message);
66 }
67
68 action_data.m_Player.GetSoftSkillManager().AddSpecialty( m_SpecialtyWeight );
69 }*/
70}
ref CCIBase m_ConditionItem
Definition ActionBase.c:55
ref CCTBase m_ConditionTarget
Definition ActionBase.c:56
protected string m_Text
Definition ActionBase.c:49
class ActionTargets ActionTarget
protected ActionData m_ActionData
ref ActionBase m_Action
Definition ActionBase.c:27
ref CABase m_ActionComponent
Definition ActionBase.c:30
override void OnStateChange(int pOldState, int pCurrentState)
override void CreateActionComponent()
override bool HasProgress()
override void CreateConditionComponents()
override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
override bool HasTarget()
override bool HasProneException()
protected int m_CommandUIDProne
DayZPlayerConstants
defined in C++
Definition dayzplayer.c:602
static const int STATE_LOOP_LOOP
Definition human.c:344