9 enum ESubscriberSystems
11 TRIGGERS = 0x00000001,
22 static int m_SystemsMaks;
23 static bool DIAGS_REGISTERED;
25 bool m_EnableModifiers =
true;
26 bool m_EnableUnlimitedAmmo;
27 bool m_DisableBloodLoss =
false;
28 int m_IsInvincible =
false;
29 bool m_ShowCraftingDebugActions =
false;
30 bool m_BuildWood =
false;
31 bool m_BuildGate =
false;
32 bool m_LogPlayerStats =
false;
33 bool m_SoftSkillsState =
false;
34 bool m_SoftSkillsDebug =
false;
35 bool m_GunParticlesState =
false;
36 bool m_SoftSkillsModel =
false;
38 bool m_PermanentCrossHair =
false;
39 bool m_ToggleHud =
false;
40 bool m_ShowingWeaponDebug =
false;
41 bool m_AimNoiseEnabled =
true;
42 int m_DisplayPlayerInfo =
false;
43 bool m_ProceduralRecoilEnabled =
true;
44 bool m_EnableQuickRestrain =
false;
45 bool m_EnableQuickFishing =
false;
46 bool m_StaminaDisabled =
false;
47 bool m_EnvironmentStats =
false;
48 bool m_EnableUniversalTemperatureSources =
false;
49 bool m_DrawCheckerboard =
false;
50 bool m_PresenceNotifierDebug =
false;
51 bool m_ShowBleedingSources =
false;
52 bool m_DoActionLogs =
false;
53 bool m_DoWeaponLogs =
false;
54 bool m_DoInventoryMoveLogs =
false;
55 bool m_DoInventoryReservationLogs =
false;
56 bool m_DoInventoryHFSMLogs =
false;
57 bool m_DoSymptomLogs =
false;
58 bool m_AllowInventoryAccess =
false;
59 bool m_EnableRemoteCamera;
60 bool m_FixItems =
false;
61 bool m_HitIndicationDebugEnabled =
false;
63 float m_SpecialtyLevel = 0;
64 float m_LifespanLevel = 0;
65 int m_DayzPlayerDebugMenu = -1;
66 int m_BleedingSourceRequested;
67 int m_BleedingSourceLevelRequested;
68 int m_HairLevelSelected = 0;
69 int m_TotalHairLevelsAdjusted;
71 static bool ENABLE_BREATH_VAPOR;
76 Shape m_VehicleFreeAreaBox;
92 g_Game.ConfigGetTextArray(
"cfgVehicles Head_Default simpleHiddenSelections", m_HairSelectionArray);
93 m_TotalHairLevelsAdjusted = m_HairSelectionArray.Count() - 1;
94 for (
int i = 0; i < m_HairSelectionArray.Count(); ++i)
96 m_HairHidingStateMap.Insert(i, 1);
102 m_Timer.Run(0.5,
this,
"Update",
null,
true);
104 if (DIAGS_REGISTERED)
120 DiagMenu.RegisterBool(
DiagMenuIDs.DM_PLAYER_SYMPTOMS_SHOW,
"lalt+6",
"Show States",
"Player States");
131 DiagMenu.RegisterBool(
DiagMenuIDs.DM_TRANSFER_VALUES_SHOW,
"",
"ShowValues",
"TransferValues");
142 DiagMenu.RegisterBool(
DiagMenuIDs.DM_PLAYER_CRAFTING_GENERATE,
"",
"Generate Cache",
"Crafting");
143 DiagMenu.RegisterBool(
DiagMenuIDs.DM_PLAYER_CRAFTING_DEBUG_ACTIONS_ENABLE,
"",
"Debug Insta Crafting",
"Crafting");
144 DiagMenu.RegisterBool(
DiagMenuIDs.DM_PLAYER_CRAFTING_DUMP,
"",
"Dump recipes to file",
"Crafting");
155 DiagMenu.RegisterBool(
DiagMenuIDs.DM_CHEATS_MODIFIERS_ENABLE,
"lalt+2",
"Tick Modifiers",
"Cheats");
157 DiagMenu.RegisterBool(
DiagMenuIDs.DM_CHEATS_PLAYER_INSTAKILL,
"",
"Kill Player",
"Cheats");
158 DiagMenu.RegisterItem(
DiagMenuIDs.DM_CHEATS_INVINCIBILITY,
"lalt+1",
"Invincibility (IDDQD)",
"Cheats",
"Disabled,Partial,Full" );
159 DiagMenu.RegisterBool(
DiagMenuIDs.DM_CHEATS_STAMINA_DISABLE,
"",
"Disable stamina",
"Cheats");
161 DiagMenu.RegisterBool(
DiagMenuIDs.DM_PLAYER_RESET_MAX,
"lalt+3",
"Reset Player Max",
"Cheats");
162 DiagMenu.RegisterBool(
DiagMenuIDs.DM_PLAYER_INVENTORY_ACCESS,
"",
"Inventory Access",
"Cheats");
174 DiagMenu.RegisterBool(
DiagMenuIDs.DM_PLAYER_AGENTS_INJECTS_SHOW,
"lalt+5",
"Allow Inject Actions",
"Player Agents");
185 DiagMenu.RegisterBool(
DiagMenuIDs.DM_SOFT_SKILLS_SHOW_DEBUG,
"",
"Show Debug",
"Soft Skills" );
186 DiagMenu.RegisterBool(
DiagMenuIDs.DM_SOFT_SKILLS_TOGGLE_STATE,
"",
"Enable SoftSkills",
"Soft Skills" );
187 DiagMenu.RegisterBool(
DiagMenuIDs.DM_SOFT_SKILLS_TOGGLE_MODEL,
"",
"Enable linear model",
"Soft Skills" );
188 DiagMenu.RegisterRange(
DiagMenuIDs.DM_SOFT_SKILLS_SPECIALTY_VALUE,
"",
"Set specialty value",
"Soft Skills",
"-1, 1, 0, 0.01" );
200 DiagMenu.RegisterRange(
DiagMenuIDs.DM_LIFESPAN_PLAYTIME_UPDATE,
"",
"Playtime in minutes",
"Lifespan",
"0, 600, 0, 10" );
211 DiagMenu.RegisterBool(
DiagMenuIDs.DM_DISABLE_PERSONAL_LIGHT,
"",
"Disable Personal Light",
"Misc");
212 DiagMenu.RegisterBool(
DiagMenuIDs.DM_ITEM_DEBUG_ACTIONS_SHOW,
"lalt+4",
"Item Debug Actions",
"Misc");
213 DiagMenu.RegisterBool(
DiagMenuIDs.DM_PLAYER_STATS_LOG_ENABLE,
"",
"Log Player Stats",
"Misc");
219 DiagMenu.RegisterBool(
DiagMenuIDs.DM_ACTION_TARGETS_NEW,
"",
"New AT Selection",
"Action Targets",
true);
220 DiagMenu.RegisterBool(
DiagMenuIDs.DM_ACTION_TARGETS_DEBUG,
"",
"Show Debug",
"Action Targets");
221 DiagMenu.RegisterBool(
DiagMenuIDs.DM_ACTION_TARGETS_SELPOS_DEBUG,
"",
"Show selection pos debug",
"Action Targets");
226 DiagMenu.RegisterBool(
DiagMenuIDs.DM_PERMANENT_CROSSHAIR,
"",
"Enable permanent crosshair",
"Misc");
227 DiagMenu.RegisterBool(
DiagMenuIDs.DM_SHOW_VEHICLE_GETOUT_BOX,
"",
"Debug transport freespace",
"Misc");
229 DiagMenu.RegisterBool(
DiagMenuIDs.DM_ENVIRONMENT_DEBUG_ENABLE,
"",
"Show Environment stats",
"Misc");
230 DiagMenu.RegisterRange(
DiagMenuIDs.DM_DISPLAY_PLAYER_INFO,
"",
"Display Player Info",
"Misc",
"0,2,0,1");
231 DiagMenu.RegisterBool(
DiagMenuIDs.DM_UNIVERSAL_TEMPERATURE_SOURCES,
"lalt+u",
"Universal Temp Sources",
"Misc");
232 DiagMenu.RegisterBool(
DiagMenuIDs.DM_DRAW_CHECKERBOARD,
"",
"Draw Checkerboard on screen",
"Misc");
234 DiagMenu.RegisterBool(
DiagMenuIDs.DM_PRESENCE_NOTIFIER_DBG,
"",
"Show Presence to AI dbg",
"Misc");
236 DiagMenu.RegisterBool(
DiagMenuIDs.DM_GO_UNCONSCIOUS_DELAYED,
"",
"Uncons. in 10sec",
"Misc");
243 DiagMenu.RegisterBool(
DiagMenuIDs.DM_HAIR_DISPLAY_DEBUG,
"",
"Display Debug",
"Hair Hiding");
244 DiagMenu.RegisterRange(
DiagMenuIDs.DM_HAIR_LEVEL,
"",
"Hair Level#",
"Hair Hiding",
string.Format(
"0,%1,0,1", m_TotalHairLevelsAdjusted));
245 DiagMenu.RegisterBool(
DiagMenuIDs.DM_HAIR_LEVEL_HIDE,
"",
"Toggle Hair Level",
"Hair Hiding");
253 DiagMenu.RegisterBool(
DiagMenuIDs.DM_HOLOGRAM,
"lctrl+h",
"Hologram placing debug",
"Misc");
255 DiagMenu.RegisterBool(
DiagMenuIDs.DM_SHOW_PLUG_ARROWS,
"",
"Show Energy Manager Plug Arrows",
"Misc");
258 DiagMenu.RegisterBool(
DiagMenuIDs.DM_TARGETABLE_BY_AI,
"",
"Toggle Targetable By AI",
"Misc");
265 DiagMenu.RegisterBool(
DiagMenuIDs.DM_HIT_INDICATION_ENABLE_DEBUG,
"",
"Enable Debug",
"Hit Indication");
266 DiagMenu.RegisterBool(
DiagMenuIDs.DM_HIT_INDICATION_SPAWN_HIT,
"",
"Spawn Hit",
"Hit Indication");
267 DiagMenu.RegisterRange(
DiagMenuIDs.DM_HIT_INDICATION_SPAWN_HIT_DIRECTION,
"",
"Spawn Hit Direction",
"Hit Indication",
"0, 359, 0, 1");
268 DiagMenu.RegisterItem(
DiagMenuIDs.DM_HIT_INDICATION_MODE,
"",
"Mode",
"Hit Indication",
"Disabled,Static,Dynamic");
270 DiagMenu.RegisterItem(
DiagMenuIDs.DM_HIT_INDICATION_TYPE,
"",
"Type",
"Hit Indication",
"Splash,Spike,Arrow");
271 DiagMenu.RegisterRange(
DiagMenuIDs.DM_HIT_INDICATION_DURATION,
"",
"Hit Duration Max",
"Hit Indication",
"0.1, 5.0, 1.0, 0.1");
272 DiagMenu.RegisterRange(
DiagMenuIDs.DM_HIT_INDICATION_BREAKPOINT,
"",
"Hit Breakpoint",
"Hit Indication",
"0.0, 1.0, 0.8, 0.05");
273 DiagMenu.RegisterRange(
DiagMenuIDs.DM_HIT_INDICATION_DISTANCE,
"",
"Distance Adjust",
"Hit Indication",
"0.0, 1.0, 0.0, 0.01");
274 DiagMenu.RegisterRange(
DiagMenuIDs.DM_HIT_INDICATION_ROTATION,
"",
"Rotation Override",
"Hit Indication",
"0, 360, 0, 15");
275 DiagMenu.RegisterRange(
DiagMenuIDs.DM_HIT_INDICATION_SCATTER,
"",
"Direction Scatter",
"Hit Indication",
"0, 90, 0, 1");
276 DiagMenu.RegisterBool(
DiagMenuIDs.DM_HIT_INDICATION_DISABLE_PPE,
"",
"Disable Hit PPE",
"Hit Indication");
281 DiagMenu.RegisterBool(
DiagMenuIDs.DM_SUPPRESSNEXTFRAMEINPUTS,
"",
"Suppress Next Frame Inputs",
"Misc");
293 DiagMenu.RegisterBool(
DiagMenuIDs.DM_SIMULATE_INFINITE_LOOP,
"",
"Simulate infinite loop",
"Simulate script");
294 DiagMenu.RegisterBool(
DiagMenuIDs.DM_SIMULATE_NULL_POINTER,
"",
"Simulate null pointer",
"Simulate script");
295 DiagMenu.RegisterBool(
DiagMenuIDs.DM_SIMULATE_DIVISION_BY_ZERO,
"",
"Simulate division by 0",
"Simulate script");
296 DiagMenu.RegisterBool(
DiagMenuIDs.DM_SIMULATE_ERROR_FUNCTION,
"",
"Simulate Error() function",
"Simulate script");
307 DiagMenu.RegisterBool(
DiagMenuIDs.DM_MELEE_DEBUG_ENABLE,
"",
"Enable Melee Debug",
"Melee");
312 DiagMenu.RegisterBool(
DiagMenuIDs.DM_MELEE_DRAW_BLOCK_RANGE_AI,
"",
"Draw block range PVE",
"Melee");
313 DiagMenu.RegisterBool(
DiagMenuIDs.DM_MELEE_DRAW_BLOCK_RANGE_PVP,
"",
"Draw block range PVP",
"Melee");
324 DiagMenu.RegisterBool(
DiagMenuIDs.DM_GUN_PARTICLES,
"",
"Enable gun particles",
"Weapon",
true);
328 DiagMenu.RegisterBool(
DiagMenuIDs.DM_WEAPON_ALLOW_RECOIL,
"",
"Procedural Recoil",
"Weapon");
330 DiagMenu.RegisterBool(
DiagMenuIDs.DM_WEAPON_UNLIMITED,
"lalt+9",
"Unlimited Ammo",
"Weapon");
331 DiagMenu.RegisterItem(
DiagMenuIDs.DM_WEAPON_BURST,
"lctrl+0",
"Burst Version",
"Weapon",
"Hold, Press");
332 DiagMenu.RegisterBool(
DiagMenuIDs.DM_WEAPON_CLAYMORE_DEBUG,
"",
"Claymore debugs",
"Weapon");
343 DiagMenu.RegisterBool(
DiagMenuIDs.DM_SHOW_BLEEDING_SOURCES,
"",
"Show Bleeding Sources",
"Bleeding");
344 DiagMenu.RegisterBool(
DiagMenuIDs.DM_DISABLE_BLOOD_LOSS,
"",
"Disable Blood Loss",
"Bleeding");
345 DiagMenu.RegisterRange(
DiagMenuIDs.DM_ACTIVATE_SOURCE,
"",
"Activate Source #",
"Bleeding",
"1, 32, 0, 1");
346 DiagMenu.RegisterBool(
DiagMenuIDs.DM_ACTIVATE_ALL_BS,
"",
"Activate All Sources",
"Bleeding");
347 DiagMenu.RegisterItem(
DiagMenuIDs.DM_ACTIVATE_BS_LEVEL,
"",
"Activate Blsource Level",
"Bleeding",
"None, Low, Medium, High");
350 DiagMenu.RegisterMenu(
DiagMenuIDs.DM_BLEEDINGINDICATORS_MENU,
"Bleeding Indication",
"Bleeding");
355 DiagMenu.RegisterBool(
DiagMenuIDs.DM_BLEEDINGINDICATORS_ENABLE,
"",
"Enable BleedingIndicators",
"Bleeding Indication");
357 DiagMenu.RegisterBool(
DiagMenuIDs.DM_BLEEDINGINDICATORS_USEVALUEOVERRIDES,
"",
"Enable Debug Overrides",
"Bleeding Indication");
359 DiagMenu.RegisterBool(
DiagMenuIDs.DM_BLEEDINGINDICATORS_DROP_RANDOMROTATION,
"",
"Enable Random Rotation",
"Bleeding Indication");
371 DiagMenu.RegisterRange(
DiagMenuIDs.DM_BLEEDINGINDICATORS_DROP_SLIDEDISTANCE,
"",
"Drop Slide Distance",
"Bleeding Indication",
"0.0, 500.0, 0, 0.1");
372 DiagMenu.RegisterMenu(
DiagMenuIDs.DM_BLEEDINGINDICATORS_DROP_COLORMENU,
"Color Debug",
"Bleeding Indication");
377 DiagMenu.RegisterBool(
DiagMenuIDs.DM_BLEEDINGINDICATORS_DROP_ENABLEDESATURATION,
"",
"Desaturate",
"Color Debug");
404 DiagMenu.RegisterBool(
DiagMenuIDs.DM_LOG_INVENTORY_MOVE,
"",
"Log Items move",
"InventoryLog");
405 DiagMenu.RegisterBool(
DiagMenuIDs.DM_LOG_INVENTORY_RESERVATION,
"",
"Log Reservations",
"InventoryLog");
406 DiagMenu.RegisterBool(
DiagMenuIDs.DM_LOG_INVENTORY_HFSM,
"",
"Log HandFSM",
"InventoryLog");
418 DiagMenu.RegisterBool(
DiagMenuIDs.DM_SHOW_AREADMG_TRIGGER,
"",
"Show Triggers",
"Triggers");
419 DiagMenu.RegisterBool(
DiagMenuIDs.DM_SHOW_PLAYER_TOUCHTRIGGER,
"",
"Show Player Touch",
"Triggers");
420 #ifdef TRIGGER_DEBUG_BASIC
434 DiagMenu.RegisterBool(
DiagMenuIDs.DM_BUILD_WOOD,
"",
"Spawn uses wood/metal",
"Base Building");
435 DiagMenu.RegisterBool(
DiagMenuIDs.DM_BUILD_GATE,
"",
"Spawn Fence makes gate",
"Base Building");
446 DiagMenu.RegisterBool(
DiagMenuIDs.DM_UNDERGROUND_SHOW_BREADCRUMB,
"",
"Show Breadcrumbs",
"Underground Areas");
447 DiagMenu.RegisterBool(
DiagMenuIDs.DM_UNDERGROUND_DISABLE_DARKENING,
"lctrl+f",
"Disable Darkening",
"Underground Areas");
458 DiagMenu.RegisterItem(
DiagMenuIDs.DM_FINISHERS_FINISHER_FORCED,
"",
"Forced Finisher: ",
"Finishers",
"None,Liver,Neck");
469 DiagMenu.RegisterBool(
DiagMenuIDs.DM_SOUNDS_ITEM_IMPACT_SOUNDS,
"",
"Item impact sounds",
"Script Sounds");
475 DiagMenu.RegisterMenu(
DiagMenuIDs.DM_CAMERA_TOOLS_MENU,
"Cinematic Camera Tools",
"Script");
480 DiagMenu.RegisterBool(
DiagMenuIDs.DM_ENABLE_REMOTE_CAMERA,
"",
"Show remote camera",
"Cinematic Camera Tools");
481 DiagMenu.RegisterBool(
DiagMenuIDs.DM_ENABLE_REMOTE_CAMERA_BROADCAST,
"",
"Broadcast camera",
"Cinematic Camera Tools");
491 DiagMenu.RegisterBool(
DiagMenuIDs.DM_FEATURE_TIME_ACCEL_ENABLE,
"",
"Apply Time Accel",
"Time Accel");
492 DiagMenu.RegisterRange(
DiagMenuIDs.DM_FEATURE_TIME_ACCEL_VALUE1,
"",
"Accel Factor Big",
"Time Accel",
"0,100,1,1");
493 DiagMenu.RegisterRange(
DiagMenuIDs.DM_FEATURE_TIME_ACCEL_VALUE2,
"",
"Accel Factor Small",
"Time Accel",
"0,0.95 ,0,0.05");
494 DiagMenu.RegisterBool(
DiagMenuIDs.DM_FEATURE_TIME_ACCEL_UG_ENTRANCES,
"",
"Underground Entrances",
"Time Accel");
495 DiagMenu.RegisterBool(
DiagMenuIDs.DM_FEATURE_TIME_ACCEL_UG_RESERVOIR,
"",
"Underground Reservoir",
"Time Accel");
496 DiagMenu.RegisterBool(
DiagMenuIDs.DM_FEATURE_TIME_ACCEL_ENERGY_CONSUME,
"",
"Energy Consumption",
"Time Accel");
497 DiagMenu.RegisterBool(
DiagMenuIDs.DM_FEATURE_TIME_ACCEL_ENERGY_RECHARGE,
"",
"Energy Recharging",
"Time Accel");
501 DIAGS_REGISTERED =
true;
516 CheckCraftingDebugActions();
517 CheckItemDebugActions();
518 CheckAgentInjectActions();
519 CheckGenerateRecipeCache();
520 CheckDayzPlayerMenu();
521 CheckSoftSkillsDebug();
522 CheckSoftSkillsState();
523 CheckSoftSkillsModel();
525 CheckSpecialtyLevel();
527 CheckLifeSpanPlaytimeUpdate();
528 CheckPermanentCrossHairUpdate();
530 CheckShowWeaponDebug();
531 CheckInvincibility();
534 CheckProceduralRecoil();
535 CheckUnlimitedAmmo();
537 CheckEnvironmentStats();
538 CheckUniversalTemperatureSources();
540 CheckDrawCheckerboard();
543 CheckTargetableByAI();
544 CheckPresenceNotifierDebug();
545 CheckGoUnconscious();
546 CheckGoUnconsciousDelayed();
547 CheckSimulateNULLPointer();
548 CheckSimulateDivisionByZero();
549 CheckSimulateInfiniteLoop();
550 CheckSimulateErrorFunction();
551 CheckShowBleedingSources();
552 CheckDisableBloodLoss();
553 CheckActivateAllBS();
555 CheckActivateBleedingSource();
556 CheckActivateBleedingSourceLevel();
557 CheckQuickRestrain();
561 CheckPersonalLight();
563 CheckVehicleGetOutBox();
566 CheckDoInventoryLogs();
567 CheckDoSymptomLogs();
569 CheckInventoryAccess();
575 CheckBleedingIndicators();
576 CheckFinisherOverride();
577 CheckInputSuppression();
581 CheckClientCameraObserver();
587 void CheckTimeAccel()
591 int bitMask = GetTimeAccelBitmask();
595 TimeAccelParam param =
new TimeAccelParam(enable, timeAccel, bitMask);
597 if (!AreTimeAccelParamsSame(param, FeatureTimeAccel.m_CurrentTimeAccel))
599 SendTimeAccel(param);
600 FeatureTimeAccel.m_CurrentTimeAccel = param;
605 void CheckTriggerDebug()
607 EnableDebugSystemClient(ESubscriberSystems.TRIGGERS,
DiagMenu.GetBool(
DiagMenuIDs.DM_SHOW_AREADMG_TRIGGER));
611 void CheckBreathVapor()
617 void CheckClientCameraObserver()
621 if (!m_EnableRemoteCamera)
626 m_EnableRemoteCamera =
true;
631 if (m_EnableRemoteCamera)
639 m_EnableRemoteCamera =
false;
646 void CheckPlayerReset()
672 void CheckInventoryAccess()
676 if (!m_AllowInventoryAccess)
678 SendInventoryAccessRPC(
true);
680 m_AllowInventoryAccess =
true;
685 if (m_AllowInventoryAccess)
688 m_AllowInventoryAccess =
false;
703 void CheckModifiers()
707 if (!m_EnableModifiers)
709 SendModifiersRPC(
true);
710 m_EnableModifiers =
true;
715 if (m_EnableModifiers)
717 SendModifiersRPC(
false);
718 m_EnableModifiers =
false;
723 void CheckUnlimitedAmmo()
727 if (!m_EnableUnlimitedAmmo)
729 SendUnlimitedRPC(
true);
730 m_EnableUnlimitedAmmo =
true;
736 if (m_EnableUnlimitedAmmo)
738 SendUnlimitedRPC(
false);
739 m_EnableUnlimitedAmmo =
false;
745 void CheckDisableBloodLoss()
749 if (!m_DisableBloodLoss)
751 SendDisableBloodLossRPC(
true);
752 m_DisableBloodLoss =
true;
757 if (m_DisableBloodLoss)
759 SendDisableBloodLossRPC(
false);
760 m_DisableBloodLoss =
false;
765 void CheckActivateAllBS()
769 SendActivateAllBSRPC();
779 if (player && player.GetBleedingManagerRemote())
781 player.GetBleedingManagerRemote().Reload();
787 void CheckGenerateRecipeCache()
791 PluginRecipesManager plugin_recipes_manager;
792 Class.CastTo(plugin_recipes_manager,
GetPlugin(PluginRecipesManager));
793 plugin_recipes_manager.CallbackGenerateCache();
798 void CheckShowBleedingSources()
803 if ( !m_ShowBleedingSources )
806 player.GetBleedingManagerRemote().SetDiag(
true);
807 m_ShowBleedingSources =
true;
812 if ( m_ShowBleedingSources )
815 player.GetBleedingManagerRemote().SetDiag(
false);
816 m_ShowBleedingSources =
false;
821 void CheckKillPlayer()
830 void CheckGoUnconscious()
834 SendGoUnconsciousRPC(
false);
839 void CheckGoUnconsciousDelayed()
843 SendGoUnconsciousRPC(
true);
848 void CheckHairLevel()
851 if (value != m_HairLevelSelected)
853 m_HairLevelSelected = value;
865 SendSetHairLevelHideRPC(-1,value);
870 SendSetHairLevelHideRPC(m_HairLevelSelected,value);
875 void CheckPersonalLight()
883 void CheckItemDebugActions()
891 SendDebugActionsRPC();
899 ItemBase.SetDebugActionsMask(mask2);
900 SendDebugActionsRPC();
905 void CheckBulletImpact()
922 void CheckShockImpact()
927 if (tmp >= 1.0) tmp = 0.25;
928 pl_player.SpawnShockEffect(tmp);
934 void CheckHitDirection()
938 if (enabled != m_HitIndicationDebugEnabled)
949 m_HitIndicationDebugEnabled = enabled;
952 if ( m_HitIndicationDebugEnabled )
967 if ( m_HitIndicationDebugEnabled )
969 GetGame().GetMission().GetHud().SpawnHitDirEffect(player,
DiagMenu.GetRangeValue(
DiagMenuIDs.DM_HIT_INDICATION_SPAWN_HIT_DIRECTION),1.0);
974 if ( m_HitIndicationDebugEnabled )
981 void CheckBleedingIndicators()
988 if (player && player.GetBleedingManagerRemote())
990 player.GetBleedingManagerRemote().Reload();
1020 void CheckFinisherOverride()
1024 if ( player && player.GetMeleeCombat() && player.GetMeleeCombat().DebugGetForcedFinisherType() != value )
1026 player.GetMeleeCombat().DebugSetForcedFinisherType(value);
1027 SendForceFinisherType(value);
1031 void CheckTargetableByAI()
1037 if ( value != pl_player.m_CanBeTargetedDebug )
1039 pl_player.m_CanBeTargetedDebug = value;
1040 SendTargetabilityRPC(value);
1045 void CheckInputSuppression()
1058 void CheckFreezeEntity()
1063 if (PluginSceneManager.GetInstance() && PluginSceneManager.GetInstance().IsOpened())
1066 SceneObject scene_obj = PluginSceneManager.GetInstance().GetSelectedSceneObject();
1070 entity = scene_obj.GetObject();
1076 FreeDebugCamera camera = FreeDebugCamera.GetInstance();
1077 entity =
EntityAI.Cast(camera.GetCrosshairObject());
1081 entity.DisableSimulation(!entity.GetIsSimulationDisabled());
1088 void CheckAgentInjectActions()
1095 ItemBase.SetDebugActionsMask(mask);
1096 SendDebugActionsRPC();
1104 ItemBase.SetDebugActionsMask(mask2);
1105 SendDebugActionsRPC();
1131 void CheckCraftingDump()
1135 PluginRecipesManager plugin_recipes_manager;
1136 Class.CastTo(plugin_recipes_manager,
GetPlugin(PluginRecipesManager));
1137 plugin_recipes_manager.GenerateHumanReadableRecipeList();
1145 void CheckCraftingDebugActions()
1149 if (!m_ShowCraftingDebugActions)
1151 SendDebugCraftingRPC(
true);
1152 PluginRecipesManager plugin_recipes_manager;
1153 Class.CastTo(plugin_recipes_manager,
GetPlugin(PluginRecipesManager));
1154 plugin_recipes_manager.SetEnableDebugCrafting(
true);
1155 m_ShowCraftingDebugActions =
true;
1160 if (m_ShowCraftingDebugActions)
1162 SendDebugCraftingRPC(
false);
1163 PluginRecipesManager plugin_recipes_manager2;
1164 Class.CastTo(plugin_recipes_manager2,
GetPlugin(PluginRecipesManager));
1165 plugin_recipes_manager2.SetEnableDebugCrafting(
false);
1166 m_ShowCraftingDebugActions =
false;
1171 void CheckBuildWood()
1177 SendBuildWoodRPC(
true);
1185 SendBuildWoodRPC(
false);
1186 m_BuildWood =
false;
1191 void CheckBuildGate()
1197 SendBuildGateRPC(
true);
1205 SendBuildGateRPC(
false);
1206 m_BuildGate =
false;
1211 void CheckInvincibility()
1215 if (m_IsInvincible != 1)
1217 SendInvincibilityRPC(1);
1223 if (m_IsInvincible != 2)
1225 SendInvincibilityRPC(2);
1231 if (m_IsInvincible != 0)
1233 SendInvincibilityRPC(0);
1243 if ( m_Burst != value )
1246 SendBurstRPC(value);
1248 player.GetWeaponManager().SetBurstOption(m_Burst);
1257 if (!m_StaminaDisabled)
1259 SendStaminaRPC(m_StaminaDisabled);
1260 m_StaminaDisabled =
true;
1265 if (m_StaminaDisabled)
1267 SendStaminaRPC(m_StaminaDisabled);
1268 m_StaminaDisabled =
false;
1274 void CheckLogPlayerStats()
1278 if (!m_LogPlayerStats)
1280 SendLogPlayerStatsRPC(
true);
1281 m_LogPlayerStats =
true;
1286 if (m_LogPlayerStats)
1288 SendLogPlayerStatsRPC(
false);
1289 m_LogPlayerStats =
false;
1295 void CheckSoftSkillsDebug()
1302 if (!m_SoftSkillsDebug)
1305 player.GetSoftSkillsManager().CreateDebugWindow(
true );
1306 SoftSkillsShowDebugRPC(
true);
1307 m_SoftSkillsDebug =
true;
1312 if (m_SoftSkillsDebug)
1315 player.GetSoftSkillsManager().CreateDebugWindow(
false );
1316 SoftSkillsShowDebugRPC(
false);
1317 m_SoftSkillsDebug =
false;
1323 void CheckSoftSkillsState()
1327 if (!m_SoftSkillsState)
1329 SoftSkillsToggleStateRPC(
true);
1330 m_SoftSkillsState =
true;
1335 if (m_SoftSkillsState)
1337 SoftSkillsToggleStateRPC(
false);
1338 m_SoftSkillsState =
false;
1344 void CheckGunParticles()
1348 if (!m_GunParticlesState)
1350 GunParticlesToggleStateRPC(
false);
1351 m_GunParticlesState =
true;
1356 if (m_GunParticlesState)
1358 GunParticlesToggleStateRPC(
true);
1359 m_GunParticlesState =
false;
1365 void CheckSoftSkillsModel()
1369 if (!m_SoftSkillsModel)
1371 SoftSkillsToggleModelRPC(
true);
1372 m_SoftSkillsModel =
true;
1377 if (m_SoftSkillsModel)
1379 SoftSkillsToggleModelRPC(
false);
1380 m_SoftSkillsModel =
false;
1386 void CheckSpecialtyLevel()
1388 float specialty_value =
DiagMenu.GetRangeValue(
DiagMenuIDs.DM_SOFT_SKILLS_SPECIALTY_VALUE );
1390 if ( m_SpecialtyLevel != specialty_value )
1392 SoftSkillsSetSpecialtyRPC( specialty_value );
1393 m_SpecialtyLevel = specialty_value;
1398 void CheckActivateBleedingSource()
1402 if ( bleeding_source != m_BleedingSourceRequested )
1404 SendActivateBleedingSource(bleeding_source);
1405 m_BleedingSourceRequested = bleeding_source;
1410 void CheckActivateBleedingSourceLevel()
1414 if (source_level != m_BleedingSourceLevelRequested)
1422 if (source_level != 0)
1425 switch (source_level)
1428 bone =
"lefttoebase";
1440 for (
int i = 0; i < mgr.m_BleedingSourceZone.Count(); i++)
1442 if (mgr.m_BleedingSourceZone.GetKey(i) == bone)
1449 SendActivateBleedingSource(idx);
1451 m_BleedingSourceLevelRequested = source_level;
1456 void CheckBloodyHands()
1462 LifespanBloodyHandsRPC(
true);
1470 LifespanBloodyHandsRPC(
false);
1477 void CheckLifeSpanPlaytimeUpdate()
1479 float lifespan_level =
DiagMenu.GetRangeValue(
DiagMenuIDs.DM_LIFESPAN_PLAYTIME_UPDATE ) * 60;
1481 if ( m_LifespanLevel != lifespan_level )
1483 LifespanPlaytimeUpdateRPC( lifespan_level );
1484 m_LifespanLevel = lifespan_level;
1488 void CheckPermanentCrossHairUpdate()
1490 PluginPermanentCrossHair crosshair;
1493 if (!m_PermanentCrossHair)
1496 crosshair.SwitchPermanentCrossHair(
true);
1497 m_PermanentCrossHair =
true;
1502 if (m_PermanentCrossHair)
1505 crosshair.SwitchPermanentCrossHair(
false);
1506 m_PermanentCrossHair =
false;
1512 void CheckVehicleGetOutBox()
1516 if (m_VehicleFreeAreaBox)
1518 m_VehicleFreeAreaBox.Destroy();
1519 m_VehicleFreeAreaBox =
null;
1525 m_VehicleFreeAreaBox = hcv.GetTransport().DebugFreeAreaAtDoor( hcv.GetVehicleSeat() );
1527 else if (m_VehicleFreeAreaBox)
1529 m_VehicleFreeAreaBox.Destroy();
1530 m_VehicleFreeAreaBox =
null;
1535 void CheckToggleHud()
1543 hud =
GetGame().GetMission().GetHud();
1544 hud.Show( m_ToggleHud );
1545 GetGame().GetMission().HideCrosshairVisibility();
1553 hud =
GetGame().GetMission().GetHud();
1554 hud.Show( m_ToggleHud );
1555 GetGame().GetMission().RefreshCrosshairVisibility();
1556 m_ToggleHud =
false;
1562 void CheckShowWeaponDebug()
1567 if (!m_ShowingWeaponDebug)
1571 player.ShowWeaponDebug(
true);
1572 m_ShowingWeaponDebug =
true;
1577 if (m_ShowingWeaponDebug)
1580 player.ShowWeaponDebug(
false);
1581 m_ShowingWeaponDebug =
false;
1586 void CheckProceduralRecoil()
1591 if (!m_ProceduralRecoilEnabled)
1595 SendProceduralRecoilRPC(
true);
1596 m_ProceduralRecoilEnabled =
true;
1601 if (m_ProceduralRecoilEnabled)
1605 SendProceduralRecoilRPC(
false);
1606 m_ProceduralRecoilEnabled =
false;
1611 void CheckQuickRestrain()
1616 if (!m_EnableQuickRestrain)
1618 SendEnableQuickRestrainRPC(
true);
1619 m_EnableQuickRestrain =
true;
1624 if (m_EnableQuickRestrain)
1626 SendEnableQuickRestrainRPC(
false);
1627 m_EnableQuickRestrain =
false;
1633 void CheckQuickFishing()
1638 if (!m_EnableQuickFishing)
1640 SendEnableQuickFishingRPC(
true);
1641 m_EnableQuickFishing =
true;
1646 if (m_EnableQuickFishing)
1648 SendEnableQuickFishingRPC(
false);
1649 m_EnableQuickFishing =
false;
1656 void CheckCamShake()
1660 GetGame().GetPlayer().GetCurrentCamera().SpawnCameraShake(1,1,15,4);
1667 void CheckAimNoise()
1672 if (!m_AimNoiseEnabled)
1676 player.GetAimingModel().SetAimNoiseAllowed(
true);
1677 m_AimNoiseEnabled =
true;
1682 if (m_AimNoiseEnabled)
1685 player.GetAimingModel().SetAimNoiseAllowed(
false);
1686 m_AimNoiseEnabled =
false;
1692 void CheckDayzPlayerMenu()
1696 if (actMenuValue != m_DayzPlayerDebugMenu)
1704 pd.ToggleDebugWindowSetMode(actMenuValue);
1708 m_DayzPlayerDebugMenu = actMenuValue;
1714 void CheckDisplayMenu()
1716 PluginRemotePlayerDebugClient plugin_remote_client;
1721 if ( m_DisplayPlayerInfo != value )
1723 plugin_remote_client = PluginRemotePlayerDebugClient.Cast(
GetPlugin(PluginRemotePlayerDebugClient) );
1726 m_DisplayPlayerInfo = value;
1731 if ( m_DisplayPlayerInfo != 0 )
1733 plugin_remote_client = PluginRemotePlayerDebugClient.Cast(
GetPlugin(PluginRemotePlayerDebugClient) );
1736 m_DisplayPlayerInfo = 0;
1741 void CheckUniversalTemperatureSources()
1743 PluginUniversalTemperatureSourceClient client;
1746 if (m_EnableUniversalTemperatureSources != value)
1748 client = PluginUniversalTemperatureSourceClient.Cast(
GetPlugin(PluginUniversalTemperatureSourceClient));
1751 m_EnableUniversalTemperatureSources = value;
1755 void CheckEnvironmentStats()
1759 if (!m_EnvironmentStats)
1760 m_EnvironmentStats =
true;
1764 if (m_EnvironmentStats)
1765 m_EnvironmentStats =
false;
1769 void CheckDrawCheckerboard()
1773 if (!m_DrawCheckerboard) m_DrawCheckerboard =
true;
1777 if (m_DrawCheckerboard) m_DrawCheckerboard =
false;
1781 void CheckPresenceNotifierDebug()
1785 if (!m_PresenceNotifierDebug) m_PresenceNotifierDebug =
true;
1789 if (m_PresenceNotifierDebug) m_PresenceNotifierDebug =
false;
1794 void CheckSimulateNULLPointer()
1798 SendSimulateNULLPointer();
1803 void CheckSimulateDivisionByZero()
1807 SendSimulateDivisionByZero();
1812 void CheckSimulateInfiniteLoop()
1816 SendSimulateInfiniteLoop();
1821 void CheckSimulateErrorFunction()
1825 SendSimulateErrorFunction();
1830 void CheckDoActionLogs()
1834 if ( !m_DoActionLogs )
1836 SendSetActionLogs(
true);
1838 m_DoActionLogs =
true;
1843 if ( m_DoActionLogs )
1845 SendSetActionLogs(
false);
1847 m_DoActionLogs =
false;
1852 void CheckDoWeaponLogs()
1856 if ( !m_DoActionLogs )
1858 SendSetWeaponLogs(
true);
1860 m_DoWeaponLogs =
true;
1865 if ( m_DoActionLogs )
1867 SendSetWeaponLogs(
false);
1869 m_DoWeaponLogs =
false;
1874 void CheckDoInventoryLogs()
1878 if ( !m_DoInventoryMoveLogs )
1880 SendSetInventoryMoveLogs(
true);
1882 m_DoInventoryMoveLogs =
true;
1887 if ( m_DoInventoryMoveLogs )
1889 SendSetInventoryMoveLogs(
false);
1891 m_DoInventoryMoveLogs =
false;
1896 if ( !m_DoInventoryReservationLogs )
1898 SendSetInventoryReservationLogs(
true);
1899 LogManager.InventoryReservationLogEnable(
true);
1900 m_DoInventoryReservationLogs =
true;
1905 if ( m_DoInventoryReservationLogs )
1907 SendSetInventoryReservationLogs(
false);
1908 LogManager.InventoryReservationLogEnable(
false);
1909 m_DoInventoryReservationLogs =
false;
1914 if ( !m_DoInventoryHFSMLogs )
1916 SendSetInventoryHFSMLogs(
true);
1918 m_DoInventoryHFSMLogs =
true;
1923 if ( m_DoInventoryHFSMLogs )
1925 SendSetInventoryHFSMLogs(
false);
1927 m_DoInventoryHFSMLogs =
false;
1932 void CheckDoSymptomLogs()
1936 if ( !m_DoSymptomLogs )
1938 SendSetSymptomLogs(
true);
1940 m_DoSymptomLogs =
true;
1945 if ( m_DoSymptomLogs )
1947 SendSetSymptomLogs(
false);
1949 m_DoSymptomLogs =
false;
1954 bool m_Active =
false;
1955 void CheckPlugArrows()
1959 if ( m_Active ==
false )
1961 for (
int i = 0; i <
GetGame().m_EnergyManagerArray.Count(); i++)
1963 if (
GetGame().m_EnergyManagerArray[i] )
1971 for (
int j = 0; j <
GetGame().m_EnergyManagerArray.Count(); j++)
1973 if (
GetGame().m_EnergyManagerArray[j] )
1981 void SendDebugActionsRPC()
1989 void SendEnableQuickRestrainRPC(
bool enable)
1993 if (player) player.SetQuickRestrain(enable);
1999 void SendEnableQuickFishingRPC(
bool enable)
2003 if (player) player.SetQuickFishing(enable);
2009 void SendProceduralRecoilRPC(
bool enable)
2013 if (player) player.GetAimingModel().SetProceduralRecoilEnabled(enable);
2019 void SendActivateAllBSRPC()
2025 void SendKillPlayerRPC()
2031 void SendInvincibilityRPC(
int level)
2038 void SendStaminaRPC(
bool value)
2047 void SendTargetabilityRPC(
bool value)
2054 void SendBurstRPC(
int opt)
2061 void SendLogPlayerStatsRPC(
bool enable)
2068 void SendModifiersRPC(
bool enable)
2075 void SendInventoryAccessRPC(
bool enable)
2083 void SendUnlimitedRPC(
bool enable)
2090 void SendDisableBloodLossRPC(
bool enable)
2097 void SendDebugCraftingRPC(
bool enable)
2104 void SendBuildWoodRPC(
bool enable)
2111 void SendBuildGateRPC(
bool enable)
2118 void SoftSkillsShowDebugRPC(
bool enable)
2125 void SoftSkillsToggleStateRPC(
bool enable)
2132 void GunParticlesToggleStateRPC(
bool enable)
2139 void SoftSkillsToggleModelRPC(
bool enable)
2146 void SoftSkillsSetSpecialtyRPC(
float specialty_value )
2153 void LifespanBloodyHandsRPC(
bool enable)
2160 void LifespanPlaytimeUpdateRPC(
float playtime )
2167 void SendMeleeBlockStanceRPC(
bool enable)
2174 void SendMeleeFightRPC(
bool enable)
2181 void SendGoUnconsciousRPC(
bool is_delayed)
2183 Param1<bool> p1 =
new Param1<bool>(is_delayed);
2188 void SendSimulateNULLPointer()
2193 void SendSimulateDivisionByZero()
2199 void SendSimulateInfiniteLoop()
2205 void SendSimulateErrorFunction()
2211 void SendActivateBleedingSource(
int bleeding_source)
2213 Param1<int> p1 =
new Param1<int>(bleeding_source);
2218 void SendSetHairLevelRPC()
2224 void SendSetHairLevelHideRPC(
int level,
bool value)
2231 void SendSetActionLogs(
bool enable)
2233 Param1<bool> p1 =
new Param1<bool>(enable);
2238 void SendSetWeaponLogs(
bool enable)
2240 Param1<bool> p1 =
new Param1<bool>(enable);
2245 void SendSetSymptomLogs(
bool enable)
2247 Param1<bool> p1 =
new Param1<bool>(enable);
2252 void SendSetInventoryMoveLogs(
bool enable)
2254 Param1<bool> p1 =
new Param1<bool>(enable);
2259 void SendSetInventoryReservationLogs(
bool enable)
2261 Param1<bool> p1 =
new Param1<bool>(enable);
2266 void SendSetInventoryHFSMLogs(
bool enable)
2268 Param1<bool> p1 =
new Param1<bool>(enable);
2273 void SendForceFinisherType(
int value)
2275 Param1<int> p1 =
new Param1<int>(value);
2280 void SendTimeAccel(
Param param)
2293 case ERPCs.DEV_SIMULATE_NULL_POINTER:
2295 NULL_player.SetHealth(
"",
"", -1);
2298 case ERPCs.DEV_SIMULATE_DIVISION_BY_ZERO:
2300 int division_by_zero = 1/zero;
2303 case ERPCs.DEV_SIMULATE_INFINITE_LOOP:
2306 Print(
"simulated infinite loop");
2310 case ERPCs.DEV_SIMULATE_ERROR_FUNCTION:
2311 Error(
"Simulated error");
2314 case ERPCs.DEV_DIAGMENU_SUBSCRIBE:
2318 int currentMask = m_Subscribers.Get(player);
2320 if (newMask != currentMask)
2324 m_Subscribers.Remove(player);
2328 m_Subscribers.Set(player, newMask);
2335 case ERPCs.DEV_ACTIVATE_BS:
2337 player.GetBleedingManagerServer().DebugActivateBleedingSource(
CachedObjectsParams.PARAM1_INT.param1);
2340 case ERPCs.DEV_RPC_UNLIMITED_AMMO:
2353 case ERPCs.RPC_DISABLE_MODIFIERS:
2356 player.SetModifiers( enable );
2359 case ERPCs.DEV_RPC_DISABLE_BLOODLOOS:
2364 case ERPCs.RPC_KILL_PLAYER:
2365 player.SetHealth(
"",
"", -1);
2368 case ERPCs.DEV_ACTIVATE_ALL_BS:
2369 player.GetBleedingManagerServer().ActivateAllBS();
2372 case ERPCs.RPC_ENABLE_INVINCIBILITY:
2377 player.SetAllowDamage(
true);
2378 player.SetCanBeDestroyed(
true);
2380 else if (level == 1)
2382 player.SetAllowDamage(
true);
2383 player.SetCanBeDestroyed(
false);
2385 else if (level == 2)
2387 player.SetAllowDamage(
false);
2391 case ERPCs.DEV_RPC_STAMINA_TOGGLE:
2394 player.SetStaminaEnabled(staminaState);
2397 case ERPCs.DEV_RPC_TOGGLE_TARGETABLE:
2400 player.m_CanBeTargetedDebug = value;
2403 case ERPCs.RPC_BURST_OPT:
2406 player.GetWeaponManager().SetBurstOption(opt);
2409 case ERPCs.RPC_ITEM_DEBUG_ACTIONS:
2412 ItemBase.SetDebugActionsMask(mask);
2415 case ERPCs.RPC_WEAPON_PROC_RECOIL:
2418 player.GetAimingModel().SetProceduralRecoilEnabled(enable);
2421 case ERPCs.RPC_ENABLE_QUICK_RESTRAIN:
2424 player.SetQuickRestrain(enable);
2427 case ERPCs.RPC_ENABLE_QUICK_FISHING:
2430 player.SetQuickFishing(enable);
2433 case ERPCs.RPC_LOG_PLAYER_STATS:
2438 case ERPCs.RPC_SOFT_SKILLS_TOGGLE_STATE:
2443 case ERPCs.RPC_SOFT_SKILLS_DEBUG_WINDOW:
2449 player.GetSoftSkillsManager().StartSynchTimer();
2453 player.GetSoftSkillsManager().StopSynchTimer();
2454 player.GetSoftSkillsManager().ResetDebugWindow();
2459 case ERPCs.RPC_GUN_PARTICLES_TOGGLE:
2464 case ERPCs.RPC_CRAFTING_DEBUG:
2466 PluginRecipesManager plugin_recipes_manager;
2467 Class.CastTo(plugin_recipes_manager,
GetPlugin(PluginRecipesManager));
2471 case ERPCs.RPC_SOFT_SKILLS_TOGGLE_MODEL:
2476 case ERPCs.RPC_SOFT_SKILLS_SET_SPECIALTY:
2480 soft_skill_manager.SetSpecialtyLevel( specialty );
2481 soft_skill_manager.SynchSpecialtyLevel();
2482 player.GetStatSpecialty().Set( specialty );
2485 case ERPCs.RPC_LIFESPAN_BLOODY_HANDS:
2490 lifespan_bloody_hands.UpdateBloodyHandsVisibility( player, enable );
2493 case ERPCs.RPC_LIFESPAN_PLAYTIME_UPDATE:
2496 float playtime = player.StatGet(
"playtime");
2497 float opposite_playtime = playtime * ( -1 );
2498 player.StatUpdate(
"playtime", opposite_playtime );
2501 player.StatUpdate(
"playtime", playtime_update );
2502 player.SetLastShavedSeconds( 0 );
2506 module_lifespan_update.UpdateLifespan( player,
true );
2507 module_lifespan_update.ChangeFakePlaytime( player, playtime_update );
2510 case ERPCs.DEV_GO_UNCONSCIOUS:
2514 GoUnconscious(player);
2522 case ERPCs.DEV_HAIR_LEVEL_HIDE:
2525 player.UpdateHairSelectionVisibility(
true);
2528 case ERPCs.RPC_DO_ACTION_LOGS:
2533 case ERPCs.RPC_DO_WEAPON_LOGS:
2538 case ERPCs.RPC_DO_SYMPTOMS_LOGS:
2543 case ERPCs.RPC_DO_INV_MOVE_LOGS:
2548 case ERPCs.RPC_DO_INV_RESERVATION_LOGS:
2553 case ERPCs.RPC_DO_INV_HFSM_LOGS:
2557 case ERPCs.DEV_RPC_ITEMS_FIX:
2559 player.FixAllInventoryItems();
2561 case ERPCs.DEV_RPC_FORCE_FINISHER:
2563 player.GetMeleeCombat().DebugSetForcedFinisherType(
CachedObjectsParams.PARAM1_INT.param1);
2565 case ERPCs.RPC_BUILD_GATE:
2569 case ERPCs.RPC_BUILD_WOOD:
2573 case ERPCs.DEV_TIME_ACCEL:
2575 TimeAccelParam tap =
new TimeAccelParam(
false,0,0);
2579 FeatureTimeAccel.m_CurrentTimeAccel = tap;
2600 if (player.IsUnconscious())
2602 player.SetHealth(
"",
"Shock",100);
2606 player.m_UnconsciousEndTime = -60;
2607 player.SetHealth(
"",
"Shock",0);
2611 bool AreTimeAccelParamsSame(TimeAccelParam p1, TimeAccelParam p2)
2613 if (p1.param1 != p2.param1)
2615 if (p1.param2 != p2.param2)
2617 if (p1.param3 != p2.param3)
2622 static void EnableDebugSystemClient(ESubscriberSystems system,
bool enable)
2627 mask = (m_SystemsMaks | system);
2631 mask = ((~system) & m_SystemsMaks);
2634 if (mask != m_SystemsMaks)
2637 m_SystemsMaks = mask;
2641 static void SendDataToSubscribersServer(
Object target, ESubscriberSystems system,
int rpc_type,
Param data,
bool guaranteed =
true)
2643 for (
int i = 0; i < m_Subscribers.Count(); i++)
2645 Man man = m_Subscribers.GetKey(i);
2648 int subscribedSystems = m_Subscribers.Get(man);
2649 if (system & subscribedSystems)
2651 GetGame().RPCSingleParam( target, rpc_type, data, guaranteed , man.GetIdentity() );
2656 m_Subscribers.RemoveElement(i);
2664 int GetTimeAccelBitmask()
2667 WriteCategoryBit(bitmask,
DiagMenuIDs.DM_FEATURE_TIME_ACCEL_UG_ENTRANCES, ETimeAccelCategories.UNDERGROUND_ENTRANCE);
2668 WriteCategoryBit(bitmask,
DiagMenuIDs.DM_FEATURE_TIME_ACCEL_UG_RESERVOIR, ETimeAccelCategories.UNDERGROUND_RESERVOIR);
2669 WriteCategoryBit(bitmask,
DiagMenuIDs.DM_FEATURE_TIME_ACCEL_ENERGY_CONSUME, ETimeAccelCategories.ENERGY_CONSUMPTION);
2670 WriteCategoryBit(bitmask,
DiagMenuIDs.DM_FEATURE_TIME_ACCEL_ENERGY_RECHARGE, ETimeAccelCategories.ENERGY_RECHARGE);
2674 void WriteCategoryBit(out
int bitmask,
int diagMenuID, ETimeAccelCategories category)
2678 bitmask = bitmask | category;