Dayz Explorer 1.28.160049
Loading...
Searching...
No Matches
actionviewcompass.c
Go to the documentation of this file.
2{
3 override void CreateActionComponent()
4 {
5 m_ActionData.m_ActionComponent = new CAContinuousTime( -1.0 );
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
17 if (m_ActionData.m_Action && ActionViewOptics.Cast(m_ActionData.m_Action))
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
34 override void CreateConditionComponents()
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}
ActionData m_ActionData
string m_Text
Definition actionbase.c:58
ref CCIBase m_ConditionItem
Definition actionbase.c:64
ref CCTBase m_ConditionTarget
Definition actionbase.c:65
DayZPlayerConstants
defined in C++
Definition dayzplayer.c:602