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

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

override void OnEntry (WeaponEventBase e)
 
override void OnEntry (WeaponEventBase e)
 
override void OnExit (WeaponEventBase e)
 
override void OnEntry (WeaponEventBase e)
 

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

Методы

◆ OnEntry() [1/3]

override void OnEntry ( WeaponEventBase e)
inlineprivate
101 {
102 m_dtAccumulator = 0;
103
104 if (LogManager.IsWeaponLogEnable()) { wpnPrint("[wpnfsm] " + Object.GetDebugName(m_weapon) + " WeaponFire bang!"); }
105 //m_weapon.Fire();
106 int mi = m_weapon.GetCurrentMuzzle();
108 {
110 if (Class.CastTo(p, e.m_player))
111 p.GetAimingModel().SetRecoil(m_weapon);
112 m_weapon.EjectCasing(mi);
113 m_weapon.EffectBulletHide(mi);
114 m_weapon.OnFire(mi);
115 }
116 super.OnEntry(e);
117 }
void wpnPrint(string s)
Definition Debug.c:1
class WeaponGuardIsDestroyed extends WeaponGuardBase m_weapon
Definition Guards.c:604
class WeaponFireWithEject extends WeaponFire m_dtAccumulator
proto native bool TryFireWeapon(EntityAI weapon, int muzzleIndex)
Super root of all classes in Enforce script.
Definition EnScript.c:11
Definition ManBase.c:2
Definition Debug.c:600
static bool IsWeaponLogEnable()
Definition Debug.c:724
Definition ObjectTyped.c:2
Definition EntityAI.c:95
static proto bool CastTo(out Class to, Class from)
Try to safely down-cast base class to child class.

Перекрестные ссылки Class::CastTo(), LogManager::IsWeaponLogEnable(), m_dtAccumulator, m_weapon, TryFireWeapon() и wpnPrint().

◆ OnEntry() [2/3]

override void OnEntry ( WeaponEventBase e)
inlineprivate
318 {
319 super.OnEntry(e);
320 if (e)
321 {
322 if (GetGame().IsServer())
323 {
325 Class.CastTo(playerOwner, m_weapon.GetHierarchyParent());
326 m_weapon.AddJunctureToAttachedMagazine(playerOwner, 100);
327 }
328 if (!m_weapon.IsJammed())
329 {
330 if (LogManager.IsWeaponLogEnable()) { wpnDebugPrint("[wpnfsm] " + Object.GetDebugName(m_weapon) + " ejected fired out casing"); }
331 int mi = m_weapon.GetCurrentMuzzle();
332 m_weapon.EjectCasing(mi);
333 m_weapon.EffectBulletHide(mi);
334 m_weapon.SelectionBulletHide();
335
337 }
338 }
339 }
void wpnDebugPrint(string s)
Definition Debug.c:9
Definition PlayerBaseClient.c:2
proto native CGame GetGame()
bool pushToChamberFromAttachedMagazine(Weapon_Base weapon, int muzzleIndex)
Definition weapon_utils.c:1

Перекрестные ссылки Class::CastTo(), GetGame(), LogManager::IsWeaponLogEnable(), m_weapon, pushToChamberFromAttachedMagazine() и wpnDebugPrint().

◆ OnEntry() [3/3]

override void OnEntry ( WeaponEventBase e)
inlineprivate
357 {
358 super.OnEntry(e);
359
360 if (!m_weapon.IsJammed())
361 {
362 if (LogManager.IsWeaponLogEnable()) { wpnDebugPrint("[wpnfsm] " + Object.GetDebugName(m_weapon) + " ejected fired out casing"); }
363 int mi = m_weapon.GetCurrentMuzzle();
364 m_weapon.EjectCasing(mi);
365 m_weapon.EffectBulletHide(mi);
366 m_weapon.SelectionBulletHide();
367
369 }
370 }
bool pushToChamberFromInnerMagazine(Weapon_Base weapon, int muzzleIndex)
Definition weapon_utils.c:33

Перекрестные ссылки LogManager::IsWeaponLogEnable(), m_weapon, pushToChamberFromInnerMagazine() и wpnDebugPrint().

◆ OnExit()

override void OnExit ( WeaponEventBase e)
inlineprivate
342 {
343 super.OnExit(e);
344 if (GetGame().IsServer())
345 {
347 Class.CastTo(playerOwner, m_weapon.GetHierarchyParent());
348 m_weapon.ClearJunctureToAttachedMagazine(playerOwner);
349 }
350
351 }

Перекрестные ссылки Class::CastTo(), GetGame() и m_weapon.


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