16 m_player.RequestHandAnimationStateRefresh();
44 if (
m_player.GetItemInHands() && SurrenderDummyItem.Cast(
m_player.GetItemInHands()))
67 itemInHands.GetTransform(m4);
213 for (
int i = 0; i < count; i++)
242 for (
int i = 0; i < count; ++i)
289 m_Player.GetHumanInventory().CreateInHands(
"SurrenderDummyItem");
331 bool uiGesture =
false;
332 if (!
GetGame().IsDedicatedServer())
502 if (ctx.
Read(gestureID))
505 if (ctx.
Read(random))
514 pCtx.
Write(gestureID);
532 pCtx.
Read(gesture_id);
577 if (
m_Player.GetItemInHands() && SurrenderDummyItem.Cast(
m_Player.GetItemInHands()))
587 m_Player.SetInventorySoftLock(
false);
619 Error(
"EmoteManager | DetermineEmoteData failed!");
626 m_Player.SetInventorySoftLock(
true);
651 else if (
m_Player.IsPlayerInStance(mask))
691 if (weapon.CanFire())
695 weapon.ProcessWeaponEvent(weapon_event);
700 if (helm &&
GetGame().IsServer())
702 float damage = helm.GetMaxHealth(
"",
"");
703 helm.AddHealth(
"",
"", -damage/2);
714 if (!weapon.IsDamageDestroyed())
716 weapon.ProcessWeaponEvent(weapon_event);
721 else if (
m_Player.GetItemInHands() &&
m_Player.GetItemInHands().ConfigIsExisting(
"suicideAnim"))
823 bool canProceed =
true;
843 m_Player.SetInventorySoftLock(
true);
848 else if (!
GetGame().IsMultiplayer())
906 if (
m_Player.GetCommand_Vehicle().GetTransport())
994 m_Player.GetActionManager().EnableActions(
true);
996 m_Player.SetInventorySoftLock(
false);
1011 m_Player.GetActionManager().EnableActions(
false);
1024 if (!
m_Player.GetItemInHands() || (
m_Player.GetItemInHands() && !SurrenderDummyItem.Cast(
m_Player.GetItemInHands())))
1041 m_Player.GetItemInHands().Delete();
1117 switch (Callback_ID)
1120 m_Player.GetBleedingManagerServer().AttemptAddBleedingSourceBySelection(
"Neck");
1124 m_Player.GetBleedingManagerServer().AttemptAddBleedingSourceBySelection(
"LeftForeArmRoll");
1128 m_Player.GetBleedingManagerServer().AttemptAddBleedingSourceBySelection(
"Spine2");
1132 m_Player.GetBleedingManagerServer().AttemptAddBleedingSourceBySelection(
"Spine2");
1136 m_Player.GetBleedingManagerServer().AttemptAddBleedingSourceBySelection(
"Head");
1140 m_Player.GetBleedingManagerServer().AttemptAddBleedingSourceBySelection(
"LeftForeArmRoll");
1175 old_item.GetTransform(mtx);
1178 OverrideNewLocation(gnd);
1183 if (PrepareLocations())
void actionDebugPrint(string s)
override void OnCallbackEnd()
protected const int CALLBACK_CMD_INSTACANCEL
ref array< UAInput > m_InterruptInputDirect
protected void CommitSuicide()
protected bool m_MouseButtonPressed
void CheckEmoteLockedState()
protected void CreateEmoteCallback(typename callbacktype, int id, int mask, bool fullbody)
void EmoteManager(PlayerBase player)
void CreateEmoteCBFromMenu(int id, bool interrupts_same=false)
protected int m_CurrentGestureID
ref array< string > m_InterruptInputs
bool CanPlayEmote(int id)
protected bool m_controllsLocked
PluginAdminLog m_AdminLog
protected ref array< ref EmoteBase > m_EmoteClassArray
ref InventoryLocation m_HandInventoryLocation
void InterruptCallbackCommand()
protected int m_PreviousGestureID
void PlaySurrenderInOut(bool state)
protected int m_DeferredEmoteExecution
int DetermineGestureIndex()
protected const int CALLBACK_CMD_GESTURE_INTERRUPT
void CreateBleedingEffect(int Callback_ID)
map< int, ref EmoteBase > GetNameEmoteMap()
bool m_GestureInterruptInput
bool OnInputUserDataProcess(int userDataType, ParamsReadContext ctx)
protected ref array< int > m_EmoteIDs
protected void PickEmote(int gestureslot)
Deprecated.
void ServerRequestEmoteCancel()
protected void ShowItemInHands()
void EndSurrenderRequest(SurrenderData data=null)
directly force-ends surrender state from outside of normal flow
void SetEmoteLockState(bool state)
protected int m_InterruptInputsCount
protected ref Timer m_ReservationTimer
ref EmoteLauncher m_MenuEmote
bool InterruptGestureCheck()
bool InterruptWaterCheck()
protected bool m_ItemIsOn
protected bool m_PlayerDies
protected int m_GestureID
void OnSyncJuncture(int pJunctureID, ParamsReadContext pCtx)
protected ref map< int, ref EmoteBase > m_NameEmoteMap
bool DetermineEmoteData(EmoteBase emote, out int callback_ID, out int stancemask, out bool is_fullbody)
Also includes a stance check for FB callbacks.
override void Execute(HumanInventoryWithFSM fsm_to_notify=null)
protected const int CALLBACK_CMD_END
protected bool m_EmoteLockState
HumanInputController m_HIC
void EndCallbackCommand()
bool m_InstantCancelEmote
EmoteLauncher GetEmoteLauncher()
protected bool m_ItemToHands
protected int m_RPSOutcome
protected ref array< int > m_EmoteInputIDs
void SendEmoteRequestSync(int id)
protected void HideItemInHands()
protected SHumanCommandSwimSettings m_HumanSwimSettings
protected const int CALLBACK_CMD_INVALID
void hndDebugPrint(string s)
PluginBase GetPlugin(typename plugin_type)
override ScriptCallQueue GetCallQueue(int call_category)
proto native UIManager GetUIManager()
drops weapon in hands to ground and then calls kill
Super root of all classes in Enforce script.
this is main camera class
override bool IsShootingFromCamera()
void OverrideShootFromCamera(bool pState)
DayZPlayerInventory GetDayZPlayerInventory()
WeaponManager GetWeaponManager()
void SetSuicide(bool state)
override void OnItemInHandsChanged()
override float GetCurrentWaterLevel()
DayZPlayerImplementThrowing GetThrowing()
bool IsThrowingModeEnabled()
static const int SJ_GESTURE_REQUEST
bool EmoteFBStanceCheck(int stancemask)
Checks for valid stance mask.
void OnBeforeStandardCallbackCreated(int callback_ID, int stancemask, bool is_fullbody)
int GetAdditiveCallbackUID()
int GetFullbodyCallbackUID()
bool EmoteStartOverride(typename callbacktype, int id, int mask, bool fullbody)
bool EmoteCondition(int stancemask)
bool CanBeCanceledNormally(notnull EmoteCB callback)
bool GetHideItemInHands()
bool DetermineOverride(out int callback_ID, out int stancemask, out bool is_fullbody)
int GetStanceMaskFullbody()
int GetStanceMaskAdditive()
override void OnAnimationEvent(int pEventID)
override bool IsGestureCallback()
bool ConstructEmotes(PlayerBase player, out map< int, ref EmoteBase > emoteMap)
static const int FORCE_NONE
protected bool m_InterruptsSameIDEmote
static const int FORCE_DIFFERENT
static const int FORCE_ALL
void EmoteLauncher(int emoteID, bool interrupts_same)
protected int m_ForcePlayEmote
script counterpart to engine's class Inventory
const int c_InventoryReservationTimeoutMS
reservations
HumanInventory... with FSM (synchronous, no anims)
proto native void SetGround(EntityAI e, vector mat[4])
sets current inventory location type to Ground with transformation mat
proto native void SetHands(notnull EntityAI parent, EntityAI e)
sets current inventory location type to Hands
proto owned string GetId()
unique id of player (hashed steamID, database Xbox id...) can be used in database or logs
proto owned string GetName()
nick (short) name of player
The class that will be instanced (moddable)
base class for transformation operations (creating one item from another)
float m_fToCrouchLevel
when to crouch
float m_fToErectLevel
when to stand
proto void Call(func fn, void param1=NULL, void param2=NULL, void param3=NULL, void param4=NULL, void param5=NULL, void param6=NULL, void param7=NULL, void param8=NULL, void param9=NULL)
adds call into the queue with given parameters and arguments (arguments are held in memory until the ...
Serialization general interface. Serializer API works with:
proto bool Write(void value_out)
proto bool Read(void value_in)
void End()
called on surrender end request end
bool IsMenuOpen(int id)
Returns true if menu with specific ID is opened (see MenuID)
signalize mechanism manipulation
Result for an object found in CGame.IsBoxCollidingGeometryProxy.
DayZPlayerConstants
defined in C++
proto native CGame GetGame()
const int EMOTE_SUICIDE_SIMULATION_END
const int EMOTE_SUICIDE_BLEED
const int EMOTE_SUICIDE_DEATH
void Error(string err)
Messagebox with error message.
const int ID_EMOTE_THUMBDOWN
const int ID_EMOTE_SURRENDER
const int ID_EMOTE_SUICIDE
static proto bool CastTo(out Class to, Class from)
Try to safely down-cast base class to child class.
static proto int RandomInt(int min, int max)
Returns a random int number between and min [inclusive] and max [exclusive].