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

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

void HandEventForceSwap (Man p=null, InventoryLocation src=null, InventoryLocation src2=null, InventoryLocation dst=null, InventoryLocation dst2=null)
 
override bool CheckRequest ()
 
override bool CanPerformEvent ()
 

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

Методы

◆ CanPerformEvent()

override bool CanPerformEvent ( )
inlineprivate
701 {
702 bool test2 = GameInventory.CanForceSwapEntitiesEx(m_Src.GetItem(), m_Dst, m_Src2.GetItem(), m_Dst2); // null here means 'do not search for dst2' (already have valid one from constructor)
703 #ifdef ENABLE_LOGGING
705 {
706 if (!test2)
707 Debug.InventoryHFSMLog("CanForceSwapEntitiesEx failed", typename.EnumToString(HandEventID, GetEventID()) , "n/a", "CanPerformEvent", m_Player.ToString() );
708 }
709 #endif
710 return test2;
711 }
DayZPlayer m_Player
Definition Hand_Events.c:42
ref InventoryLocation m_Src
Definition Hand_Events.c:43
HandEventID GetEventID()
Definition Hand_Events.c:53
HandEventID
events
Definition Hand_Events.c:7
Definition Debug.c:14
static void InventoryHFSMLog(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Definition Debug.c:161
script counterpart to engine's class Inventory
Definition Inventory.c:79
static bool CanForceSwapEntitiesEx(notnull EntityAI item1, InventoryLocation item1_dst, notnull EntityAI item2, out InventoryLocation item2_dst)
Definition Inventory.c:664
Definition Debug.c:600
static bool IsInventoryHFSMLogEnable()
Definition Debug.c:674
Definition EntityAI.c:95

Перекрестные ссылки GameInventory::CanForceSwapEntitiesEx(), GetEventID(), Debug::InventoryHFSMLog(), LogManager::IsInventoryHFSMLogEnable(), m_Player и m_Src.

◆ CheckRequest()

override bool CheckRequest ( )
inlineprivate
683 {
684 bool test1 = false;
685 EntityAI inHands = m_Player.GetHumanInventory().GetEntityInHands();
686 if (GetSrcEntity() && inHands && m_Dst && m_Dst.IsValid())
687 {
689 #ifdef ENABLE_LOGGING
691 {
692 if (!test1)
693 Debug.InventoryHFSMLog("CheckSwapItemsRequest failed", typename.EnumToString(HandEventID, GetEventID()) , "n/a", "CheckRequest", m_Player.ToString() );
694 }
695 #endif
696 }
697 return test1;
698 }
EntityAI GetSrcEntity()
Definition Hand_Events.c:81
Definition Building.c:6
const float c_MaxItemDistanceRadius
anti-cheats
Definition Inventory.c:813
static proto native bool CheckSwapItemsRequest(notnull Man requestingPlayer, notnull InventoryLocation src1, notnull InventoryLocation src2, notnull InventoryLocation dst1, notnull InventoryLocation dst2, float radius)

Перекрестные ссылки GameInventory::c_MaxItemDistanceRadius, GameInventory::CheckSwapItemsRequest(), GetEventID(), GetSrcEntity(), Debug::InventoryHFSMLog(), LogManager::IsInventoryHFSMLogEnable(), m_Player и m_Src.

◆ HandEventForceSwap()

void HandEventForceSwap ( Man p = null,
InventoryLocation src = null,
InventoryLocation src2 = null,
InventoryLocation dst = null,
InventoryLocation dst2 = null )
inlineprivate
680{ m_EventID = HandEventID.FORCESWAP; }
m_EventID

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


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