"net stat" output position

Discussions about UT99
Post Reply
User avatar
Barbie
Godlike
Posts: 1704
Joined: Fri Sep 25, 2015 9:01 pm
Location: moved without proper hashing

"net stat" output position

Post by Barbie » Mon Jul 08, 2019 12:15 am

Is it possible to manipulate the "net stat" output position on the HUD?
"Multiple exclamation marks," he went on, shaking his head, "are a sure sign of a diseased mind." --Terry Pratchett

The_Cowboy
Average
Posts: 72
Joined: Mon Jan 24, 2011 3:22 am
Personal rank: Codezilla

Re: "net stat" output position

Post by The_Cowboy » Mon Jul 08, 2019 4:03 am

It is. You just have to challenge it!

User avatar
Barbie
Godlike
Posts: 1704
Joined: Fri Sep 25, 2015 9:01 pm
Location: moved without proper hashing

Re: "net stat" output position

Post by Barbie » Mon Jul 08, 2019 9:17 pm

I suspected it while I was writing that: A given answer would be "yes" or "no"... :omfg:
"Multiple exclamation marks," he went on, shaking his head, "are a sure sign of a diseased mind." --Terry Pratchett

The_Cowboy
Average
Posts: 72
Joined: Mon Jan 24, 2011 3:22 am
Personal rank: Codezilla

Re: "net stat" output position

Post by The_Cowboy » Mon Jul 08, 2019 11:09 pm

Hehe, you may find a lazy example at https://github.com/ravimohan1991/SmartD ... verInfo.uc. It is simple (nothing complex at all) to inherit the class and start writing on the Canvas.

Higor
Godlike
Posts: 1767
Joined: Sun Mar 04, 2012 6:47 pm

Re: "net stat" output position

Post by Higor » Tue Jul 09, 2019 7:10 am

Except NET STAT display originates from the 'Render' class and is 100% native code.

All stats lines are drawn using the same function:

Code: Select all

void URender::ShowStat( FSceneNode* Frame, const TCHAR* Fmt, ... )
{
	TCHAR TempStr[4096];
	GET_VARARGS( TempStr, ARRAY_COUNT(TempStr), Fmt );

	guard(URender::ShowStat);
	Frame->Viewport->Canvas->WrappedPrintf( Frame->Viewport->Canvas->SmallFont, 0, TEXT(" %s\n"), TempStr );
	unguard;
}
And before drawing begins, this happens:

Code: Select all

	Frame->Viewport->Canvas->CurX=0;
	Frame->Viewport->Canvas->CurY=16;
So unless you know your way in C++, it's not possible.
ImageImage
Image unreal://23.111.157.138:7777
Image unreal://46.228.199.205:7788

The_Cowboy
Average
Posts: 72
Joined: Mon Jan 24, 2011 3:22 am
Personal rank: Codezilla

Re: "net stat" output position

Post by The_Cowboy » Tue Jul 09, 2019 7:52 am

In that case, my knowledge is incomplete when I obviously "assumed" it to be a simple canvas rendering procedure.
Anyways, adding a uscript support for the native function is piece of cake (maybe not with old engine).

Post Reply