DayZ 1.30
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено
EmoteManager.c
См. документацию.
2{
4 int m_callbackID; //Animation cmd ID
7
8 void ~EmoteCB()
9 {
10 if (m_Manager)
11 {
12 m_Manager.OnCallbackEnd();
13 }
14
15 if (g_Game && m_player)
16 m_player.RequestHandAnimationStateRefresh();
17 }
18
20 {
21 return false;
22 }
23
25 {
26 return IsGestureCallback();
27 }
28
29 override void OnAnimationEvent(int pEventID)
30 {
31 switch (pEventID)
32 {
34
35 if (g_Game.IsServer())
36 m_Manager.KillPlayer();
37
38 m_Manager.LogSuicide();
39 break;
40
42 if (g_Game.IsServer())
43 m_Manager.CreateBleedingEffect(m_callbackID);
44 break;
45
47 m_player.DeathDropHandEntity();
48 m_player.StartDeath();
49 break;
50 }
51 }
52
53 override bool IsGestureCallback()
54 {
55 return true;
56 }
57};
58
60{
61 static const int FORCE_NONE = 0;
62 static const int FORCE_DIFFERENT = 1;
63 static const int FORCE_ALL = 2;
64
66 protected bool m_IsStartGuaranteed; //remains in queue until played or canceled directly (logout sit pose etc.)
67 protected bool m_SyncRequestSent;
68 protected int m_ForcePlayEmote;
69 protected int m_ID;
70
71 void EmoteLauncher(int emoteID, bool interrupts_same)
72 {
73 m_ID = emoteID;
74 m_InterruptsSameIDEmote = interrupts_same;
76 m_IsStartGuaranteed = false;
77 m_SyncRequestSent = false;
78 }
79
80 void SetForced(int mode)
81 {
82 m_ForcePlayEmote = mode;
83 }
84
86 {
87 return m_ForcePlayEmote;
88 }
89
90 int GetID()
91 {
92 return m_ID;
93 }
94
95 void SetStartGuaranteed(bool guaranted)
96 {
97 m_IsStartGuaranteed = guaranted;
98 }
99
101 {
102 return m_IsStartGuaranteed;
103 }
104
106 {
107 m_SyncRequestSent = true;
108 }
109
111 {
112 return m_SyncRequestSent;
113 }
114}
115
116class EmoteManager
117{
131 protected bool m_DisconnectEmoteQueued; //reaction to client logging out
132 protected bool m_DeferredEmoteLauncherCleanup; //safe cleanup from the outside
133 protected bool m_ItemToHands; //deprecated
134 protected bool m_ItemIsOn;
135 protected bool m_MouseButtonPressed;
136 protected bool m_PlayerDies;
137 protected bool m_controllsLocked;
139 protected bool m_EmoteLockState;
140 protected int m_DeferredGuaranteedEmoteId; //secondary emote ID to ensure playback
142 protected int m_GestureID;
143 protected int m_PreviousGestureID;
144 protected int m_CurrentGestureID;
145 protected int m_LastMask;
146 protected int m_RPSOutcome;
148 protected const int CALLBACK_CMD_INVALID = -1;
149 protected const int CALLBACK_CMD_END = -2;
150 protected const int CALLBACK_CMD_GESTURE_INTERRUPT = -3;
151 protected const int CALLBACK_CMD_INSTACANCEL = -4;
152 PluginAdminLog m_AdminLog;
153
154 protected ref map<int, ref EmoteBase> m_NameEmoteMap; //<emote_ID,EmoteBase>
155 protected ref array<ref EmoteBase> m_EmoteClassArray; //registered 'EmoteBase' object refs
156 protected ref array<int> m_EmoteIDs; //IDs of registered emotes (found in 'EmoteConstants'). For quick access.
157 protected ref array<int> m_EmoteInputIDs; //input IDs for the registered 'EmoteBase' objects
159
161 {
162 m_Player = player;
163 m_HIC = m_Player.GetInputController();
164 m_ItemIsOn = false;
165 m_controllsLocked = false;
169 m_RPSOutcome = -1;
172
174 m_InterruptInputs.Insert("UAMoveForward");
175 m_InterruptInputs.Insert("UAMoveBack");
176 m_InterruptInputs.Insert("UATurnLeft");
177 m_InterruptInputs.Insert("UATurnRight");
178 m_InterruptInputs.Insert("UAMoveLeft");
179 m_InterruptInputs.Insert("UAMoveRight");
180 m_InterruptInputs.Insert("UAStand");
181 m_InterruptInputs.Insert("UACrouch");
182 m_InterruptInputs.Insert("UAProne");
183 m_InterruptInputs.Insert("UAGetOver");
184
186 m_HandInventoryLocation.SetHands(m_Player, null);
187
188 if (g_Game.IsServer())
189 {
190 m_AdminLog = PluginAdminLog.Cast(GetPlugin(PluginAdminLog));
191 }
192
193 m_HumanSwimSettings = m_Player.GetDayZPlayerType().CommandSwimSettingsW();
194
196 }
197
199 {
200 }
201
203 {
205 if (!m_NameEmoteMap)
206 {
211 int inputID;
212 int count = m_NameEmoteMap.Count();
213 UAInput inp;
214
215 for (int i = 0; i < count; i++)
216 {
217 m_EmoteClassArray.Insert(m_NameEmoteMap.GetElement(i));
218 m_EmoteIDs.Insert(m_NameEmoteMap.GetElement(i).GetID());
219 inp = GetUApi().GetInputByName(m_NameEmoteMap.GetElement(i).GetInputActionName());
220 inputID = inp.ID();
221 m_EmoteInputIDs.Insert(inputID);
222 }
223
224 if (m_EmoteInputIDs.Count() != m_EmoteClassArray.Count())
225 {
226 ErrorEx("Faulty emote data detected in 'ConstructData' method!",ErrorExSeverity.WARNING);
227 }
228 }
229 }
230
231 void SetGesture(int id)
232 {
233 m_GestureID = id;
234 }
235
237 {
238 return m_GestureID;
239 }
240
242 {
243 int count = m_EmoteInputIDs.Count();
244 for (int i = 0; i < count; ++i)
245 {
246 if (GetUApi().GetInputByID(m_EmoteInputIDs[i]).LocalPress())
247 {
248 return m_EmoteIDs[i];
249 }
250 }
251
252 return 0;
253 }
254
256 bool DetermineEmoteData(EmoteBase emote, out int callback_ID, out int stancemask, out bool is_fullbody)
257 {
258 if (emote.DetermineOverride(callback_ID, stancemask, is_fullbody))
259 {
260 return emote.EmoteFBStanceCheck(stancemask);
261 }
262 else if (emote.GetAdditiveCallbackUID() != 0 && m_Player.IsPlayerInStance(emote.GetStanceMaskAdditive()))
263 {
264 callback_ID = emote.GetAdditiveCallbackUID();
265 stancemask = emote.GetStanceMaskAdditive();
266 is_fullbody = false;
267 return true;
268 }
269 else if (emote.GetFullbodyCallbackUID() != 0 && emote.EmoteFBStanceCheck(emote.GetStanceMaskFullbody()))
270 {
271 callback_ID = emote.GetFullbodyCallbackUID();
272 stancemask = emote.GetStanceMaskFullbody();
273 is_fullbody = true;
274 return true;
275 }
276
277 return false;
278 }
279
280 void SetPending(bool state)
281 {
283 }
284
285 //Called from players commandhandler each frame, checks input
286 void Update(float deltaT)
287 {
288 // no updates on restrained characters
289 if (m_Player.IsRestrained())
290 return;
291
292 int gestureSlot = 0;
293 #ifndef SERVER
294 gestureSlot = DetermineGestureIndex();
295 #endif
296
297 //nuclear solution to inventory question
298 #ifndef NO_GUI
299 if (g_Game.IsClient() && g_Game.GetUIManager().FindMenu(MENU_INVENTORY) && IsEmotePlaying())
300 m_Player.CloseInventoryMenu();
301 #endif
302
303 //deferred emote cancel
304 if (m_InstantCancelEmote) //'hard' cancel
305 {
306 if (m_Callback)
307 m_Callback.Cancel();
308
311 m_InstantCancelEmote = false;
312 SetPending(false);
313
314 if (m_Player.IsSurrendered())
316 else
317 SetEmoteLockState(false);
318 }
319 else if (m_CancelEmote) //'soft' cancel
320 {
321 SetPending(false);
322 m_CancelEmote = false;
323
324 if (m_Player.IsSurrendered())
326 else if (m_Callback)
327 m_Callback.InternalCommand(DayZPlayerConstants.CMD_ACTIONINT_INTERRUPT);
328 }
329
331 {
332 ClearEmoteLauncher(true);
334 }
335
336 //if (m_DisconnectEmoteQueued && (!m_bEmoteIsPlaying && !m_bEmoteIsRequestPending))
338 {
339 if (!m_MenuEmote || !m_MenuEmote.IsStartGuaranteed())
340 {
343 m_MenuEmote.SetStartGuaranteed(true);
344
345 EmoteBase emote = EmoteBase.Cast(m_NameEmoteMap.Get(m_MenuEmote.GetID()));
346 int stanceIdx = DayZPlayerUtils.ConvertStanceMaskToStanceIdx(emote.GetStanceMaskFullbody());
347
348 //if the emote cannot be played, don't sent a request to server
349 if (!DayZPlayerUtils.PlayerCanChangeStance(m_Player, stanceIdx))
350 {
351 m_MenuEmote = null; //setting this to null also ensures that the forcedEmotQueuedClient below is also false
353 }
354 }
355 }
356
357 bool forcedEmoteQueuedClient = m_MenuEmote && !m_MenuEmote.WasSynced() && m_MenuEmote.GetForced() > EmoteLauncher.FORCE_NONE && !g_Game.IsDedicatedServer();
358 if (forcedEmoteQueuedClient) //regular forced emote playing
359 {
361 }
362 else if (m_Callback)
363 {
364 bool uiGesture = false;
365 if (!g_Game.IsHeadlessOrDedicatedServer())
366 {
367 uiGesture = g_Game.GetUIManager().IsMenuOpen(MENU_GESTURES);
368
370 {
372 }
373
375 {
377 }
378 }
379
380 if (gestureSlot > 0 || m_GestureInterruptInput || (m_HIC.IsSingleUse() && !uiGesture) || (m_HIC.IsContinuousUseStart() && !uiGesture) || (m_Callback.m_IsFullbody && !uiGesture && m_HIC.IsWeaponRaised()))
381 {
383 {
384 if (m_Callback.GetState() == m_Callback.STATE_LOOP_LOOP)
385 {
387 }
388 else
389 {
390 return;
391 }
392 }
394 {
395 m_Callback.InternalCommand(DayZPlayerConstants.CMD_ACTIONINT_ACTION);
396 }
398 {
399 if (m_RPSOutcome != -1)
400 {
401 if (m_RPSOutcome == 0)
402 {
403 m_Callback.InternalCommand(DayZPlayerConstants.CMD_ACTIONINT_RPS_ROCK);
404 }
405 else if (m_RPSOutcome == 1)
406 {
407 m_Callback.InternalCommand(DayZPlayerConstants.CMD_ACTIONINT_RPS_PAPER);
408 }
409 else if (m_RPSOutcome == 2)
410 {
411 m_Callback.InternalCommand(DayZPlayerConstants.CMD_ACTIONINT_RPS_SCISSORS);
412 }
413 m_RPSOutcome = -1;
414 }
415 else
416 {
417 m_Callback.InternalCommand(DayZPlayerConstants.CMD_ACTIONINT_END);
418 }
419 }
421 {
423 }
425 {
427 }
428 }
429
430 if (m_LastMask != -1 && m_Player.IsPlayerInStance(DayZPlayerConstants.STANCEMASK_PRONE))
431 {
432 m_Callback.Cancel();
433 }
434
435 if (m_MenuEmote && !m_MenuEmote.IsStartGuaranteed() && m_bEmoteIsPlaying)
436 {
438 }
439
441 {
443 }
444
446 {
448 }
449 }
450 //no m_Callback exists
451 else
452 {
453 if (m_bEmoteIsRequestPending && (m_Player.IsUnconscious() || !m_Player.IsAlive()))
454 {
455 SetPending(false);
456 }
457
459 {
460 OnEmoteEnd();
461 }
462 // getting out of surrender state
463 else if (m_Player.IsSurrendered() && (m_HIC.IsSingleUse() || m_HIC.IsContinuousUseStart() || m_HIC.IsWeaponRaised()))
464 {
466 return;
467 }
468 //actual emote launch
470 {
472 //m_DeferredGuaranteedEmoteId = CALLBACK_CMD_INVALID;
473 }
475 {
478 }
479 //client-side emote launcher
480 else if (!m_bEmoteIsPlaying && m_MenuEmote && !m_MenuEmote.WasSynced() && !g_Game.IsDedicatedServer())
481 {
483 }
484 else if (!m_MenuEmote && gestureSlot > 0)
485 {
486 CreateEmoteCBFromMenu(gestureSlot,true); //translation no longer needed
487 }
488 }
489 }
490
492 {
494
495 if (m_PlayerDies)
496 {
497 m_Player.SetHealth(0.0);
498 return;
499 }
500
502 m_bEmoteIsPlaying = false;
503 SetPending(false);
504
505 if (m_Player.IsSurrendered())
506 return;
507
509 SetEmoteLockState(false);
510
511 // back to the default - shoot from camera - if not set already
512 if (!m_Player.IsShootingFromCamera())
513 m_Player.OverrideShootFromCamera(true);
514 }
515
516 //server-side
517 bool OnInputUserDataProcess(int userDataType, ParamsReadContext ctx)
518 {
519 if (userDataType == INPUT_UDT_GESTURE)
520 {
521 int forced = EmoteLauncher.FORCE_NONE;
522 int gestureID = -1;
523 int cancelID = 0;
524 int random = -1;
525 bool guaranteed = false;
526
527 if (!ctx.Read(gestureID))
528 {
529 cancelID = CALLBACK_CMD_INSTACANCEL; //fallback solution in case of severe data corruption
530 }
531 else
532 {
533 ctx.Read(forced);
534 ctx.Read(guaranteed);
535 if (ctx.Read(random))
536 m_RPSOutcome = random;
537 //server-side check, sends CALLBACK_CMD_INSTACANCEL as a fail
538 bool canPlay = CanPlayEmote(gestureID);
539 if (!canPlay && (forced == EmoteLauncher.FORCE_NONE || !m_Player.GetCommand_Move())) //HOTFIX for swim and such
540 {
541 gestureID = CALLBACK_CMD_INVALID;
542 cancelID = CALLBACK_CMD_INSTACANCEL;
543 }
544 }
545
547 pCtx.Write(gestureID);
548 pCtx.Write(cancelID);
549 pCtx.Write(forced);
550 pCtx.Write(guaranteed);
552 SetPending(true);
553
554 return true;
555 }
556 return false;
557 }
558
559 //server and client
560 void OnSyncJuncture(int pJunctureID, ParamsReadContext pCtx)
561 {
562 int gestureID;
563 int cancelID;
564 int forced;
565 bool guaranteed;
566
567 if (!m_CancelEmote)
568 {
569 pCtx.Read(gestureID);
570 pCtx.Read(cancelID);
571 pCtx.Read(forced);
572 pCtx.Read(guaranteed);
573
574 if (gestureID != 0)
575 {
576 // Check if player's state has changed since request was sent
577
578 if (m_Player.IsSwimming() || m_Player.GetCommand_Swim())
579 {
580 // Player is now in water - reject the emote
581 gestureID = CALLBACK_CMD_INVALID;
582 cancelID = CALLBACK_CMD_INSTACANCEL;
586 // Notify server about it
587 if (g_Game.IsClient())
588 {
589 SendEmoteRequestSync(CALLBACK_CMD_INSTACANCEL); // Tell server we're cancelling
590 }
591 return;
592 }
593 }
594
595 EmoteBase emoteData;
596 if ((m_Callback || m_Player.IsSurrendered()) && (forced == EmoteLauncher.FORCE_ALL || (forced == EmoteLauncher.FORCE_DIFFERENT && m_CurrentGestureID != gestureID)))
597 {
598 if (m_Callback)
599 {
600 if (m_NameEmoteMap.Find(m_CurrentGestureID,emoteData) && emoteData.CanBeCanceledNormally(m_Callback))
601 m_CancelEmote = true;
602 else
603 return;
604 }
605 m_CancelEmote = true;
606 }
607
608 if (cancelID == CALLBACK_CMD_INSTACANCEL)
609 {
610 if (m_Callback)
611 {
612 if (m_NameEmoteMap.Find(m_CurrentGestureID,emoteData) && !emoteData.CanBeCanceledNormally(m_Callback))
613 {
614 m_InstantCancelEmote = false;
615 return;
616 }
617 }
619 }
620
621 if (guaranteed)
622 m_DeferredGuaranteedEmoteId = gestureID;
623 m_DeferredEmoteExecution = gestureID;
624 }
625 else
626 m_CancelEmote = false;
627 }
628
630 {
631 EmoteBase emoteData;
632 if (m_NameEmoteMap.Find(m_CurrentGestureID,emoteData))
633 emoteData.OnCallbackEnd();
634 }
635
637 {
638 }
639
640 bool PlayEmote(int id)
641 {
646 SetPending(false);
647
648 if (CanPlayEmote(id))
649 {
650 EmoteBase emote;
651 m_NameEmoteMap.Find(id,emote);
652
653 if (m_AdminLog)
654 m_AdminLog.OnEmote(m_Player, emote);
655
658 if (id > 0)
659 {
660 if (emote)
661 {
662 int callback_ID;
663 int stancemask;
664 bool is_fullbody;
665 if (DetermineEmoteData(emote,callback_ID,stancemask,is_fullbody))
666 {
667 if (!emote.EmoteStartOverride(EmoteCB,callback_ID,stancemask,is_fullbody))
668 {
669 emote.OnBeforeStandardCallbackCreated(callback_ID,stancemask,is_fullbody);
670 CreateEmoteCallback(EmoteCB,callback_ID,stancemask,is_fullbody);
671 }
672
673 if (emote.GetHideItemInHands())
674 {
676 }
677 }
678 else
679 {
680 ErrorEx("EmoteManager | DetermineEmoteData failed!");
681 }
682 }
683 }
684 }
685
687 return m_bEmoteIsPlaying;
688 }
689
690 //creates Emote callback
691 protected void CreateEmoteCallback(typename callbacktype, int id, int mask, bool fullbody)
692 {
693 if (m_Player)
694 {
695 m_LastMask = -1;
696
697 if (fullbody)
698 {
699 Class.CastTo(m_Callback, m_Player.StartCommand_Action(id,callbacktype,mask));
700 m_Callback.m_IsFullbody = true;
701 m_Callback.EnableCancelCondition(true);
702 }
703 else if (m_Player.IsPlayerInStance(mask))
704 {
705 m_LastMask = mask; //character is probably not prone now
706 Class.CastTo(m_Callback, m_Player.AddCommandModifier_Action(id,callbacktype));
707 }
708
709 if (m_Callback)
710 {
711 m_bEmoteIsPlaying = true;
712 m_Callback.m_callbackID = id;
713 m_Callback.m_player = m_Player;
714 m_Callback.m_Manager = this;
715 }
716 }
717 }
718
719 protected void HideItemInHands()
720 {
721 m_item = m_Player.GetItemInHands();
722 if (m_Callback && m_item)
723 {
724 m_Player.TryHideItemInHands(true);
725 }
726 }
727
728 protected void ShowItemInHands()
729 {
730 if (m_item)
731 {
732 m_Player.TryHideItemInHands(false);
733 }
734 }
735
737 {
738 if (!g_Game.IsClient())
740 }
741
742 protected void CommitSuicide()
743 {
744 Weapon_Base weapon;
745 WeaponEventBase weapon_event = new WeaponEventTrigger;
746
747 if (Weapon_Base.CastTo(weapon,m_Player.GetItemInHands()))
748 {
749 if (weapon.CanFire())
750 {
751 m_Callback.RegisterAnimationEvent("Simulation_End",EmoteConstants.EMOTE_SUICIDE_SIMULATION_END);
752 m_Player.SetSuicide(true);
753 weapon.ProcessWeaponEvent(weapon_event);
754 m_Callback.InternalCommand(DayZPlayerConstants.CMD_ACTIONINT_FINISH);
755 if (m_Player.IsAlive())
756 {
757 EntityAI helm = m_Player.FindAttachmentBySlotName("Headgear");
758 if (helm && g_Game.IsServer())
759 {
760 float damage = helm.GetMaxHealth("","");
761 helm.AddHealth("","", -damage/2);
762 }
763 g_Game.GetCallQueue(CALL_CATEGORY_GAMEPLAY).Call(this.KillPlayer);
764 if (m_AdminLog)
765 {
766 m_AdminLog.Suicide(m_Player);
767 }
768 }
769 }
770 else
771 {
772 if (!weapon.IsDamageDestroyed())
773 {
774 weapon.ProcessWeaponEvent(weapon_event);
775 }
776 m_Callback.InternalCommand(DayZPlayerConstants.CMD_ACTIONINT_END);
777 }
778 }
779 else if (m_Player.GetItemInHands() && m_Player.GetItemInHands().ConfigIsExisting("suicideAnim"))
780 {
781 m_Callback.RegisterAnimationEvent("Death",EmoteConstants.EMOTE_SUICIDE_DEATH);
782 m_Callback.RegisterAnimationEvent("Bleed",EmoteConstants.EMOTE_SUICIDE_BLEED);
783 m_Callback.RegisterAnimationEvent("Simulation_End",EmoteConstants.EMOTE_SUICIDE_SIMULATION_END);
784 m_Callback.InternalCommand(DayZPlayerConstants.CMD_ACTIONINT_FINISH);
785 m_Player.SetSuicide(true);
786 }
787 else
788 {
789 m_Callback.InternalCommand(DayZPlayerConstants.CMD_ACTIONINT_FINISH);
790 }
791 }
792
794 {
795 if (g_Game.IsServer())
796 {
797 m_Player.SetHealth(0);
798 }
799 }
800
802 {
803 if (g_Game.IsServer())
804 {
805 PlayerIdentity identity = m_Player.GetIdentity();
806 if (identity)
807 {
808 if (m_AdminLog)
809 m_AdminLog.Suicide(m_Player);
810 }
811 }
812 }
813
814 void CreateEmoteCBFromMenu(int id, bool interrupts_same = false)
815 {
816 if (ClearEmoteLauncher())
817 m_MenuEmote = new EmoteLauncher(id,interrupts_same);
818 }
819
820 protected bool ClearEmoteLauncher(bool forced = false)
821 {
822 if (!forced && m_MenuEmote && m_MenuEmote.IsStartGuaranteed())
823 return false;
824
825 m_MenuEmote = null;
826 return true;
827 }
828
829 protected bool ClearDeferredExecution()
830 {
832 return true;
833 }
834
836 {
837 return m_MenuEmote;
838 }
839
841 {
842 m_Callback.InternalCommand(DayZPlayerConstants.CMD_ACTIONINT_INTERRUPT);
843
846 }
847
849 {
851 {
852 m_Callback.InternalCommand(DayZPlayerConstants.CMD_ACTIONINT_INTERRUPT);
853 }
854 else
855 {
856 m_Callback.InternalCommand(DayZPlayerConstants.CMD_ACTIONINT_END);
857 }
858
861 }
862
863 //sends request (client)
865 {
866 int forced = EmoteLauncher.FORCE_NONE;
867 bool guaranteedLaunch = false;
868
869 m_RPSOutcome = -1;
870 switch (id)
871 {
874 break;
875
877 m_RPSOutcome = 0;
878 break;
879
881 m_RPSOutcome = 1;
882 break;
883
885 m_RPSOutcome = 2;
886 break;
887 }
888
890 if (g_Game.IsMultiplayer() && g_Game.IsClient())
891 {
892 bool canProceed = true; //running callbacks in certain state can block additional actions
894 if (m_Callback && emoteData)
895 {
896 canProceed = emoteData.CanBeCanceledNormally(m_Callback);
897 }
898
899 if (ctx.CanStoreInputUserData() && ((CanPlayEmote(id) && CanPlayEmoteClientCheck(id)) || forced) && canProceed)
900 {
902 ctx.Write(id);
903 ctx.Write(forced);
904 ctx.Write(guaranteedLaunch);
905 if (m_RPSOutcome != -1)
906 {
907 ctx.Write(m_RPSOutcome);
908 }
909 ctx.Send();
910 SetPending(true);
911 }
912 else
913 {
914 SetPending(false);
915 }
916
918 }
919 else if (!g_Game.IsMultiplayer())
920 {
921 if (id == CALLBACK_CMD_END)
922 {
924 }
925 else if (id == CALLBACK_CMD_GESTURE_INTERRUPT)
926 {
928 }
929 else if (CanPlayEmote(id) && CanPlayEmoteClientCheck(id))
930 {
931 PlayEmote(id);
932 }
933 else
934 {
936 }
937 }
938 }
939
941 protected void SendEmoteRequestSyncEx(notnull EmoteLauncher launcher)
942 {
943 int id = launcher.GetID();
944 int forced = launcher.GetForced();
945 bool guaranteedLaunch = launcher.IsStartGuaranteed();
946
947 m_RPSOutcome = -1;
948 switch (id)
949 {
952 break;
953
955 m_RPSOutcome = 0;
956 break;
957
959 m_RPSOutcome = 1;
960 break;
961
963 m_RPSOutcome = 2;
964 break;
965 }
966
968 if (g_Game.IsMultiplayer() && g_Game.IsClient())
969 {
970 bool canProceed = true; //running callbacks in certain state can block additional actions
972 if (m_Callback && emoteData)
973 {
974 canProceed = emoteData.CanBeCanceledNormally(m_Callback);
975 }
976
977 if (ctx.CanStoreInputUserData() && ((CanPlayEmote(id) && CanPlayEmoteClientCheck(id)) || forced) && canProceed)
978 {
980 ctx.Write(id);
981 ctx.Write(forced);
982 ctx.Write(guaranteedLaunch);
983 if (m_RPSOutcome != -1)
984 {
985 ctx.Write(m_RPSOutcome);
986 }
987 ctx.Send();
988 launcher.VerifySyncRequest();
989 SetPending(true);
990 }
991 else
992 {
993 SetPending(false);
994 }
995
996 if (launcher == m_MenuEmote)
999 }
1000 else if (!g_Game.IsMultiplayer())
1001 {
1002 if (id == CALLBACK_CMD_END)
1003 {
1005 }
1006 else if (id == CALLBACK_CMD_GESTURE_INTERRUPT)
1007 {
1009 }
1010 else if (CanPlayEmote(id) && CanPlayEmoteClientCheck(id))
1011 {
1012 PlayEmote(id);
1013 }
1014
1015 if (launcher == m_MenuEmote)
1018 }
1019 }
1020
1022 {
1023 return m_controllsLocked;
1024 }
1025
1026 bool CanPlayEmote(int id)
1027 {
1028 //special cases
1030 {
1031 return true;
1032 }
1033
1034 if (!m_Player || !m_Player.IsAlive() || (!IsEmotePlaying() && (m_Player.GetCommand_Action() || m_Player.GetCommandModifier_Action())) || m_Player.GetThrowing().IsThrowingModeEnabled())
1035 {
1036 return false;
1037 }
1038
1039 ItemBase item = m_Player.GetItemInHands();
1040 if (item)
1041 {
1042 if (item.IsHeavyBehaviour() && id != EmoteConstants.ID_EMOTE_SURRENDER)
1043 {
1044 return false;
1045 }
1046 }
1047
1048 if ((m_Player.GetWeaponManager() && m_Player.GetWeaponManager().IsRunning()) || (m_Player.GetActionManager() && m_Player.GetActionManager().GetRunningAction()))
1049 {
1050 return false;
1051 }
1052
1053 if (m_HIC.IsWeaponRaised() || m_Player.IsRolling() || m_Player.IsClimbing() || m_Player.IsRestrainStarted() || m_Player.IsFighting() || m_Player.IsSwimming() || m_Player.IsClimbingLadder() || m_Player.IsFalling() || m_Player.IsUnconscious() || m_Player.IsJumpInProgress() || m_Player.IsRestrained()) // rework conditions into something better?
1054 {
1055 return false;
1056 }
1057
1058 if (m_Player.GetCommand_Vehicle() || m_Player.GetCommand_Swim())
1059 {
1060 return false;
1061 }
1062
1063 HumanCommandMove cm = m_Player.GetCommand_Move();
1064 if (cm)
1065 {
1066 if (cm.IsOnBack() && id != EmoteConstants.ID_EMOTE_SURRENDER)
1067 return false;
1068 if (cm.IsChangingStance())
1069 return false;
1070 }
1071
1072 //"locks" player in surrender state
1073 if (m_Player.IsSurrendered() && (id != EmoteConstants.ID_EMOTE_SURRENDER))
1074 {
1075 return false;
1076 }
1077
1078 if (m_Player.GetDayZPlayerInventory().IsProcessing())
1079 {
1080 return false;
1081 }
1082
1083 EmoteBase emote;
1084 if (m_NameEmoteMap.Find(id,emote))
1085 {
1086 int callback_ID;
1087 int stancemask;
1088 bool is_fullbody;
1089 if (DetermineEmoteData(emote,callback_ID,stancemask,is_fullbody) && emote.EmoteCondition(stancemask))
1090 {
1091 return true;
1092 }
1093 }
1094
1095 return false;
1096 }
1097
1099 {
1100 if (!g_Game.IsClient())
1101 return true;
1102
1103 if (g_Game.GetUIManager().FindMenu(MENU_INVENTORY))
1104 {
1105 return false;
1106 }
1107
1108 return true;
1109 }
1110
1111 // is player able to perform the animation at the moment
1112 /*bool CanPerformEmoteAnimation(int id)
1113 {
1114
1115 }*/
1116
1117 void PlaySurrenderInOut(bool state)
1118 {
1121
1122 if (state)
1123 {
1124 ItemBase item = m_Player.GetItemInHands();
1125 if (item)
1126 {
1127 if (!m_Player.CanDropEntity(item))
1128 return;
1129
1130 if (m_Player.GetInventory().HasInventoryReservation(null, m_HandInventoryLocation))
1131 m_Player.GetInventory().ClearInventoryReservationEx(null, m_HandInventoryLocation);
1132
1133 if (g_Game.IsMultiplayer())
1134 {
1135 if (g_Game.IsServer())
1136 m_Player.ServerDropEntity(item);
1137 }
1138 else
1139 {
1140 m_Player.PhysicalPredictiveDropItem(item); //SP only
1141 }
1142 }
1143
1144 CreateEmoteCallback(EmoteCB,DayZPlayerConstants.CMD_GESTUREFB_SURRENDERIN,DayZPlayerConstants.STANCEMASK_ALL,true);
1145
1146 if (m_Callback)
1147 {
1148 m_Callback.RegisterAnimationEvent("ActionExec", UA_ANIM_EVENT);
1149 }
1150 }
1151 else
1152 {
1153 if (m_Player.IsAlive() && !m_Player.IsUnconscious())
1154 {
1155 CreateEmoteCallback(EmoteCB,DayZPlayerConstants.CMD_GESTUREFB_SURRENDEROUT,DayZPlayerConstants.STANCEMASK_ALL,true);
1156 }
1157 else
1158 {
1159 OnEmoteEnd();
1160 }
1161 }
1162 }
1163
1165 void SetEmoteLockState(bool state)
1166 {
1167 //separate inventory access locking
1168 if (state != m_InventoryAccessLocked)
1169 {
1170 m_Player.SetInventorySoftLock(state);
1172 }
1173
1174 if (g_Game.IsClient() && m_InventoryAccessLocked && g_Game.GetUIManager().FindMenu(MENU_INVENTORY))
1175 m_Player.CloseInventoryMenu();
1176
1177 //Movement lock in fullbody anims
1178 if (state && m_Callback && m_Callback.m_IsFullbody)
1179 m_controllsLocked = true;
1180 else
1181 m_controllsLocked = false;
1182
1183 if (state == m_EmoteLockState)
1184 return;
1185
1187 {
1189 m_HandInventoryLocation.SetHands(m_Player,null);
1190 }
1191
1192 if (!state)
1193 {
1194 if (m_Player.GetInventory().HasInventoryReservation(null, m_HandInventoryLocation))
1195 m_Player.GetInventory().ClearInventoryReservationEx(null, m_HandInventoryLocation);
1196
1197 if (m_Player.GetActionManager())
1198 m_Player.GetActionManager().EnableActions(true);
1199 }
1200 else
1201 {
1202 if (!m_Player.GetInventory().HasInventoryReservation(null, m_HandInventoryLocation))
1203 m_Player.GetInventory().AddInventoryReservationEx(null, m_HandInventoryLocation, GameInventory.c_InventoryReservationTimeoutMS);
1204
1205 if (m_Player.GetActionManager())
1206 m_Player.GetActionManager().EnableActions(false);
1207 }
1208 m_EmoteLockState = state;
1209 }
1210
1211 [Obsolete("1.30: no replacement")]
1213 {
1214 if (!m_Player.GetItemInHands() || (m_Player.GetItemInHands() && !SurrenderDummyItem.Cast(m_Player.GetItemInHands())))
1215 return;
1216
1217 //refreshes reservation in case of unwanted timeout
1219 {
1220 m_Player.GetInventory().ExtendInventoryReservationEx(null, m_HandInventoryLocation, 10000);
1221 }
1222 }
1223
1226 {
1227 if (m_Player.IsSurrendered() && data)
1228 {
1230 data.End();
1231 }
1232 }
1233
1234 void SetClientLoggingOut(bool state)
1235 {
1237
1238 if (!state)
1239 {
1240 if (m_MenuEmote)
1242 }
1243 }
1244
1247 {
1248 if (m_Player.IsSurrendered())
1249 {
1250 m_Player.SetSurrenderState(false);
1251 SetEmoteLockState(false);
1252 }
1253 }
1254
1255 [Obsolete("1.30: Use PlayerBase::SetSurrenderState instead")]
1256 void ForceSurrenderState(bool state)
1257 {
1258 m_Player.SetSurrenderState(state);
1260 }
1261
1264 {
1265 if ((g_Game.IsMultiplayer() && g_Game.IsServer()) || !g_Game.IsMultiplayer())
1266 {
1270 m_Player.SendSyncJuncture(DayZPlayerSyncJunctures.SJ_GESTURE_REQUEST, pCtx);
1271 }
1272 }
1273
1274 //sent from server to cancel generic emote callback
1282
1284 {
1285 //init pass
1287 {
1290
1291 for (int i = 0; i < m_InterruptInputsCount; i++)
1292 {
1293 m_InterruptInputDirect.Insert(GetUApi().GetInputByName(m_InterruptInputs[i]).GetPersistentWrapper());
1294 }
1295 }
1296
1297 //interrupts any callback if restrain action is in progress, takes priority
1298 if (!m_Callback.m_IsFullbody)
1299 return false;
1300
1301 for (int idx = 0; idx < m_InterruptInputsCount; idx++)
1302 {
1303 if (m_InterruptInputDirect[idx].InputP().LocalPress())
1304 {
1305 return true;
1306 }
1307 }
1308
1309 return false;
1310 }
1311
1313 {
1314 float waterLevel = m_Player.GetCurrentWaterLevel();
1315
1316 if (m_Player.IsPlayerInStance(DayZPlayerConstants.STANCEMASK_PRONE | DayZPlayerConstants.STANCEMASK_RAISEDPRONE) && waterLevel >= m_HumanSwimSettings.m_fToCrouchLevel)
1317 {
1318 return true;
1319 }
1320 else if (m_Player.IsPlayerInStance(DayZPlayerConstants.STANCEMASK_CROUCH | DayZPlayerConstants.STANCEMASK_RAISEDCROUCH) && waterLevel >= m_HumanSwimSettings.m_fToErectLevel)
1321 {
1322 return true;
1323 }
1324
1325 return m_Player.GetModifiersManager() && m_Player.GetModifiersManager().IsModifierActive(eModifiers.MDF_DROWNING);
1326 }
1327
1329 {
1330 return m_bEmoteIsPlaying || m_Player.IsSurrendered() || m_bEmoteIsRequestPending;
1331 }
1332
1337
1338 void CreateBleedingEffect(int Callback_ID)
1339 {
1340 if (g_Game.IsServer() && m_Player.IsAlive())
1341 {
1342 switch (Callback_ID)
1343 {
1344 case DayZPlayerConstants.CMD_SUICIDEFB_1HD :
1345 m_Player.GetBleedingManagerServer().AttemptAddBleedingSourceBySelection("Neck");
1346 break;
1347
1348 case DayZPlayerConstants.CMD_SUICIDEFB_FIREAXE :
1349 m_Player.GetBleedingManagerServer().AttemptAddBleedingSourceBySelection("LeftForeArmRoll");
1350 break;
1351
1352 case DayZPlayerConstants.CMD_SUICIDEFB_PITCHFORK :
1353 m_Player.GetBleedingManagerServer().AttemptAddBleedingSourceBySelection("Spine2");
1354 break;
1355
1356 case DayZPlayerConstants.CMD_SUICIDEFB_SWORD :
1357 m_Player.GetBleedingManagerServer().AttemptAddBleedingSourceBySelection("Spine2");
1358 break;
1359
1360 case DayZPlayerConstants.CMD_SUICIDEFB_SPEAR :
1361 m_Player.GetBleedingManagerServer().AttemptAddBleedingSourceBySelection("Head");
1362 break;
1363
1364 case DayZPlayerConstants.CMD_SUICIDEFB_WOODAXE :
1365 m_Player.GetBleedingManagerServer().AttemptAddBleedingSourceBySelection("LeftForeArmRoll");
1366 break;
1367
1368 default :
1369 ErrorEx("EmoteManager.c | CreateBleedingEffect | WRONG ID",ErrorExSeverity.INFO);
1370 break;
1371 }
1372 }
1373 }
1374
1377 protected void PickEmote(int gestureslot)
1378 {
1379 }
1380
1384};
1385
1387{
1389 void End();
1390}
1391
1392/**@class ChainedDropAndKillPlayerLambda
1393 * @brief drops weapon in hands to ground and then calls kill
1394 **/
1396{
1398
1399 void ChainedDropAndKillPlayerLambda (EntityAI old_item, string new_item_type, PlayerBase player)
1400 {
1401 m_Player = player;
1403 vector mtx[4];
1404 old_item.GetTransform(mtx);
1405 gnd.SetGround(old_item, mtx);
1406
1407 OverrideNewLocation(gnd);
1408 }
1409
1410 override void Execute (HumanInventoryWithFSM fsm_to_notify = null)
1411 {
1412 if (PrepareLocations())
1413 {
1414 vector transform[4];
1415
1416 m_Player.GetInventory().TakeToDst(InventoryMode.SERVER, m_OldLocation, m_NewLocation);
1417 m_Player.OnItemInHandsChanged();
1418 }
1419
1420 m_Player.SetHealth(0);
1421
1422 if (LogManager.IsInventoryHFSMLogEnable()) hndDebugPrint("[syncinv] player=" + Object.GetDebugName(m_Player) + " STS = " + m_Player.GetSimulationTimeStamp() + " ChainedDropAndKillPlayerLambda");
1423 }
1424}
InventoryMode
NOTE: PREDICTIVE is not to be used at all in multiplayer.
const int INPUT_UDT_GESTURE
DayZGame g_Game
Определения DayZGame.c:4074
void DayZPlayerUtils()
cannot be instantiated
Определения DayZPlayerUtils.c:465
override void OnCallbackEnd()
Определения EmoteClasses.c:859
void ChainedDropAndKillPlayerLambda(EntityAI old_item, string new_item_type, PlayerBase player)
Определения EmoteManager.c:1399
bool m_ItemToHands
Определения EmoteManager.c:133
bool m_DisconnectEmoteQueued
Определения EmoteManager.c:131
EmoteCB m_Callback
Определения EmoteManager.c:120
ref Timer m_ReservationTimer
Определения EmoteManager.c:1383
ref array< int > m_EmoteInputIDs
Определения EmoteManager.c:157
bool ClearDeferredExecution()
Определения EmoteManager.c:829
const int CALLBACK_CMD_END
Определения EmoteManager.c:149
void ForceSurrenderState(bool state)
Определения EmoteManager.c:1256
void RequestCommitSuicide()
Определения EmoteManager.c:736
int m_InterruptInputsCount
Определения EmoteManager.c:147
void HideItemInHands()
Определения EmoteManager.c:719
void CheckEmoteLockedState()
Определения EmoteManager.c:1212
bool m_controllsLocked
Определения EmoteManager.c:137
void EmoteManager(PlayerBase player)
Определения EmoteManager.c:160
int m_RPSOutcome
Определения EmoteManager.c:146
void CreateEmoteCBFromMenu(int id, bool interrupts_same=false)
Определения EmoteManager.c:814
void AfterStoreLoad()
Определения EmoteManager.c:636
const int CALLBACK_CMD_INVALID
Определения EmoteManager.c:148
int m_CurrentGestureID
Определения EmoteManager.c:144
ref array< string > m_InterruptInputs
Определения EmoteManager.c:122
bool m_CancelEmote
Определения EmoteManager.c:128
bool CanPlayEmoteClientCheck(int id)
Определения EmoteManager.c:1098
ref array< int > m_EmoteIDs
Определения EmoteManager.c:156
bool CanPlayEmote(int id)
Определения EmoteManager.c:1026
int m_DeferredEmoteExecution
Определения EmoteManager.c:141
bool IsControllsLocked()
Определения EmoteManager.c:1021
bool m_DeferredEmoteLauncherCleanup
Определения EmoteManager.c:132
void ShowItemInHands()
Определения EmoteManager.c:728
int m_DeferredGuaranteedEmoteId
Определения EmoteManager.c:140
ItemBase m_item
Определения EmoteManager.c:119
PluginAdminLog m_AdminLog
Определения EmoteManager.c:152
ref InventoryLocation m_HandInventoryLocation
Определения EmoteManager.c:124
void InterruptCallbackCommand()
Определения EmoteManager.c:840
void SetPending(bool state)
Определения EmoteManager.c:280
void ConstructData()
Определения EmoteManager.c:202
void PostSurrenderRequestServer()
server only
Определения EmoteManager.c:1263
int m_LastMask
Определения EmoteManager.c:145
void PlaySurrenderInOut(bool state)
Определения EmoteManager.c:1117
int DetermineGestureIndex()
Определения EmoteManager.c:241
void CreateBleedingEffect(int Callback_ID)
Определения EmoteManager.c:1338
void SendEmoteRequestSyncEx(notnull EmoteLauncher launcher)
To avoid mixing m_MenuEmote with exceptional sync commands.
Определения EmoteManager.c:941
void SetGesture(int id)
Определения EmoteManager.c:231
map< int, ref EmoteBase > GetNameEmoteMap()
Определения EmoteManager.c:1333
void CommitSuicide()
Определения EmoteManager.c:742
bool m_GestureInterruptInput
Определения EmoteManager.c:130
void ClearSurrenderState()
Surrender state cleared.
Определения EmoteManager.c:1246
bool m_InventoryAccessLocked
Определения EmoteManager.c:138
bool OnInputUserDataProcess(int userDataType, ParamsReadContext ctx)
Определения EmoteManager.c:517
const int CALLBACK_CMD_INSTACANCEL
Определения EmoteManager.c:151
void SetClientLoggingOut(bool state)
Определения EmoteManager.c:1234
void KillPlayer()
Определения EmoteManager.c:793
void OnEmoteEnd()
Определения EmoteManager.c:491
void ServerRequestEmoteCancel()
Определения EmoteManager.c:1275
void ~EmoteManager()
Определения EmoteManager.c:198
void EndSurrenderRequest(SurrenderData data=null)
directly force-ends surrender state AND requests hard cancel
Определения EmoteManager.c:1225
void SetEmoteLockState(bool state)
Определения EmoteManager.c:1165
bool ClearEmoteLauncher(bool forced=false)
Определения EmoteManager.c:820
ref EmoteLauncher m_MenuEmote
Определения EmoteManager.c:125
void CreateEmoteCallback(typename callbacktype, int id, int mask, bool fullbody)
Определения EmoteManager.c:691
bool InterruptGestureCheck()
Определения EmoteManager.c:1283
bool m_PlayerDies
Определения EmoteManager.c:136
bool InterruptWaterCheck()
Определения EmoteManager.c:1312
void OnSyncJuncture(int pJunctureID, ParamsReadContext pCtx)
Определения EmoteManager.c:560
int m_GestureID
Определения EmoteManager.c:142
void PickEmote(int gestureslot)
Deprecated.
Определения EmoteManager.c:1377
bool IsEmotePlaying()
Определения EmoteManager.c:1328
bool DetermineEmoteData(EmoteBase emote, out int callback_ID, out int stancemask, out bool is_fullbody)
Also includes a stance check for FB callbacks.
Определения EmoteManager.c:256
bool m_EmoteLockState
Определения EmoteManager.c:139
SHumanCommandSwimSettings m_HumanSwimSettings
Определения EmoteManager.c:158
override void Execute(HumanInventoryWithFSM fsm_to_notify=null)
Определения EmoteManager.c:1410
bool m_ItemToBeCreated
Определения EmoteManager.c:1382
bool m_IsSurrendered
Определения EmoteManager.c:1381
const int CALLBACK_CMD_GESTURE_INTERRUPT
Определения EmoteManager.c:150
ref map< int, ref EmoteBase > m_NameEmoteMap
Определения EmoteManager.c:154
HumanInputController m_HIC
Определения EmoteManager.c:121
ref array< ref EmoteBase > m_EmoteClassArray
Определения EmoteManager.c:155
void EndCallbackCommand()
Определения EmoteManager.c:848
bool m_bEmoteIsPlaying
Определения EmoteManager.c:127
void LogSuicide()
Определения EmoteManager.c:801
bool m_MouseButtonPressed
Определения EmoteManager.c:135
bool m_InstantCancelEmote
Определения EmoteManager.c:129
EmoteLauncher GetEmoteLauncher()
Определения EmoteManager.c:835
bool m_bEmoteIsRequestPending
Определения EmoteManager.c:126
bool m_ItemIsOn
Определения EmoteManager.c:134
void SendEmoteRequestSync(int id)
Определения EmoteManager.c:864
int m_PreviousGestureID
Определения EmoteManager.c:143
int GetGesture()
Определения EmoteManager.c:236
bool PlayEmote(int id)
Определения EmoteManager.c:640
ref array< UAIDWrapper > m_InterruptInputDirect
Определения EmoteManager.c:123
DayZPlayer m_Player
Определения Hand_Events.c:42
void hndDebugPrint(string s)
Определения HandFSM.c:1
PluginBase GetPlugin(typename plugin_type)
Определения PluginManager.c:326
proto native UAInputAPI GetUApi()
drops weapon in hands to ground and then calls kill
Определения EmoteManager.c:1387
Super root of all classes in Enforce script.
Определения EnScript.c:11
static const int SJ_GESTURE_REQUEST
Определения DayZPlayerSyncJunctures.c:22
void OnCallbackEnd()
bool EmoteFBStanceCheck(int stancemask)
Checks for valid stance mask.
Определения EmoteBase.c:23
bool CanBeCanceledNormally(notnull EmoteCB callback)
Определения EmoteBase.c:17
bool DetermineOverride(out int callback_ID, out int stancemask, out bool is_fullbody)
Определения EmoteBase.c:39
int GetAdditiveCallbackUID()
Определения EmoteBase.c:85
int GetFullbodyCallbackUID()
Определения EmoteBase.c:90
int GetStanceMaskAdditive()
Определения EmoteBase.c:75
bool EmoteStartOverride(typename callbacktype, int id, int mask, bool fullbody)
Определения EmoteBase.c:47
int GetStanceMaskFullbody()
Определения EmoteBase.c:80
bool EmoteCondition(int stancemask)
Определения EmoteBase.c:12
void OnBeforeStandardCallbackCreated(int callback_ID, int stancemask, bool is_fullbody)
bool GetHideItemInHands()
Определения EmoteBase.c:95
Определения EmoteBase.c:2
bool IsEmoteCallback()
Определения EmoteManager.c:24
EmoteManager m_Manager
Определения EmoteManager.c:6
override void OnAnimationEvent(int pEventID)
Определения EmoteManager.c:29
void ~EmoteCB()
Определения EmoteManager.c:8
bool m_IsFullbody
Определения EmoteManager.c:3
PlayerBase m_player
Определения EmoteManager.c:5
bool CancelCondition()
Определения EmoteManager.c:19
override bool IsGestureCallback()
Определения EmoteManager.c:53
int m_callbackID
Определения EmoteManager.c:4
Определения EmoteManager.c:2
bool ConstructEmotes(PlayerBase player, out map< int, ref EmoteBase > emoteMap)
Определения EmoteConstructor.c:3
static const int FORCE_ALL
Определения EmoteManager.c:63
static const int FORCE_NONE
Определения EmoteManager.c:61
void VerifySyncRequest()
Определения EmoteManager.c:105
bool m_SyncRequestSent
Определения EmoteManager.c:67
void SetStartGuaranteed(bool guaranted)
Определения EmoteManager.c:95
int GetID()
Определения EmoteManager.c:90
bool IsStartGuaranteed()
Определения EmoteManager.c:100
void SetForced(int mode)
Определения EmoteManager.c:80
int m_ID
Определения EmoteManager.c:69
bool m_IsStartGuaranteed
Определения EmoteManager.c:66
bool m_InterruptsSameIDEmote
Определения EmoteManager.c:65
static const int FORCE_DIFFERENT
Определения EmoteManager.c:62
bool WasSynced()
Определения EmoteManager.c:110
int GetForced()
Определения EmoteManager.c:85
int m_ForcePlayEmote
Определения EmoteManager.c:68
void EmoteLauncher(int emoteID, bool interrupts_same)
Определения EmoteManager.c:71
Определения EmoteManager.c:60
const int c_InventoryReservationTimeoutMS
reservations
script counterpart to engine's class Inventory
proto native bool IsOnBack()
return true if prone is on back
proto native bool IsChangingStance()
returns true if character is changing stance
Определения human.c:454
Определения human.c:18
HumanInventory... with FSM (synchronous, no anims)
Определения HumanInventoryWithFSM.c:6
proto native void SetGround(EntityAI e, vector mat[4])
sets current inventory location type to Ground with transformation mat
InventoryLocation.
Определения InventoryLocation.c:30
static bool IsInventoryHFSMLogEnable()
Определения 3_Game/DayZ/tools/Debug.c:779
Определения EnMath.c:7
Определения ObjectTyped.c:2
Определения PlayerBaseClient.c:2
The class that will be instanced (moddable)
Определения gameplay.c:389
base class for transformation operations (creating one item from another)
Определения ReplaceItemWithNewLambdaBase.c:5
proto native void Send()
proto static native bool CanStoreInputUserData()
Returns true when the channel is free, AND the InputBuffer is NOT full (same as '!...
Определения gameplay.c:121
Определения gameplay.c:152
proto bool Write(void value_out)
proto bool Read(void value_in)
void End()
called on surrender end request end
Определения EmoteManager.c:1387
Определения DayZPlayerImplement.c:39
proto native UAInput GetInputByName(string sInputName)
proto native int ID()
Определения UAInput.c:34
shorthand
Определения BoltActionRifle_Base.c:6
signalize mechanism manipulation
Определения Events.c:35
Result for an object found in CGame.IsBoxCollidingGeometryProxy.
Определения Transport.c:70
Определения EnConvert.c:119
DayZPlayerConstants
defined in C++
Определения dayzplayer.c:602
eModifiers
Определения eModifiers.c:2
Serializer ParamsReadContext
Определения gameplay.c:15
const int EMOTE_SUICIDE_SIMULATION_END
Определения 3_Game/DayZ/constants.c:418
const int EMOTE_SUICIDE_BLEED
Определения 3_Game/DayZ/constants.c:417
const int EMOTE_SUICIDE_DEATH
Определения 3_Game/DayZ/constants.c:416
ErrorExSeverity
Определения EnDebug.c:62
enum ShapeType ErrorEx
const int ID_EMOTE_RPS_P
Определения 3_Game/DayZ/constants.c:402
const int ID_EMOTE_RPS
Определения 3_Game/DayZ/constants.c:391
const int ID_EMOTE_SURRENDER
Определения 3_Game/DayZ/constants.c:407
const int ID_EMOTE_SITA
Определения 3_Game/DayZ/constants.c:381
const int ID_EMOTE_THUMB
Определения 3_Game/DayZ/constants.c:376
const int ID_EMOTE_DANCE
Определения 3_Game/DayZ/constants.c:379
const int ID_EMOTE_RPS_S
Определения 3_Game/DayZ/constants.c:403
const int ID_EMOTE_SUICIDE
Определения 3_Game/DayZ/constants.c:378
const int ID_EMOTE_RPS_R
Определения 3_Game/DayZ/constants.c:401
const int ID_EMOTE_THUMBDOWN
Определения 3_Game/DayZ/constants.c:383
static proto bool CastTo(out Class to, Class from)
Try to safely down-cast base class to child class.
void Obsolete(string msg="")
Определения EnScript.c:371
static proto int RandomInt(int min, int max)
Returns a random int number between and min [inclusive] and max [exclusive].
const int MENU_GESTURES
Определения 3_Game/DayZ/constants.c:200
const int MENU_INVENTORY
Определения 3_Game/DayZ/constants.c:186
const int CALL_CATEGORY_GAMEPLAY
Определения 3_Game/DayZ/tools/tools.c:10
const int UA_ANIM_EVENT
Определения 3_Game/DayZ/constants.c:505
proto native volatile void Update()
Определения PlayerSoundManager.c:125