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

◆ OnFinishProgressServer()

override void ActionUnrestrainSelf::OnFinishProgressServer ( ActionData action_data)
inlineprivate

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

86 {
87 PlayerBase player = PlayerBase.Cast(action_data.m_Player);
88 EntityAI item_in_hands = action_data.m_MainItem;
89
90 if (item_in_hands)
91 {
92 if (item_in_hands.IsInherited(BarbedWireLocked))
93 {
94 int randNum = Math.RandomInt(0, 3); // Values 0 to 3 represent fore arm and arm roll bleed sources
95 player.m_BleedingManagerServer.AttemptAddBleedingSourceBySelection(PlayerBase.m_BleedingSourcesUp[randNum]);
96 }
97 player.SetRestrained(false);
98 item_in_hands.AddHealth(-GameConstants.CLEAN_UNRESTRAIN_DAMAGE);
99 MiscGameplayFunctions.TransformRestrainItem(item_in_hands, null, null, player);
100 //string new_item_name = MiscGameplayFunctions.ObtainRestrainItemTargetClassname(item_in_hands);
101 //MiscGameplayFunctions.TurnItemInHandsIntoItemEx(player, new UnrestrainSelfPlayer(item_in_hands, new_item_name));
102 }
103 }
class LogManager EntityAI

Перекрестные ссылки ActionData, GameConstants::CLEAN_UNRESTRAIN_DAMAGE и Math::RandomInt().