112 g_Game.SetKeyboardHandle(
this);
122 layoutRoot =
GetGame().GetWorkspace().CreateWidgets(
"gui/layouts/dialog_queue_position.layout");
128 layoutRoot.FindAnyWidget(
"notification_root").Show(
false);
130#ifdef PLATFORM_CONSOLE
131 layoutRoot.FindAnyWidget(
"toolbar_bg").Show(
true);
135#ifdef BUILD_EXPERIMENTAL
136 layoutRoot.FindAnyWidget(
"notification_root").Show(
true);
158 layoutRoot.Show(
true);
164 layoutRoot.Show(
false);
207 g_Game.SetKeyboardHandle(
this);
222 layoutRoot =
GetGame().GetWorkspace().CreateWidgets(
"gui/layouts/dialog_login_time.layout");
224 m_txtDescription =
TextWidget.Cast(layoutRoot.FindAnyWidget(
"txtDescription"));
225 m_txtLabel =
TextWidget.Cast(layoutRoot.FindAnyWidget(
"txtLabel"));
227 m_txtDescription.Show(
true);
228 layoutRoot.FindAnyWidget(
"notification_root").Show(
false);
230#ifdef PLATFORM_CONSOLE
231 layoutRoot.FindAnyWidget(
"toolbar_bg").Show(
true);
235#ifdef BUILD_EXPERIMENTAL
236 layoutRoot.FindAnyWidget(
"notification_root").Show(
true);
259 layoutRoot.Show(
true);
267 layoutRoot.Show(
false);
276 text =
"#menu_loading_in_";
278 text =
"#dayz_game_spawning_in_";
280 if (m_FullTime.m_Days > 0)
282 else if (m_FullTime.m_Hours > 0)
284 else if (m_FullTime.m_Minutes > 0)
290 text =
string.Format(
text, m_FullTime.m_Seconds, m_FullTime.m_Minutes, m_FullTime.m_Hours, m_FullTime.m_Days);
291 m_txtLabel.SetText(
text);
293 if (m_IsRespawn &&
time <= 1)
294 GetGame().SetLoginTimerFinished();
299 m_txtDescription.SetText(
status);
342 m_WidgetRoot =
game.GetWorkspace().CreateWidgets(
"gui/layouts/day_z_connection_lost.layout");
353 if (
g_Game.GetUIManager().IsDialogVisible())
354 g_Game.GetUIManager().HideDialog();
681 m_WidgetRoot =
game.GetLoadingWorkspace().CreateWidgets(
"gui/layouts/loading.layout");
698 m_WidgetRoot.FindAnyWidget(
"notification_root").Show(
false);
700#ifdef PLATFORM_CONSOLE
702#ifdef BUILD_EXPERIMENTAL
718 game.GetBacklit().LoadingAnim();
803 if (
m_DayZGame.GetUIManager().IsDialogVisible())
806 if (
m_DayZGame.GetMissionState() == DayZGame.MISSION_STATE_MAINMENU)
853 const int MISSION_STATE_MAINMENU = 0;
854 const int MISSION_STATE_GAME = 1;
855 const int MISSION_STATE_FINNISH = 2;
866 protected bool m_FirstConnect =
true;
891 private bool m_IsWorldWetTempUpdateEnabled =
true;
892 private bool m_IsFoodDecayEnabled =
true;
904 private bool m_CursorDesiredVisibilityScript =
true;
937 private const int MIN_ARTY_SOUND_RANGE = 300;
951#ifdef PLATFORM_CONSOLE
956 m_keyboard_handler =
null;
959 m_early_access_dialog_accepted =
true;
971 m_dragQueue =
new DragQueue;
977 m_IsStressTest =
true;
980 m_AimLoggingEnabled =
true;
984 m_Backlit.OnInit(
this);
989 if (m_loading ==
null)
993 m_loading.ShowEx(
this);
1010 string path =
"cfgVehicles";
1022 m_IsConnecting =
false;
1023 m_ConnectFromJoin =
false;
1035 Print(
"~DayZGame()");
1044 GetInput().UpdateConnectedInputDeviceList();
1063 m_IsWorldWetTempUpdateEnabled = (
GetCEApi().GetCEGlobalInt(
"WorldWetTempUpdate") == 1);
1065 m_FoodDecayModifier =
GetCEApi().GetCEGlobalFloat(
"FoodDecay");
1068 if (m_FoodDecayModifier ==
float.
MIN)
1069 m_FoodDecayModifier =
GetCEApi().GetCEGlobalInt(
"FoodDecay");
1097 m_DayZProfileOptions.ResetOptionsBool();
1098 m_DayZProfileOptions.ResetOptionsInt();
1099 m_DayZProfileOptions.ResetOptionsFloat();
1105 m_MissionPath =
path;
1170 m_MissionState =
state;
1176 return m_DayZProfileOptions.GetProfileOption(
option);
1186 return m_DayZProfileOptions.GetProfileOptionInt(
option);
1191 return m_DayZProfileOptions.GetProfileOptionFloat(
option);
1196 return m_DayZProfileOptions.GetProfileOptionDefaultBool(
option);
1206 return m_DayZProfileOptions.GetProfileOptionDefaultInt(
option);
1211 return m_DayZProfileOptions.GetProfileOptionDefaultFloat(
option);
1216 m_DayZProfileOptions.SetProfileOptionBool(
option,
value);
1226 m_DayZProfileOptions.SetProfileOptionInt(
option,
value);
1231 m_DayZProfileOptions.SetProfileOptionFloat(
option,
value);
1236 return m_DayZProfileOptions.GetProfileOptionMap();
1251 m_GameState =
state;
1261 m_LoadState =
state;
1292 if (!m_early_access_dialog_accepted)
1295 m_early_access_dialog_accepted =
true;
1315 Print(
"Reloading mission module!");
1325 if (m_LoginQueue.IsStatic())
1327 m_LoginQueue.Hide();
1331 m_LoginQueue.Close();
1339 if (m_LoginTimeScreen)
1341 if (m_LoginTimeScreen.IsStatic())
1343 m_LoginTimeScreen.Hide();
1347 m_LoginTimeScreen.Close();
1354 m_ConnectivityStatsStates[
i] = 0;
1380 m_FirstConnect =
true;
1390 m_FirstConnect =
true;
1391#ifdef PLATFORM_CONSOLE
1399 m_Notifications.ClearVoiceNotifications();
1439#ifdef PLATFORM_CONSOLE
1440 m_Notifications.ClearVoiceNotifications();
1445 m_FirstConnect =
false;
1449#ifdef PLATFORM_CONSOLE
1450#ifndef PLATFORM_WINDOWS
1543 if (m_LoginTimeScreen)
1547 if (
msg2.Length() > 0)
1550 m_LoginTimeScreen.SetStatus(
finalMsg);
1570 if (m_ConnectFromJoin)
1572 m_ConnectFromJoin =
false;
1606#ifdef DIAG_DEVELOPER
1610 if (
fps >
GetWorld().GetServerFpsWarningThreshold())
1612 else if (
fps >
GetWorld().GetServerFpsCriticalThreshold())
1634 if (
level != m_ConnectivityStatsStates[type])
1637 m_ConnectivityStatsStates[type] =
level;
1653#ifdef DIAG_DEVELOPER
1668 DbgUI.
Text(
"Server Fps Warning Threshold:" +
GetWorld().GetServerFpsWarningThreshold());
1669 DbgUI.
Text(
"Server Fps Critical Threshold:" +
GetWorld().GetServerFpsCriticalThreshold());
1691 m_Notifications.RemoveVoiceNotification(
vonStopParams.param2);
1700 if (!m_LoginQueue && pos > 0)
1711 m_LoginQueue =
new LoginQueueStatic();
1717 m_LoginQueue.SetPosition(pos);
1738 if (m_LoginTime > 0)
1740 if (!m_LoginTimeScreen)
1751 m_LoginTimeScreen =
new LoginTimeStatic();
1756 m_LoginTimeScreen.SetTime(m_LoginTime);
1757 m_LoginTimeScreen.Show();
1767 if (m_LoginTime > 0)
1769 if (m_LoginTimeScreen)
1770 m_LoginTimeScreen.SetTime(m_LoginTime);
1788 if (!m_LoginTimeScreen)
1796 m_LoginTimeScreen.SetRespawn(
true);
1797 m_LoginTimeScreen.SetTime(m_LoginTime);
1798 m_LoginTimeScreen.Show();
1813 if (m_LoginTimeScreen && !m_LoginTimeScreen.IsRespawn())
1873 m_loading.SetTitle(
title);
1874 if (m_loading.m_HintPanel)
1875 m_loading.m_HintPanel.ShowRandomPage();
1895 m_loading.SetProgress(0);
1974 protected const int MAX_VISITED = 50;
1992 m_IntroMenu =
GetWorkspace().CreateWidgets(
"gui/layouts/xbox/day_z_title_screen.layout");
1994 m_IntroMenu.FindAnyWidget(
"notification_root").Show(
false);
1997 string text =
Widget.TranslateString(
"#console_start_game");
2001 text_widget.SetText(
string.Format(
text,
"<image set=\"xbox_buttons\" name=\"A\" />"));
2003 text_widget.SetText(
string.Format(
text,
"<image set=\"xbox_buttons\" name=\"A\" />"));
2012 text_widget.SetText(
string.Format(
text,
"<image set=\"playstation_buttons\" name=\"" +
confirm +
"\" />"));
2016#ifdef PLATFORM_CONSOLE
2018#ifdef BUILD_EXPERIMENTAL
2019 m_IntroMenu.FindAnyWidget(
"notification_root").Show(
true);
2038#ifdef PLATFORM_CONSOLE
2041 m_ShouldShowControllerDisconnect = !
GetInput().AreAllAllowedInputDevicesActive();
2042 if (m_ShouldShowControllerDisconnect)
2053#ifdef PLATFORM_CONSOLE
2072#ifndef PLATFORM_WINDOWS
2073#ifdef PLATFORM_CONSOLE
2098#ifdef PLATFORM_WINDOWS
2126#ifndef PLATFORM_WINDOWS
2127#ifdef PLATFORM_CONSOLE
2222 g_Game.SetHudBrightness(
g_Game.GetHUDBrightnessSetting());
2239 if (
GetInput().IsActiveGamepadSelected())
2248#ifdef PLATFORM_CONSOLE
2249#ifndef PLATFORM_WINDOWS
2289#ifdef PLATFORM_CONSOLE
2378 if (m_ConnectAddress ==
address && m_ConnectPort ==
port)
2397 if (m_Visited.Count() > 0)
2399 string uid = m_Visited.Get(m_Visited.Count() - 1);
2415 int pos = m_Visited.Find(
uid);
2419 if (m_Visited.Count() == MAX_VISITED)
2420 m_Visited.Remove(0);
2421 m_Visited.Insert(
uid);
2426 if (pos != (m_Visited.Count() - 1))
2428 m_Visited.Remove(pos);
2429 m_Visited.Insert(
uid);
2441 return (
index >= 0);
2450 m_ConnectAddress =
addr;
2451 m_ConnectPort =
port;
2465 if (m_ConnectAddress ==
addr && m_ConnectPort ==
port)
2469 if (
Connect(
GetUIManager().GetMenu(), m_ConnectAddress, m_ConnectPort, m_ConnectPassword) != 0)
2501 GetGame().GetUIManager().CloseAllSubmenus();
2504 GetGame().GetUIManager().CloseDialog();
2517 GetGame().GetMission().AbortMission();
2532 m_ConnectAddress =
ip;
2533 m_ConnectPort =
port;
2535 m_ConnectFromJoin =
false;
2541 m_ConnectAddress =
ip;
2542 m_ConnectPort =
port;
2543 m_ConnectFromJoin =
true;
2553 m_ConnectPort =
port.ToInt();
2557 m_ConnectFromJoin =
false;
2572 m_IsCtrlHolding =
true;
2575 m_IsLeftAltHolding =
true;
2578 m_IsRightAltHolding =
true;
2580 if (m_keyboard_handler)
2588 if ((m_IsLeftAltHolding || m_IsLeftAltHolding) &&
key ==
KeyCode.KC_F4)
2598 m_IsCtrlHolding =
false;
2601 m_IsWinHolding =
false;
2604 m_IsLeftAltHolding =
false;
2607 m_IsRightAltHolding =
false;
2609 if (m_keyboard_handler)
2636 m_IsCtrlHolding =
false;
2637 m_IsWinHolding =
false;
2638 m_IsLeftAltHolding =
false;
2639 m_IsRightAltHolding =
false;
2671 if (m_loading && m_loading.IsLoading())
2673 else if (m_LoginTimeScreen && m_LoginTimeScreen.IsStatic())
2684 if (m_Notifications)
2688#ifdef DIAG_DEVELOPER
2726 if (m_loading && m_loading.IsLoading())
2729 else if (m_LoginTimeScreen && m_LoginTimeScreen.IsStatic())
2759 case ERPCs.RPC_CFG_GAMEPLAY_SYNC:
2764 case ERPCs.RPC_UNDERGROUND_SYNC:
2769 case ERPCs.RPC_SEND_NOTIFICATION:
2782 case ERPCs.RPC_SEND_NOTIFICATION_EXTENDED:
2799 case ERPCs.RPC_SOUND_HELICRASH:
2817 m_CrashSound.SetAutodestroy(
true);
2823 case ERPCs.RPC_SOUND_ARTILLERY:
2843 m_ArtySound.SetAutodestroy(
true);
2847 case ERPCs.RPC_SOUND_CONTAMINATION:
2881 case ERPCs.RPC_SOUND_ARTILLERY_SINGLE:
2903 m_ArtySound.SetAutodestroy(
true);
2912 case ERPCs.RPC_SET_BILLBOARDS:
2914 if (!m_BillboardSetHandler)
2921 m_BillboardSetHandler.OnRPCIndex(
index);
2928 case ERPCs.RPC_USER_SYNC_PERMISSIONS:
2955 case ERPCs.DEV_SET_WEATHER:
2963 if (
data.m_FogValue >= 0)
2964 GetGame().GetWeather().GetFog().Set(
data.m_FogValue,
data.m_FogInterpolation,
data.m_FogDuration);
2966 if (
data.m_OvercastValue >= 0)
2967 GetGame().GetWeather().GetOvercast().Set(
data.m_OvercastValue,
data.m_OvercastInterpolation,
data.m_OvercastDuration);
2969 if (
data.m_RainValue >= 0)
2970 GetGame().GetWeather().GetRain().Set(
data.m_RainValue,
data.m_RainInterpolation,
data.m_RainDuration);
2974 ErrorEx(
"Failed to read weather debug data");
2980#ifdef DIAG_DEVELOPER
2982 case ERPCs.DIAG_CAMERATOOLS_CAM_DATA:
2990 case ERPCs.DIAG_CAMERATOOLS_CAM_SUBSCRIBE:
3017 if (
mission && !m_loading.IsLoading() && GetUIManager().IsDialogQueued())
3028 m_IsConnecting =
value;
3039 return m_loading && m_loading.IsLoading();
3052 m_loading.ShowEx(
this);
3060 m_loading.Hide(
force);
3063#ifdef PLATFORM_CONSOLE
3076 if (m_CharClassNames.Count() > 0)
3077 return m_CharClassNames[0];
3085 return m_CharClassNames.GetRandomElement();
3122 if (
source.ShootsExplosiveAmmo() &&
ammoType ==
"Explosion_40mm_Ammo")
3133 GetGame().GetPlayer().GetCurrentCamera().SpawnCameraShake(
modifier * m_AmmoShakeParams.m_Strength);
3150 GetGame().ConfigGetText(
"cfgAmmo " +
info.GetAmmoType() +
" spawnPileType",
pile);
3153 arrow.PlaceOnSurface();
3158 const float ARROW_PIERCE_DEPTH = 0.05;
3165 if (
info.GetIsWater())
3172 GetGame().ConfigGetText(
"cfgAmmo " +
info.GetAmmoType() +
" spawnPileType",
pile);
3180 arrow.SetDirection(dir);
3194 GetGame().ConfigGetText(
"cfgAmmo " +
info.GetAmmoType() +
" spawnPileType",
pile);
3201 if (parent && parent.IsPlayer())
3204 arrow.PlaceOnSurface();
3218 arrow.SetDirection(dir);
3221 info.GetHitObj().AddArrow(
arrow,
info.GetComponentIndex(),
info.GetHitObjPos(),
info.GetHitObjRot());
3255 if (
ammoType ==
"Bullet_40mm_ChemGas")
3256 GetGame().CreateObject(
"ContaminatedArea_Local", pos);
3257 else if (
ammoType ==
"Bullet_40mm_Explosive")
3317 m_PlayerName =
name;
3327 m_IsNewCharacter =
state;
3356 return noa.ReadValue();
3446#ifdef DIAG_DEVELOPER
3456 if (!m_ConnectedInputDeviceList)
3463 m_CursorDesiredVisibilityScript =
visible;
3477#ifdef PLATFORM_CONSOLE
3479 return GetInput().IsMouseConnected();
3483#ifdef PLATFORM_CONSOLE
3493#ifdef FEATURE_CURSOR
proto native CEApi GetCEApi()
Get the CE API.
const int ECE_DYNAMIC_PERSISTENCY
PlayerSpawnPresetDiscreteItemSetSlotData name
one set for cargo
DamageType
exposed from C++ (do not change)
class AttachmentSoundLookupTable extends SoundLookupTable m_NoiseParams
class DayZProfilesOptions PARTY_CONTROLLER_SELECT
class DayZProfilesOptions MISSION_USER_SELECT
ImageWidget m_ImageLogoCorner
ImageWidget m_ImageLoadingIcon
ImageWidget m_ImageWidgetBackground
enum DisconnectSessionFlags DISCONNECT_SESSION_FLAGS_FORCE
class DayZProfilesOptions PARTY_USER_SELECT
class DayZProfilesOptions JOIN_START
class DayZProfilesOptions MAIN_MENU_USER_SELECT
Param3< string, int, int > DayZProfilesOptionInt
class DayZProfilesOptions CONNECT_START
void SetProgress(float val)
TextWidget m_TextWidgetTitle
float m_LastProgressUpdate
class DayZProfilesOptions MISSION_START
const int DISCONNECT_SESSION_FLAGS_ALL
class DayZProfilesOptions PARTY
class DayZProfilesOptions MAIN_MENU_CONTROLLER_SELECT
ref UiHintPanelLoading m_HintPanel
@ DISCONNECT_ERROR_ENABLED
class DayZProfilesOptions UNDEFINED
TextWidget m_ModdedWarning
void ShowEx(DayZGame game)
Param3< string, float, float > DayZProfilesOptionFloat
ProgressBarWidget m_ProgressLoading
class DayZProfilesOptions JOIN_USER_SELECT
const int DISCONNECT_SESSION_FLAGS_JOIN
ImageWidget m_ImageLogoMid
DayZProfilesOption DayZProfilesOptionBool
class DayZProfilesOptions JOIN_CONTROLLER_SELECT
void SetTitle(string title)
class DayZProfilesOptions CONNECTING
class DayZProfilesOptions CONNECT_USER_SELECT
class DayZProfilesOptions MAIN_MENU_START
void LoadingScreen(DayZGame game)
TextWidget m_TextWidgetStatus
void SetStatus(string status)
class DayZProfilesOptions PARTY_START
float m_ImageLoadingIconRotation
ImageWidget m_ImageBackground
bool CanChangeHintPage(float timeAccu)
class LoginScreenBase extends UIScriptedMenu m_txtPosition
class DayZProfilesOptions m_WidgetRoot
class DayZProfilesOptions CONNECT
TextWidget m_ProgressText
class DayZProfilesOptions JOIN
class CrashSoundSets GetIsWater
Param3< string, bool, bool > DayZProfilesOption
void SetPosition(int position)
override bool OnClick(Widget w, int x, int y, int button)
buttons clicks
ProjectileStoppedInfo Managed GetSurfNormal()
class DayZProfilesOptions MAIN_MENU
class DayZProfilesOptions CONNECT_CONTROLLER_SELECT
void SetDispatcher(Dispatcher dispatcher)
int GetID()
Get the ID registered in SEffectManager.
ErrorCategory
ErrorCategory - To decide what ErrorHandlerModule needs to be called and easily identify where it cam...
class NoiseSystem NoiseParams()
NotificationType
DEPRECATED (moved into NotificationSystem)
void ParticleManager(ParticleManagerSettings settings)
Constructor (ctor)
class JsonUndergroundAreaTriggerData GetPosition
static void PlayerDisconnected(StatsEventDisconnectedData data)
static void PlayerSpawned(StatsEventSpawnedData data)
Static data of bleeding chance probabilities; currently used for melee only.
static void InitBleedChanceData()
ref LoginQueueBase m_LoginQueue
proto native UIManager GetUIManager()
void SetConnecting(bool value)
Returns true when connecting to server.
void SetProfileOptionInt(EDayZProfilesOptions option, int value)
proto bool ConfigGetChildName(string path, int index, out string name)
Get name of subclass in config class on path.
void SetConnectivityStatState(EConnectivityStatType type, EConnectivityStatLevel level)
void DisconnectSessionScript(bool displayJoinError=false)
override TStringArray ListAvailableCharacters()
ref array< int > m_ConnectedInputDeviceList
override void OnUpdate(bool doSim, float timeslice)
bool m_ShouldShowControllerDisconnect
proto native NoiseSystem GetNoiseSystem()
ref array< string > m_CharClassNames
ref EffectSound m_ArtySound
void UpdateVoiceLevel(int level)
override void OnActivateMessage()
void SetProfileOption(EDayZProfilesOptions option, bool value)
void AddVisitedServer(string ip, int port)
override void OnDeactivateMessage()
void UpdateLoginQueue(float timeslice)
override string CreateRandomPlayer()
void OnProjectileStoppedInTerrain(TerrainCollisionInfo info)
DayZGameState m_GameState
void SetPreviousGamepad(int gamepad)
proto native float ConfigGetFloat(string path)
Get float value from config on path.
float GetFoodDecayModifier()
ref DayZProfilesOptions m_DayZProfileOptions
override UIScriptedMenu CreateScriptedMenu(int id)
create custom main menu part (submenu)
void ResetProfileOptions()
float GetProfileOptionDefaultFloat(EDayZProfilesOptions option)
proto native void PlayMission(string path)
Starts mission (equivalent for SQF playMission). You MUST use double slash \.
void StoreLoginDataPrepare()
DayZGameState GetGameState()
override bool IsInventoryOpen()
void DelayedMidAirDetonation(float x, float y, float z)
override void OnPostUpdate(bool doSim, float timeslice)
int GetCurrentDisplayLanguageIdx()
proto native void SetPlayerName(string name)
Sets current player name.
float GetProfileOptionFloat(EDayZProfilesOptions option)
array< int > GetConnectedInputDeviceList()
proto native World GetWorld()
override ScriptCallQueue GetCallQueue(int call_category)
override void OnDeviceReset()
int GetProfileOptionDefaultInt(EDayZProfilesOptions option)
override void OnAfterCreate()
proto native bool IsMultiplayer()
void SetPlayerGameName(string name)
proto native void MutePlayer(string muteUID, string playerUID, bool mute)
Mutes voice of source player to target player.
void OnGameplayDataHandlerLoad()
string GetPlayerGameName()
bool GetProfileOptionDefaultBool(EDayZProfilesOptions option)
bool IsKindOf(string cfg_class_name, string cfg_parent_name)
Returns is class name inherited from parent class name.
void OnProjectileStopped(ProjectileStoppedInfo info)
proto bool GetHostAddress(out string address, out int port)
Gets the server address. (from client)
override DragQueue GetDragQueue()
void ExplosionEffectsEx(Object source, Object directHit, int componentIndex, float energyFactor, float explosionFactor, HitInfo hitInfo)
bool GetProfileOptionDefault(EDayZProfilesOptions option)
bool OnConnectivityStatChange(EConnectivityStatType type, EConnectivityStatLevel newLevel, EConnectivityStatLevel oldLevel)
void SetMouseCursorDesiredVisibility(bool visible)
static bool ReportModded()
void LoadingHide(bool force=false)
bool GetMouseCursorDesiredVisibility()
proto native void GetProfileStringList(string name, out TStringArray values)
Gets array of strings from profile variable.
proto native BiosUserManager GetUserManager()
void OnLoginTimeEvent(int loginTime)
override void OnEvent(EventType eventTypeId, Param params)
override void OnKeyPress(int key)
override ScriptInvoker GetUpdateQueue(int call_category)
bool m_early_access_dialog_accepted
void OnMPConnectionLostEvent(int duration)
ref EffectSound m_CrashSound
void RegisterProfilesOptions()
void CreateGamepadDisconnectMenu()
bool CanDisplayMouseCursor()
extend as needed, only game focus and M&K setting (consoles only!) are checked natively
void SetKeyboardHandle(UIScriptedMenu handler)
void OnRespawnEvent(int time)
float GetPreviousEVValue()
void LoginTimeCountdown()
proto native bool GetModToBeReported()
proto native void SetMainMenuWorld(string world)
proto native void RequestExit(int code)
Sets exit code and quits in the right moment.
float m_FoodDecayModifier
static bool m_ReportModded
map< EDayZProfilesOptions, ref DayZProfilesOption > GetProfileOptionMap()
ref BillboardSetHandler m_BillboardSetHandler
proto native AbstractSoundScene GetSoundScene()
void EarlyAccessDialog(UIScriptedMenu parent)
void OnPreloadEvent(vector pos)
bool m_IsWorldWetTempUpdateEnabled
proto native int ConfigGetInt(string path)
Get int value from config on path.
proto native bool IsServer()
int m_OriginalCharactersCount
void SetLoadState(DayZLoadState state)
string GetMissionFolderPath()
void EnterLoginTime(UIMenuPanel parent)
void RemoveVoiceNotification(VONStopSpeakingEventParams vonStopParams)
const int MISSION_STATE_GAME
ref TStringArray m_Visited
float GetCurrentEVValue()
static float GetUserFOVFromConfig()
override string CreateDefaultPlayer()
void EnterLoginQueue(UIMenuPanel parent)
void SetNewCharacter(bool state)
void RefreshCurrentServerInfo()
override void OnKeyRelease(int key)
void ClearConnectivityStates()
static bool CheckAmmoCompability(EntityAI weaponInHand, EntityAI ammo)
bool ShouldShowControllerDisconnect()
bool GetProfileOptionBool(EDayZProfilesOptions option)
void FirearmEffects(Object source, Object directHit, int componentIndex, string surface, vector pos, vector surfNormal, vector exitPos, vector inSpeed, vector outSpeed, bool isWater, bool deflected, string ammoType)
float GetFOVByZoomType(ECameraZoomType type)
void OnProjectileStoppedInObject(ObjectCollisionInfo info)
proto native owned string GetMainMenuWorld()
void ConnectFromServerBrowser(string ip, int port, string password="")
override void OnMouseButtonRelease(int button)
DayZLoadState GetLoadState()
proto native DayZPlayer GetPlayer()
void SetMissionPath(string path)
Called from C++.
bool GetLastVisitedServer(out string ip, out int port)
proto native WorkspaceWidget GetWorkspace()
ref ConnectionLost m_connectionLost
override void OnMouseButtonPress(int button)
proto native Object CreateObjectEx(string type, vector pos, int iFlags, int iRotation=RF_DEFAULT)
Creates object of certain type.
proto native void SaveProfile()
Saves profile on disk.
void SetDatabaseID(string id)
void InitCharacterMenuDataInfo(int menudata_count)
bool IsVisited(string ip, int port)
void SelectUser(int gamepad=-1)
void CancelLoginTimeCountdown()
UIScriptedMenu m_keyboard_handler
ref NotificationUI m_Notifications
proto native bool IsAppActive()
Returns if the application is focused on PC, returns true always on console.
ScriptModule m_mission_module
void RefreshMouseCursorVisibility()
bool GetProfileOption(EDayZProfilesOptions option)
DayZLoadState m_LoadState
string m_MissionFolderPath
bool IsFoodDecayEnabled()
float GetHUDBrightnessSetting()
ref LoginTimeBase m_LoginTimeScreen
proto native void SetProfileStringList(string name, TStringArray values)
Sets array of strings to profile variable.
native void CreateMission(string path)
Create only enforce script mission, used for mission script reloading.
proto native void DisconnectSessionForce()
Forces disconnect from current multiplayer session even if not yet in the game.
override bool OnInitialize()
proto native float SurfaceGetNoiseMultiplier(Object directHit, vector pos, int componentIndex)
proto native int ConfigGetChildrenCount(string path)
Get count of subclasses in config class on path.
void SetUserFOV(float pFov)
ref DragQueue m_dragQueue
int GetProfileOptionInt(EDayZProfilesOptions option)
void SetEVValue(float value)
const float ARROW_PIERCE_DEPTH
void SetProfileOptionBool(EDayZProfilesOptions option, bool value)
override ScriptInvoker GetPostUpdateQueue(int call_category)
void SetProfileOptionFloat(EDayZProfilesOptions option, float value)
override TimerQueue GetTimerQueue(int call_category)
override void OnRPC(PlayerIdentity sender, Object target, int rpc_type, ParamsReadContext ctx)
proto bool CommandlineGetParam(string name, out string value)
Get command line parameter value.
void CloseCombatEffects(Object source, Object directHit, int componentIndex, string surface, vector pos, vector surfNormal, bool isWater, string ammoType)
proto native void SetEVUser(float value)
Sets custom camera camera EV. range: -50.0..50.0? //TODO.
void SetHudBrightness(float value)
bool m_CursorDesiredVisibilityScript
void DeleteGamepadDisconnectMenu()
proto native void AbortMission()
Returns to main menu, leave world empty for using last mission world.
proto native Input GetInput()
proto native void StartRandomCutscene(string world)
Starts intro.
BillboardSetHandler GetBillboardHandler()
proto native Mission GetMission()
MenuDefaultCharacterData GetMenuDefaultCharacterData(bool fill_data=true)
void ExplosionEffects(Object source, Object directHit, int componentIndex, string surface, vector pos, vector surfNormal, float energyFactor, float explosionFactor, bool isWater, string ammoType)
void UpdateInputDeviceDisconnectWarning()
void ConnectFromJoin(string ip, int port)
void SetGameState(DayZGameState state)
ref Widget m_GamepadDisconnectMenu
void DisconnectSessionEx(DisconnectSessionFlags flags)
void AddVoiceNotification(VONStopSpeakingEventParams vonStartParams)
void LoadProgressUpdate(int progressState, float progress, string title)
void SetMissionState(int state)
ref LoadingScreen m_loading
proto native void StoreLoginData(ParamsWriteContext ctx)
Stores login userdata as parameters which are sent to server.
bool IsWorldWetTempUpdateEnabled()
static void OnRPC(Man player, ParamsReadContext ctx)
Super root of all classes in Enforce script.
static void ResetClientData()
TextWidget m_TextWidgetTitle
void SetDuration(float duration)
void ConnectionLost(DayZGame game)
void SetText(string text)
static void RegisterSoundSet(string sound_set)
static ref map< int, string > m_Mappings
static string GetSoundSetByHash(int hash)
bool GetProfileOptionBool(EDayZProfilesOptions option)
ref map< EDayZProfilesOptions, ref DayZProfilesOptionBool > m_DayZProfilesOptionsBool
void RegisterProfileOptionFloat(EDayZProfilesOptions option, string profileOptionName, float defaultValue=0.0)
ref map< EDayZProfilesOptions, ref DayZProfilesOption > m_DayZProfilesOptions
bool GetProfileOptionDefaultBool(EDayZProfilesOptions option)
float GetProfileOptionFloat(EDayZProfilesOptions option)
void SetProfileOption(EDayZProfilesOptions option, bool value)
void SetProfileOptionBool(EDayZProfilesOptions option, bool value)
DayZGame m_Game void DayZProfilesOptions()
map< EDayZProfilesOptions, ref DayZProfilesOptionBool > GetProfileOptionMap()
void SetProfileOptionFloat(EDayZProfilesOptions option, float value)
void RegisterProfileOptionBool(EDayZProfilesOptions option, string profileOptionName, bool defaultValue=true)
int GetProfileOptionInt(EDayZProfilesOptions option)
int GetProfileOptionDefaultInt(EDayZProfilesOptions option)
bool GetProfileOption(EDayZProfilesOptions option)
float GetProfileOptionDefaultFloat(EDayZProfilesOptions option)
void RegisterProfileOptionInt(EDayZProfilesOptions option, string profileOptionName, int defaultValue=0)
ref map< EDayZProfilesOptions, ref DayZProfilesOptionInt > m_DayZProfilesOptionsInt
bool GetProfileOptionDefault(EDayZProfilesOptions option)
void SetProfileOptionInt(EDayZProfilesOptions option, int value)
void RegisterProfileOption(EDayZProfilesOptions option, string profileOptionName, bool def=true)
ref map< EDayZProfilesOptions, ref DayZProfilesOptionFloat > m_DayZProfilesOptionsFloat
Wrapper class for managing sound through SEffectManager.
The error handler itself, for managing and distributing errors to modules Manages the ErrorHandlerMod...
static proto native ErrorModuleHandler GetInstance()
Gets the EMH Instance.
static proto int ThrowError(ErrorCategory category, int code, string additionalInfo="")
Creates and throws the error code, sending it to the handler of the category.
struct that keeps Time relevant information for future formatting
static void EvaluateImpactEffectEx(ImpactEffectsData pData)
LoginQueue position when using -connect since mission is not created yet.
void SetStatus(string status)
override bool OnClick(Widget w, int x, int y, int button)
TextWidget m_txtDescription
bool CanChangeHintPage(float timeAccu)
ref FullTimeData m_FullTime
void SetRespawn(bool value)
LoginTime when using -connect since mission is not created yet.
void OnUpdate(float timeslice)
void OnKeyRelease(int key)
void OnMouseButtonRelease(int button)
void OnMouseButtonPress(int button)
UIScriptedMenu CreateScriptedMenu(int id)
void OnEvent(EventType eventTypeId, Param params)
static void AddNotificationExtended(float show_time, string title_text, string detail_text="", string icon="")
Send custom notification from to local player.
static void InitInstance()
static void CleanupInstance()
const int DEFAULT_TIME_DISPLAYED
static void AddNotification(NotificationType type, float show_time, string detail_text="")
Send notification from default types to local player.
static void Update(float timeslice)
proto native vector GetHitObjRot()
proto native Object GetHitObj()
proto native vector GetHitObjPos()
proto native int GetComponentIndex()
static void OnGameplayDataHandlerLoad()
static void LoadVoicePrivilege()
static void LeaveGameplaySession()
static BiosUser GetBiosUser()
static void GetCurrentServerInfo(string ip, int port)
static void SetBiosUser(BiosUser user)
static void EnterGameplaySession()
static void SetMultiplayState(bool state)
static void LoadMPPrivilege()
static void ClearCurrentServerInfo()
Static component of PPE manager, used to hold the instance.
static void CreateManagerStatic()
static PPEManager GetPPEManager()
Returns the manager instance singleton.
static void DestroyManagerStatic()
Base Param Class with no parameters. Used as general purpose parameter overloaded with Param1 to Para...
static const int EXPLOSION_LANDMINE
static const int CONTAMINATED_AREA_GAS_SHELL
static void PreloadParticles()
Preloads all particles.
The class that will be instanced (moddable)
static proto native void SetUserData(Widget inst)
static proto native void DestroyAllPendingProgresses()
static proto native void SetProgressData(Widget inst)
proto native vector GetPos()
proto native string GetAmmoType()
proto native float GetProjectileDamage()
proto native Object GetSource()
proto native vector GetInVelocity()
Manager class for managing Effect (EffectParticle, EffectSound)
static EffectSound PlaySound(string sound_set, vector position, float play_fade_in=0, float stop_fade_out=0, bool loop=false)
Create and play an EffectSound.
ScriptCallQueue Class provide "lazy" calls - when we don't want to execute function immediately but l...
ScriptInvoker Class provide list of callbacks usage:
Module containing compiled scripts.
Serialization general interface. Serializer API works with:
static void OnRPC(ParamsReadContext ctx)
Manager class which handles Voice-over-network functionality while player is connected to a server.
static VONManagerBase GetInstance()
Main way to access VONManager functionality from script.
static proto native float DistanceSq(vector v1, vector v2)
Returns the square distance between tips of two 3D vectors.
proto float Normalize()
Normalizes vector. Returns length.
static proto native float Distance(vector v1, vector v2)
Returns the distance between tips of two 3D vectors.
class DayZPlayerCameraResult DayZPlayerCamera(DayZPlayer pPlayer, HumanInputController pInput)
const int PROGRESS_UPDATE
const EventType MPSessionEndEventTypeID
no params
const EventType ConnectingStartEventTypeID
no params
PlayerIdentity PROGRESS_START
const EventType LoginStatusEventTypeID
params: LoginStatusEventParams
const EventType WorldCleaupEventTypeID
no params
const EventType SelectedUserChangedEventTypeID
no params
const EventType RespawnEventTypeID
params: RespawnEventParams
const EventType MPSessionFailEventTypeID
no params
const int PROGRESS_PROGRESS
const EventType StartupEventTypeID
no params
const EventType DialogQueuedEventTypeID
no params
const EventType MPSessionStartEventTypeID
no params
const EventType PreloadEventTypeID
params: PreloadEventParams
const EventType LoginTimeEventTypeID
params: LoginTimeEventParams
const EventType ServerFpsStatsUpdatedEventTypeID
params: ServerFpsStatsUpdatedEventParams
const EventType ConnectivityStatsUpdatedEventTypeID
params: ConnectivityStatsUpdatedEventParams
const EventType MPConnectionLostEventTypeID
params: MPConnectionLostEventParams
const EventType LogoutEventTypeID
params: LogoutEventParams
const EventType MPSessionPlayerReadyEventTypeID
no params
const EventType DLCOwnerShipFailedEventTypeID
params: DLCOwnerShipFailedParams
const int PROGRESS_FINISH
proto native CGame GetGame()
const EventType ProgressEventTypeID
params: ProgressEventParams
OptionAccessType
C++ OptionAccessType.
const EventType ChatMessageEventTypeID
params: ChatMessageEventParams
const EventType ConnectingAbortEventTypeID
no params
const string GAME_CHAT_MSG
const string SYSTEM_CHAT_MSG
const string RADIO_CHAT_MSG
const string PLAYER_CHAT_MSG
const string DIRECT_CHAT_MSG
const string ADMIN_CHAT_MSG
proto void Print(void var)
Prints content of variable to console/log.
static proto native void End()
static proto native void Begin(string windowTitle, float x=0, float y=0)
static proto native void PlotLive(string label, int sizeX, int sizeY, float val, int timeStep=100, int historySize=30, int color=0xFFFFFFFF)
static proto native void Text(string label)
static proto native void ColoredText(int color, string label)
const int CAMERA_SHAKE_ARTILLERY_DISTANCE
const float DZPLAYER_CAMERA_FOV_EYEZOOM
FOV (vertical angle/2) in radians. Take care to modify also in "basicDefines.hpp".
const float DZPLAYER_CAMERA_FOV_EYEZOOM_SHALLOW
const float LOADING_SCREEN_HINT_INTERVAL
const int CAMERA_SHAKE_ARTILLERY_DISTANCE2
const float LOADING_SCREEN_HINT_INTERVAL_MIN
static proto bool CastTo(out Class to, Class from)
Try to safely down-cast base class to child class.
array< string > TStringArray
const string SHOW_QUICKBAR
const string SHOW_SERVERINFO
const string SHOW_CONNECTIVITYINFO
const string HUD_BRIGHTNESS
const string ENABLE_BLEEDINGINDICATION
const string SHOW_CROSSHAIR
proto native vector Vector(float x, float y, float z)
Vector constructor from components.
static proto int Randomize(int seed)
Sets the seed for the random number generator.
static proto float Lerp(float a, float b, float time)
Linearly interpolates between 'a' and 'b' given 'time'.
static proto float Sqrt(float val)
Returns square root.
static proto float Min(float x, float y)
Returns smaller of two given values.
static proto float RandomFloat(float min, float max)
Returns a random float number between and min[inclusive] and max[exclusive].
static proto float InverseLerp(float a, float b, float value)
Calculates the linear value that produces the interpolant value within the range [a,...
proto string Substring(int start, int len)
Substring of 'str' from 'start' position 'len' number of characters.
proto native int IndexOfFrom(int start, string sample)
Finds 'sample' in 'str' from 'start' position. Returns -1 when not found.
proto bool GetCLIParam(string param, out string val)
Returns command line argument.