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

◆ OnSuccess()

override void ReplaceWithNewReciveCargoLambda::OnSuccess ( EntityAI new_item)
inlineprotected

См. определение в файле ActionPackGift.c строка 141

142 {
143 super.OnSuccess(new_item);
144
145 InventoryLocation src = new InventoryLocation;
146 m_ItemToCargo.GetInventory().GetCurrentInventoryLocation(src);
147 InventoryLocation dst = new InventoryLocation;
148
149 dst.SetCargo(new_item, m_ItemToCargo, 0,0,0,false);
150
151 if ( dst.IsValid() )
152 {
153 if(g_Game.IsDedicatedServer())
154 m_Player.ServerTakeToDst(src,dst);
155 else
156 m_Player.LocalTakeToDst(src,dst);
157
158 }
159 }
DayZGame g_Game
Определения DayZGame.c:4074
DayZPlayer m_Player
Определения Hand_Events.c:42
proto native bool IsValid()
verify current set inventory location
proto native void SetCargo(notnull EntityAI parent, EntityAI e, int idx, int row, int col, bool flip)
sets current inventory location type to Cargo with coordinates (idx, row, col)
EntityAI m_ItemToCargo
Определения ActionPackGift.c:135

Перекрестные ссылки g_Game, InventoryLocation::IsValid(), m_ItemToCargo, m_Player и InventoryLocation::SetCargo().