Page MenuHomeFeedback Tracker

[Bug] [QoL] Allow console in singleplayer again
Closed, ResolvedPublic

Description

p:\a3\functions_f\debug\fn_isdebugconsoleallowed.sqf has only these checks for SP but lacks the enableDebugConsole value check

// == SP MODE ==

if (!isMultiplayer) exitWith
{ 
    allDisplays find findDisplay 313 in [0, 1] // 3DEN preview
    ||
    {allDisplays find findDisplay 26 in [0, 1]} // 2DEN
    ||
    {(configFile >> "enableDebugConsole") call {isArray _this || {isNumber _this && {getNumber _this >= 1}}}} // allowed by mod
};

The mission specific parameter (enableDebugConsole in desc.ext) not taken into account for SP. The check is done below but just for MP.

Wiki mentions also use for SP: https://community.bistudio.com/wiki/Arma_3:_Debug_Console#Configuration

T128695#1728561 claims it was done "by design". This doesnt make any sense.

As result you are forced to do testing via Eden, or need a config mod to enable the console globally.


Prior to a refactor the console was also available in SP:

_allowDebugConsole = if (isnil "_allowDebugConsole") then {false} else {_allowDebugConsole};
_enableDebugConsole = ["DebugConsole",getMissionConfigValue ["enableDebugConsole",0]] call bis_fnc_getParamValue;

if (
	//--- Editor
	(((alldisplays find (finddisplay 26) in [0,1]) || (alldisplays find (finddisplay 313) in [0,1])) && !ismultiplayer)
	||
	//--- In mission with enableDebugConsole entry set to 1 (only for host/admin)
	{(_enableDebugConsole == 1 && (isserver || serverCommandAvailable "#shutdown"))}
	||
	//--- In mission with enableDebugConsole entry set to 2 (for everyone)
	{(_enableDebugConsole == 2)}
	||
	//--- Allowed by script
	{_allowDebugConsole}
	//||
	//--- Dev version
	//cheatsEnabled
) then {

Details

Severity
None
Resolution
Open
Reproducibility
N/A
Operating System
Windows 10 x64
Category
Design-Mission
Steps To Reproduce

enableDebugConsole in A3 data

couple of sqm from A3 content have the property but all set to 0

class CustomAttributes
{
	class Category0
	{
		name = "Scenario";
		class Attribute0
		{
			property = "EnableDebugConsole";
			expression = "true";
			class Value
			{
				class data
				{
					class type
					{
						type[] = {"SCALAR"};
					};
					value = 0;
				};
			};
		};
		nAttributes = 1;
	};
};

only Oldman would be likely affected as it has

enableDebugConsole = 2;

in p:\a3\missions_f_oldman\systems\commondescription.inc

p:\a3\missions_f_exp\campaign\cutscenes\cs_viper_forest.tanoa\mission.sqm
220 			property = "EnableDebugConsole";

p:\a3\missions_f_exp\campaign\missions\exp_m01.tanoa\mission.sqm
488 			property = "EnableDebugConsole";

p:\a3\missions_f_exp\campaign\missions\exp_m02.tanoa\mission.sqm
437 			property = "EnableDebugConsole";

p:\a3\missions_f_exp\campaign\missions\exp_m03.tanoa\mission.sqm
488 			property = "EnableDebugConsole";

p:\a3\missions_f_exp\campaign\missions\exp_m04.tanoa\mission.sqm
465 			property = "EnableDebugConsole";

p:\a3\missions_f_exp\campaign\missions\exp_m05.tanoa\mission.sqm
472 			property = "EnableDebugConsole";

p:\a3\missions_f_exp\campaign\missions\exp_m06.tanoa\mission.sqm
552 			property = "EnableDebugConsole";

p:\a3\missions_f_exp\campaign\missions\exp_m07.tanoa\mission.sqm
486 			property = "EnableDebugConsole";

p:\a3\missions_f_exp\mpscenarios\mp_end_game_04.tanoa\mission.sqm
374 			property = "EnableDebugConsole";

p:\a3\missions_f_exp\mpscenarios\mp_end_game_05.tanoa\mission.sqm
508 			property = "EnableDebugConsole";

p:\a3\missions_f_exp\mpscenarios\mp_escapefromtanoa.tanoa\mission.sqm
383 			property = "EnableDebugConsole";

p:\a3\missions_f_exp\showcases\showcase_endgame.tanoa\mission.sqm
241 			property = "EnableDebugConsole";

p:\a3\missions_f_exp_a\mpscenarios\mp_end_game_02.altis\mission.sqm
460 			property="EnableDebugConsole";

p:\a3\missions_f_exp_a\mpscenarios\mp_end_game_03.altis\mission.sqm
450 			property="EnableDebugConsole";

p:\a3\missions_f_gamma\showcases\faction_blufor.altis\mission.sqm
315 			property="EnableDebugConsole";

p:\a3\missions_f_gamma\showcases\faction_independent.altis\mission.sqm
219 			property="EnableDebugConsole";

p:\a3\missions_f_jets\showcases\showcase_jets.altis\mission.sqm
241 			property = "EnableDebugConsole";

p:\a3\missions_f_oldman\campaign\missions\oldman.tanoa\mission.sqm
108 			property = "EnableDebugConsole";

p:\a3\missions_f_oldman\systems\commondescription.inc
19 enableDebugConsole = 2;

p:\a3\missions_f_patrol\mpscenarios\mp_combatpatrol_01.altis\mission.sqm
321 			property="EnableDebugConsole";

p:\a3\missions_f_patrol\mpscenarios\mp_combatpatrol_02.stratis\mission.sqm
302 			property="EnableDebugConsole";

p:\a3\missions_f_patrol\mpscenarios\mp_combatpatrol_03.tanoa\mission.sqm
302 			property="EnableDebugConsole";

p:\a3\missions_f_patrol\mpscenarios\mp_combatpatrol_04.malden\mission.sqm
302 			property="EnableDebugConsole";
Additional Information

https://forums.bohemia.net/forums/topic/217185-enabledebugconsole-doesnt-work/
https://forums.bohemia.net/forums/topic/229471-enable-debug-console-in-custom-missioncampaign-for-creator-not-players/
https://forums.bohemia.net/forums/topic/241962-cba-debug-console-in-sp/

T79545 - Debug console is not available during intro/outro
T66109 - Debug Console - watch fields continue to evaluate (execute) indefinitely while Arma 3 does not have focus
T66114 - Debug Console - watch fields evaluate (execute) very frequently

Event Timeline

BIS_fnc_KK set Ref Ticket to AIII-56168.Jan 2 2024, 5:46 PM
BIS_fnc_KK claimed this task.
kju-PvPscene updated the task description. (Show Details)Jan 2 2024, 5:53 PM
kju-PvPscene edited Steps To Reproduce. (Show Details)
kju-PvPscene changed Category from General to Design-Mission.
kju-PvPscene edited Steps To Reproduce. (Show Details)
kju-PvPscene edited Steps To Reproduce. (Show Details)

Should work after some future dev build

BIS_fnc_KK removed BIS_fnc_KK as the assignee of this task.Jan 9 2024, 10:26 PM
BIS_fnc_KK changed the task status from New to Feedback.
BIS_fnc_KK added a subscriber: BIS_fnc_KK.
kju-PvPscene closed this task as Resolved.Feb 14 2024, 8:29 PM
kju-PvPscene claimed this task.

works 👏