Jump to content

[Release] Custom Debug Monitor


Recommended Posts

Working great! I had to merge your ''dayz_spaceInterrupt'' with the one I already used with Snap_Pro. Also edited the file for my needs

 

debug.png

 

added player name

added survided x days count

removed server restart

added ''spaces'' before and after values so they dont look too tight in the debug box

 

This is my debug_monitor.sqf if someone want something similar.

while {debugMonitor} do
{
	_time = (round(180-(serverTime)/60));
	_hours = (floor(_time/60));
	_minutes = (_time - (_hours * 60));
	
	switch(_minutes) do
	{
		case 9: {_minutes = "09"};
		case 8: {_minutes = "08"};
		case 7: {_minutes = "07"};
		case 6: {_minutes = "06"};
		case 5: {_minutes = "05"};
		case 4: {_minutes = "04"};
		case 3: {_minutes = "03"};
		case 2: {_minutes = "02"};
		case 1: {_minutes = "01"};
		case 0: {_minutes = "00"};
	};
	
	// You can delete the server website here line (entire line) if you want
	// You can also delete the entire TeamSpeak IP line if you want
	hintSilent parseText format ["
		<t size='0.95' font='Bitstream' align='left' color='#FFBF00'></t><t size='0.95 'font='Bitstream' align='right'></t><br/>
		<t size='1.25' font='Bitstream' align='center' color='#5882FA'>Les Poulets Du Quebec</t><br/>
		<t size='0.95' font='Bitstream' align='left' color='#FFBF00'></t><t size='0.95 'font='Bitstream' align='right'></t><br/>
		<t size='1.15' font='Bitstream' align='center' color='#FFBF00'>%11</t><br/>
		<t size='1.15' font='Bitstream' align='center' color='#FFBF00'>Survived %2 Days</t><br/>
		<t size='0.95' font='Bitstream' align='left' color='#FFBF00'></t><t size='0.95 'font='Bitstream' align='right'></t><br/>
		<t size='1.0' font='Bitstream' align='left' color='#FFBF00'>  Players Online: </t><t size='0.95 'font='Bitstream' align='right'>%1  </t><br/>
		<t size='1.0' font='Bitstream' align='left' color='#FFBF00'>  Murders: </t><t size='0.95' font='Bitstream' align='right'>%4  </t><br/>
		<t size='1.0' font='Bitstream' align='left' color='#FFBF00'>  Bandits Killed: </t><t size='0.95' font='Bitstream' align='right'>%5  </t><br/>
		<t size='1.0' font='Bitstream' align='left' color='#FFBF00'>  Zombies Killed: </t><t size='0.95' font='Bitstream' align='right'>%3  </t><br/>
		<t size='1.0' font='Bitstream' align='left' color='#FFBF00'>  Humanity: </t><t size='0.95' font='Bitstream' align='right'>%7  </t><br/>
		<t size='1.0' font='Bitstream' align='left' color='#FFBF00'>  Blood: </t><t size='0.95' font='Bitstream' align='right'>%6  </t><br/>
		<t size='1.0' font='Bitstream' align='left' color='#FFBF00'>  FPS: </t><t size='0.95' font='Bitstream' align='right'>%8  </t><br/>
		<t size='0.95' font='Bitstream' align='left' color='#FFBF00'> </t><t size='0.95 'font='Bitstream' align='right'></t><br/>
		<t size='1.15' font='Bitstream'align='center' color='#5882FA'>TeamSpeak : ts52.gamespeak.com:9117</t><br/>
		<t size='0.95' font='Bitstream' align='left' color='#FFBF00'></t><t size='0.95 'font='Bitstream' align='right'></t><br/>",
		//<t size='1.15' font='Bitstream'align='center' color='#5882FA'>Server restart in %9:%10</t><br/>",
			
		(count playableUnits),
		(dayz_Survived),
		(player getVariable['zombieKills', 0]),
		(player getVariable['humanKills', 0]),
		(player getVariable['banditKills', 0]),
		(player getVariable['USEC_BloodQty', r_player_blood]),
		(player getVariable['humanity', 0]),
		(round diag_fps),
		_hours,
		_minutes,
		(name player)
	];
	
	//Don't modify below this line
	sleep 1;
}; 

 

If you have the same issue I had (Snap_Build using the same file ''dayz_spaceInterrupt'') Simply edit the file you already use in snap build folder.

Find :

if (_dikCode == 210) then 
{ 
    _nill = execvm "\z\addons\dayz_code\actions\playerstats.sqf";
};

And change it to :

//if (_dikCode == 210) then { _nill = execvm "\z\addons\dayz_code\actions\playerstats.sqf";}; //original debug
// Debug monitor
if (_dikCode == 210) then {
	if (isNil 'debugMonitor') then {
		debugMonitor = true;
		_nill = execvm "custom\debug_monitor.sqf";
	} else {
		debugMonitor = !debugMonitor;
		hintSilent '';
		_nill = execvm "custom\debug_monitor.sqf";
	};
};
Link to comment
Share on other sites

  • 1 month later...

Hi, Nox!

Thanx for tor this debug, was using it for a couple months.

Now i have my own with "StructuredText", and it don't turn off like "Hint" do.

How can i make it work?

 

That is pretty nice. I planned on making one like that but my modding has come to a serious slow due to classes.

You need to modify the space interupt. Take a look at mine.

Link to comment
Share on other sites

You need to modify the space interupt. Take a look at mine.

Well, i did exactly as you explained in your tutorial, and when i changed command to "hintSilent", than ON/OFF switch worked just fine. Of course, debug monitor got shrinked and has that ugly brown background. And if i'm changing to "ctrlSetStructuredText" back again, it becomes an eyecandy, but solid like rock.

Need to get ability to turn this freaking thing off...

Link to comment
Share on other sites

Well, i did exactly as you explained in your tutorial, and when i changed command to "hintSilent", than ON/OFF switch worked just fine. Of course, debug monitor got shrinked and has that ugly brown background. And if i'm changing to "ctrlSetStructuredText" back again, it becomes an eyecandy, but solid like rock.

Need to get ability to turn this freaking thing off...

 

If you send me the interrupt I can take a look to see what I can do if I have some extra time

Link to comment
Share on other sites

If you send me the interrupt I can take a look to see what I can do if I have some extra time

What's the point, if it's similar to yours? :)

 

As i said, the problem is in debug_monitor.sqf, specifically in StructuredText class. I guess it's just CAN'T be toggled off the way Hint class can.

 

Here's my script (well not mine actually, but anyways):

//disableSerialization;

while {debugMonitor} do
{
	//1000 cutRsc ["AsReMixhud","PLAIN"];

	//_wpui = uiNameSpace getVariable "AsReMixhud";
	//_vitals = _wpui displayCtrl 4900;
	_Player = player;

	Players		=	(count playableUnits);
	Money		=	_Player getVariable["cashMoney",0];
	Bank_Balance	=	_Player getVariable["bankMoney",0];
	Humanity	=	_Player getVariable["humanity",0];
	Civilian_Kills	=	_Player getVariable["humanKills",0];
	Bandit_Kills	=	_Player getVariable["banditKills",0];
	Hero_Kills	=	_Player getVariable["heroKills",0];
	ZombieKills	=	_Player getVariable["zombieKills",0];
	Blood		=	_Player getVariable["USEC_BloodQty",12000];

	_stime = 0;
	if(serverTime > 36000)then{_stime = time;}else{_stime = serverTime;};
	_hours = (_stime/60/60);
	_hours = toArray (str _hours);
	_hours resize 1;
	_hours = toString _hours;
	_hours = compile _hours;
	_hours = call  _hours;
	_minutes = floor(_stime/60);
	_minutes2 = ((_minutes - (_hours*60)) min 60) max 0;if (_minutes2 < 10) then {_minutes2 = format ['0%1',_minutes2];};

	if(Humanity >= 5000) then { Humanity_Icon = "<img size='2.0' align='right' image='Hud\icons\HumanityHero.paa'/>"; };
	if((Humanity >= 200) && (Humanity <= 4999)) then { Humanity_Icon = "<img size='2.0' align='right' image='Hud\icons\HumanityCiv.paa'/>"; };
	if(Humanity <= 199) then { Humanity_Icon = "<img size='2.0' align='right' image='Hud\icons\HumanityBandit.paa'/>"; };

	//_vitals ctrlSetStructuredText parseText format
	hintSilent parseText format
	[
		"
		<t size='1.5' color='#56a531' align='right'> mysite.com </t><br/>
		<t size='1.5' color='#56a531' align='right'> %1 </t><img size='2.0' align='right' image='Hud\icons\Players.paa'/><br/>
		<t size='1.5' color='#56a531' align='right'> %2h %3min </t><img size='2.0' align='right' image='Hud\icons\Time.paa'/><br/>
		<t size='1.5' color='#56a531' align='right'> %4 </t><img size='2.0' align='right' image='Hud\icons\Money.paa'/><br/>
		<t size='1.5' color='#56a531' align='right'> %5 </t><img size='2.0' align='right' image='Hud\icons\Bank.paa'/><br/>
		<t size='1.5' color='#56a531' align='right'> %6 </t>%7<br/>
		<t size='1.5' color='#56a531' align='right'> %8 </t><img size='2.0' align='right' image='Hud\icons\KillsCiv.paa'/><br/>
		<t size='1.5' color='#56a531' align='right'> %9 </t><img size='2.0' align='right' image='Hud\icons\KillsBandit.paa'/><br/>
		<t size='1.5' color='#56a531' align='right'> %10 </t><img size='2.0' align='right' image='Hud\icons\KillsHero.paa'/><br/>
		<t size='1.5' color='#56a531' align='right'> %11 </t><img size='2.0' align='right' image='Hud\icons\KillsZombie.paa'/><br/>
		<t size='1.5' color='#56a531' align='right'> Ins </t><img size='2.0' align='right' image='Hud\icons\Toggle.paa'/><br/>
		",
		Players,
		_hours,
		_minutes2,
		[Money] call BIS_fnc_numberText,
		[Bank_Balance] call BIS_fnc_numberText,
		[Humanity] call BIS_fnc_numberText,
		Humanity_Icon,
		Civilian_Kills,
		Bandit_Kills,
		Hero_Kills,
		Zombiekills
	];
	//_vitals ctrlCommit 0;
	sleep 1.5;
};

Original commands are commented out.

Link to comment
Share on other sites

  • 3 months later...

Hello there i have already one works but it have some extra stuff i just want to replace it with your Debug Menu As i am confused to still use it with UEP 

waitUntil{!isNil "UEP_Config"};
diag_log("UEP: Settings Loaded for Debugger");

while {debugMonitor} do
{
	_time = (round(480-(serverTime)/60));
	_hours = (floor(_time/60));
	_minutes = (_time - (_hours * 60));
	
	switch(_minutes) do
	{
		case 9: {_minutes = "09"};
		case 8: {_minutes = "08"};
		case 7: {_minutes = "07"};
		case 6: {_minutes = "06"};
		case 5: {_minutes = "05"};
		case 4: {_minutes = "04"};
		case 3: {_minutes = "03"};
		case 2: {_minutes = "02"};
		case 1: {_minutes = "01"};
		case 0: {_minutes = "00"};
	};
	
	// You can delete the server website here line (entire line) if you want
	// You can also delete the entire TeamSpeak IP line if you want
	hintSilent parseText format ["
		<t size='1.25' font='Bitstream' align='center' color='#5882FA'>%10</t><br/>
		<t size='1.05' font='Bitstream' align='center' color='#5882FA'>%11</t><br/> 
		<t size='0.95' font='Bitstream' align='left' color='#FFBF00'></t><t size='0.95 'font='Bitstream' align='right'></t><br/>
		<t size='0.95' font='Bitstream' align='left' color='#FFBF00'>Players Online: </t><t size='0.95 'font='Bitstream' align='right'>%1</t><br/>
		<t size='0.95' font='Bitstream' align='left' color='#FFBF00'>Murders: </t><t size='0.95' font='Bitstream' align='right'>%3</t><br/>
		<t size='0.95' font='Bitstream' align='left' color='#FFBF00'>Bandits Killed: </t><t size='0.95' font='Bitstream' align='right'>%4</t><br/>
		<t size='0.95' font='Bitstream' align='left' color='#FFBF00'>Zombies Killed: </t><t size='0.95' font='Bitstream' align='right'>%2</t><br/>
		<t size='0.95' font='Bitstream' align='left' color='#FFBF00'>Humanity: </t><t size='0.95' font='Bitstream' align='right'>%6</t><br/>
		<t size='0.95' font='Bitstream' align='left' color='#FFBF00'>Blood: </t><t size='0.95' font='Bitstream' align='right'>%5</t><br/>
		<t size='0.95' font='Bitstream' align='left' color='#FFBF00'>FPS: </t><t size='0.95' font='Bitstream' align='right'>%7</t><br/>
		<t size='0.95' font='Bitstream' align='left' color='#FFBF00'></t><t size='0.95 'font='Bitstream' align='right'></t><br/>
		<t size='1.15' font='Bitstream'align='center' color='#5882FA'>%12</t><br/>
		<t size='1.15' font='Bitstream'align='center' color='#5882FA'>Server restart in %8:%9</t><br/>",
			
		(count playableUnits),
		(player getVariable['zombieKills', 0]),
		(player getVariable['humanKills', 0]),
		(player getVariable['banditKills', 0]),
		(player getVariable['USEC_BloodQty', r_player_blood]),
		(player getVariable['humanity', 0]),
		(round diag_fps),
		_hours,
		_minutes,
		UEP_bugger_1,
		UEP_bugger_2,
		UEP_bugger_3
	];
	
	//Don't modify below this line
	sleep 1;
};
Link to comment
Share on other sites

What's the point, if it's similar to yours? :)

 

As i said, the problem is in debug_monitor.sqf, specifically in StructuredText class. I guess it's just CAN'T be toggled off the way Hint class can.

 

Here's my script (well not mine actually, but anyways):

//disableSerialization;

while {debugMonitor} do
{
	//1000 cutRsc ["AsReMixhud","PLAIN"];

	//_wpui = uiNameSpace getVariable "AsReMixhud";
	//_vitals = _wpui displayCtrl 4900;
	_Player = player;

	Players		=	(count playableUnits);
	Money		=	_Player getVariable["cashMoney",0];
	Bank_Balance	=	_Player getVariable["bankMoney",0];
	Humanity	=	_Player getVariable["humanity",0];
	Civilian_Kills	=	_Player getVariable["humanKills",0];
	Bandit_Kills	=	_Player getVariable["banditKills",0];
	Hero_Kills	=	_Player getVariable["heroKills",0];
	ZombieKills	=	_Player getVariable["zombieKills",0];
	Blood		=	_Player getVariable["USEC_BloodQty",12000];

	_stime = 0;
	if(serverTime > 36000)then{_stime = time;}else{_stime = serverTime;};
	_hours = (_stime/60/60);
	_hours = toArray (str _hours);
	_hours resize 1;
	_hours = toString _hours;
	_hours = compile _hours;
	_hours = call  _hours;
	_minutes = floor(_stime/60);
	_minutes2 = ((_minutes - (_hours*60)) min 60) max 0;if (_minutes2 < 10) then {_minutes2 = format ['0%1',_minutes2];};

	if(Humanity >= 5000) then { Humanity_Icon = "<img size='2.0' align='right' image='Hud\icons\HumanityHero.paa'/>"; };
	if((Humanity >= 200) && (Humanity <= 4999)) then { Humanity_Icon = "<img size='2.0' align='right' image='Hud\icons\HumanityCiv.paa'/>"; };
	if(Humanity <= 199) then { Humanity_Icon = "<img size='2.0' align='right' image='Hud\icons\HumanityBandit.paa'/>"; };

	//_vitals ctrlSetStructuredText parseText format
	hintSilent parseText format
	[
		"
		<t size='1.5' color='#56a531' align='right'> mysite.com </t><br/>
		<t size='1.5' color='#56a531' align='right'> %1 </t><img size='2.0' align='right' image='Hud\icons\Players.paa'/><br/>
		<t size='1.5' color='#56a531' align='right'> %2h %3min </t><img size='2.0' align='right' image='Hud\icons\Time.paa'/><br/>
		<t size='1.5' color='#56a531' align='right'> %4 </t><img size='2.0' align='right' image='Hud\icons\Money.paa'/><br/>
		<t size='1.5' color='#56a531' align='right'> %5 </t><img size='2.0' align='right' image='Hud\icons\Bank.paa'/><br/>
		<t size='1.5' color='#56a531' align='right'> %6 </t>%7<br/>
		<t size='1.5' color='#56a531' align='right'> %8 </t><img size='2.0' align='right' image='Hud\icons\KillsCiv.paa'/><br/>
		<t size='1.5' color='#56a531' align='right'> %9 </t><img size='2.0' align='right' image='Hud\icons\KillsBandit.paa'/><br/>
		<t size='1.5' color='#56a531' align='right'> %10 </t><img size='2.0' align='right' image='Hud\icons\KillsHero.paa'/><br/>
		<t size='1.5' color='#56a531' align='right'> %11 </t><img size='2.0' align='right' image='Hud\icons\KillsZombie.paa'/><br/>
		<t size='1.5' color='#56a531' align='right'> Ins </t><img size='2.0' align='right' image='Hud\icons\Toggle.paa'/><br/>
		",
		Players,
		_hours,
		_minutes2,
		[Money] call BIS_fnc_numberText,
		[Bank_Balance] call BIS_fnc_numberText,
		[Humanity] call BIS_fnc_numberText,
		Humanity_Icon,
		Civilian_Kills,
		Bandit_Kills,
		Hero_Kills,
		Zombiekills
	];
	//_vitals ctrlCommit 0;
	sleep 1.5;
};

Original commands are commented out.

 

So I completely forgot about that post. You should try deleting the structured text stuff on screen when the button is pressed, then redraw it when it is pressed again.

Link to comment
Share on other sites

  • 2 weeks later...
  • 1 month later...

Hey i am wondering how i would have the debug automatically appears on the screen, I want it to be already up when you spawn. All of the code is in and if i press insert it appears but then it goes away after 10 seconds or so. any thoughts?

-Aurora

Link to comment
Share on other sites

Hey i am wondering how i would have the debug automatically appears on the screen, I want it to be already up when you spawn. All of the code is in and if i press insert it appears but then it goes away after 10 seconds or so. any thoughts?

-Aurora

 

Easiest way is to try a reinstall. Make sure every step was done right. Does the monitor look like it should when you press the button to make it show?

Link to comment
Share on other sites

Yes It looks perfect it just appears for x number of seconds then disappears. I feel like I maybe didn't install it right but every time I press "insert" the debug shows, but it feels as if it on a timer.

 

Yes, this is how it is supposed to happen normally. The problem deals with the space interrupt. Either it was not added properly or it is messed up somehow.

Link to comment
Share on other sites

  • 7 months later...

Would it be possible to load the debug screen after ingame first?

Because I'm using Multiple Characters Script and it looks a bit strange and doesn't make sense there :D

Maybe this would also be a solution for the other buggy look of the menu.

buggy.jpg

EDIT: Never mind, the debug screen isn't the problem for the other optical problems.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
×
×
  • Create New...