Dayz 1.25
Dayz Code Explorer by KGB
Загрузка...
Поиск...
Не найдено
Класс WeaponEventBase

signalize mechanism manipulation Подробнее...

Закрытые члены

void WeaponEventBase (DayZPlayer p=NULL, Magazine m=NULL)
 
WeaponEventID GetEventID ()
 returns id from enum WeaponEventID
 
WeaponEvents GetAnimEvent ()
 returns animation event from anim engine,
 
int GetPackedType ()
 returns eventID in upper 16 bits and AnimEvent in lower 16 bits
 
void ReadFromContext (ParamsReadContext ctx)
 
void WriteToContext (ParamsWriteContext ctx)
 
string DumpToString ()
 
void WeaponEventMechanism (DayZPlayer p=NULL, Magazine m=NULL)
 
void WeaponEventTrigger (DayZPlayer p=NULL, Magazine m=NULL)
 
void WeaponEventTriggerToJam (DayZPlayer p=NULL, Magazine m=NULL)
 
void WeaponEventTriggerAutoStart (DayZPlayer p=NULL, Magazine m=NULL)
 
void WeaponEventTriggerAutoEnd (DayZPlayer p=NULL, Magazine m=NULL)
 
void WeaponEventLoad1Bullet (DayZPlayer p=NULL, Magazine m=NULL)
 
void WeaponEventContinuousLoadBulletStart (DayZPlayer p=NULL, Magazine m=NULL)
 
void WeaponEventContinuousLoadBulletEnd (DayZPlayer p=NULL, Magazine m=NULL)
 
void WeaponEventUnjam (DayZPlayer p=NULL, Magazine m=NULL)
 
void WeaponEventAttachMagazine (DayZPlayer p=NULL, Magazine m=NULL)
 
void WeaponEventUnjammingFailedTimeout (DayZPlayer p=NULL, Magazine m=NULL)
 
void WeaponEventUnjammingTimeout (DayZPlayer p=NULL, Magazine m=NULL)
 
void WeaponEventDetachMagazine (DayZPlayer p=NULL, Magazine m=NULL, InventoryLocation il=NULL)
 
override void ReadFromContext (ParamsReadContext ctx)
 
override void WriteToContext (ParamsWriteContext ctx)
 
void WeaponEventSwapMagazine (DayZPlayer p=NULL, Magazine m=NULL, InventoryLocation il=NULL)
 
override void ReadFromContext (ParamsReadContext ctx)
 
override void WriteToContext (ParamsWriteContext ctx)
 
void WeaponEventHumanCommandActionFinished (DayZPlayer p=NULL, Magazine m=NULL)
 
void WeaponEventHumanCommandActionAborted (DayZPlayer p=NULL, Magazine m=NULL)
 
void WeaponEventReloadTimeout (DayZPlayer p=NULL, Magazine m=NULL)
 
void WeaponEventDryFireTimeout (DayZPlayer p=NULL, Magazine m=NULL)
 
void WeaponEventSetNextMuzzleMode (DayZPlayer p=NULL, Magazine m=NULL)
 
void WeaponEventAnimation (DayZPlayer p=NULL, Magazine m=NULL)
 animation event from Human.WeaponEvents
 
override int GetAnimEvent ()
 

Закрытые данные

int m_eventID
 
DayZPlayer m_player
 
Magazine m_magazine
 
ref InventoryLocation m_dst
 
WeaponEvents m_type
 

Подробное описание

signalize mechanism manipulation

represents event that triggers transition from state to state

triggered when dry fire timer expires

triggered when reload timer expires

triggered when animation action aborts

triggered when animation action finishes

event when user wants to swap magazine

event when user wants to detach magazine

triggered when unjamming failed timer expires

triggered when unjamming timer expires

event when user wants to attach magazine

event when user wants to unjam weapon

event when user wants to end loading of bullets

event when user wants to load N bullets

event when user wants to load 1 bullet

event when trigger pressed

Аргументы
dstinventory location where the magazine will be stored

Конструктор(ы)

◆ WeaponEventBase()

void WeaponEventBase ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate
40{ m_eventID = 0; m_player = p; m_magazine = m; }
Definition EntityAI.c:95
Magazine m_magazine
Definition Events.c:38
int m_eventID
Definition Events.c:36
DayZPlayer m_player
Definition Events.c:37

Перекрестные ссылки m_eventID, m_magazine и m_player.

Методы

◆ DumpToString()

string DumpToString ( )
inlineprivate
63 {
64 string res = "{ WpnEv id=" + typename.EnumToString(WeaponEventID, GetEventID());
65 res = res + " pl=" + Object.GetDebugName(m_player);
66 res = res + " mag=" + Object.GetDebugName(m_magazine);
67 res = res + " }";
68 return res;
69 }
WeaponEventID
identifier for events. mainly for rpc purposes
Definition Events.c:6
Definition ObjectTyped.c:2
WeaponEventID GetEventID()
returns id from enum WeaponEventID
Definition Events.c:42

Перекрестные ссылки GetEventID(), m_magazine и m_player.

◆ GetAnimEvent() [1/2]

WeaponEvents GetAnimEvent ( )
inlineprivate

returns animation event from anim engine,

См. также
WeaponEvents
44{ return -1; }

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

◆ GetAnimEvent() [2/2]

override int GetAnimEvent ( )
inlineprivate
219{ return m_type; }
WeaponEvents m_type
Definition Events.c:217

◆ GetEventID()

WeaponEventID GetEventID ( )
inlineprivate

returns id from enum WeaponEventID

42{ return m_eventID; }

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

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

◆ GetPackedType()

int GetPackedType ( )
inlineprivate

returns eventID in upper 16 bits and AnimEvent in lower 16 bits

47 {
48 int animEvent = GetAnimEvent() & 0x0000ffff;
49 int evShl = m_eventID << 16;
50 return evShl | animEvent;
51 }
WeaponEvents GetAnimEvent()
returns animation event from anim engine,
Definition Events.c:44

Перекрестные ссылки GetAnimEvent() и m_eventID.

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

◆ ReadFromContext() [1/3]

void ReadFromContext ( ParamsReadContext ctx)
inlineprivate
53{ }

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

◆ ReadFromContext() [2/3]

override void ReadFromContext ( ParamsReadContext ctx)
inlineprivate
153 {
155 super.ReadFromContext(ctx);
156 m_dst.ReadFromContext(ctx);
157 }
InventoryLocation.
Definition InventoryLocation.c:28
ref InventoryLocation m_dst
Definition Events.c:149

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

◆ ReadFromContext() [3/3]

override void ReadFromContext ( ParamsReadContext ctx)
inlineprivate
172 {
173 super.ReadFromContext(ctx);
175 m_dst.ReadFromContext(ctx);
176 }

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

◆ WeaponEventAnimation()

void WeaponEventAnimation ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate

animation event from Human.WeaponEvents

218{ m_eventID = WeaponEventID.ANIMATION_EVENT; }

◆ WeaponEventAttachMagazine()

void WeaponEventAttachMagazine ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate
130{ m_eventID = WeaponEventID.ATTACH_MAGAZINE; }

◆ WeaponEventContinuousLoadBulletEnd()

void WeaponEventContinuousLoadBulletEnd ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate
118{ m_eventID = WeaponEventID.CONTINUOUS_LOADBULLET_END; }

◆ WeaponEventContinuousLoadBulletStart()

void WeaponEventContinuousLoadBulletStart ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate
112{ m_eventID = WeaponEventID.CONTINUOUS_LOADBULLET_START; }

◆ WeaponEventDetachMagazine()

void WeaponEventDetachMagazine ( DayZPlayer p = NULL,
Magazine m = NULL,
InventoryLocation il = NULL )
inlineprivate
150{ m_eventID = WeaponEventID.DETACH_MAGAZINE; m_dst = il; }

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

◆ WeaponEventDryFireTimeout()

void WeaponEventDryFireTimeout ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate
205{ m_eventID = WeaponEventID.DRY_FIRE_TIMEOUT; }

◆ WeaponEventHumanCommandActionAborted()

void WeaponEventHumanCommandActionAborted ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate
193{ m_eventID = WeaponEventID.HUMANCOMMAND_ACTION_ABORTED; }

◆ WeaponEventHumanCommandActionFinished()

void WeaponEventHumanCommandActionFinished ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate
187{ m_eventID = WeaponEventID.HUMANCOMMAND_ACTION_FINISHED; }

◆ WeaponEventLoad1Bullet()

void WeaponEventLoad1Bullet ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate
106{ m_eventID = WeaponEventID.LOAD1_BULLET; }

◆ WeaponEventMechanism()

void WeaponEventMechanism ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate
76{ m_eventID = WeaponEventID.MECHANISM; }

◆ WeaponEventReloadTimeout()

void WeaponEventReloadTimeout ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate
199{ m_eventID = WeaponEventID.RELOAD_TIMEOUT; }

◆ WeaponEventSetNextMuzzleMode()

void WeaponEventSetNextMuzzleMode ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate
212{ m_eventID = WeaponEventID.SET_NEXT_MUZZLE_MODE; }

◆ WeaponEventSwapMagazine()

void WeaponEventSwapMagazine ( DayZPlayer p = NULL,
Magazine m = NULL,
InventoryLocation il = NULL )
inlineprivate
169{ m_eventID = WeaponEventID.SWAP_MAGAZINE;m_dst = il; }

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

◆ WeaponEventTrigger()

void WeaponEventTrigger ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate
82{ m_eventID = WeaponEventID.TRIGGER; }

◆ WeaponEventTriggerAutoEnd()

void WeaponEventTriggerAutoEnd ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate
100{ m_eventID = WeaponEventID.TRIGGER_AUTO_END; }

◆ WeaponEventTriggerAutoStart()

void WeaponEventTriggerAutoStart ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate
94{ m_eventID = WeaponEventID.TRIGGER_AUTO_START; }

◆ WeaponEventTriggerToJam()

void WeaponEventTriggerToJam ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate
88{ m_eventID = WeaponEventID.TRIGGER_JAM; }

◆ WeaponEventUnjam()

void WeaponEventUnjam ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate
124{ m_eventID = WeaponEventID.UNJAM; }

◆ WeaponEventUnjammingFailedTimeout()

void WeaponEventUnjammingFailedTimeout ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate
136{ m_eventID = WeaponEventID.UNJAMMING_FAILED_TIMEOUT; }

◆ WeaponEventUnjammingTimeout()

void WeaponEventUnjammingTimeout ( DayZPlayer p = NULL,
Magazine m = NULL )
inlineprivate
142{ m_eventID = WeaponEventID.UNJAMMING_TIMEOUT; }

◆ WriteToContext() [1/3]

void WriteToContext ( ParamsWriteContext ctx)
inlineprivate
55 {
57 ctx.Write(packedType);
58 ctx.Write(m_player);
59 ctx.Write(m_magazine);
60 }
int GetPackedType()
returns eventID in upper 16 bits and AnimEvent in lower 16 bits
Definition Events.c:46

Перекрестные ссылки GetPackedType(), m_magazine и m_player.

◆ WriteToContext() [2/3]

override void WriteToContext ( ParamsWriteContext ctx)
inlineprivate
159 {
160 super.WriteToContext(ctx);
161 m_dst.WriteToContext(ctx);
162 }

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

◆ WriteToContext() [3/3]

override void WriteToContext ( ParamsWriteContext ctx)
inlineprivate
178 {
179 super.WriteToContext(ctx);
180 m_dst.WriteToContext(ctx);
181 }

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

Поля

◆ m_dst

ref InventoryLocation m_dst
private

◆ m_eventID

int m_eventID
private

Используется в GetEventID(), GetPackedType() и WeaponEventBase().

◆ m_magazine

Magazine m_magazine
private

Используется в DumpToString(), WeaponEventBase() и WriteToContext().

◆ m_player

DayZPlayer m_player
private

Используется в DumpToString(), WeaponEventBase() и WriteToContext().

◆ m_type

WeaponEvents m_type
private

Объявления и описания членов класса находятся в файле: