XServerQuery

Need some nice Mods? Here, you are right!
Deaod
Average
Posts: 43
Joined: Fri Jul 10, 2020 9:22 am

Re: XServerQuery

Post by Deaod »

Whats the problem with it?

EDIT: I've found an infinite loop that was crashing my servers (probably my own change at fault, but the code in XServerQuery is also pretty dumb), so therell be another version.
Eternity
Skilled
Posts: 178
Joined: Sat Nov 30, 2019 10:56 pm

Re: XServerQuery

Post by Eternity »

Deaod wrote: Sun Mar 14, 2021 12:47 pm Whats the problem with it?
It should not be used as index for 'ChallengeBotInfo' "Skills" array. "Difficulty" variable from 'ChallengeBotInfo' should be used instead.
Deaod
Average
Posts: 43
Joined: Fri Jul 10, 2020 9:22 am

Re: XServerQuery

Post by Deaod »

Given that the base-game DeathMatchPlus does exactly the same ... im not going to argue with it, and leave this untouched i think. Btw, DeathMatchPlus.SpawnBot changes Level.Game.Difficulty to (what i think will just be ChallengeBotInfo).Difficulty.

Anyway, 2.03: Fixed an infinite loop.
You do not have the required permissions to view the files attached to this post.
Buggie
Godlike
Posts: 3173
Joined: Sat Mar 21, 2020 5:32 am

Re: XServerQuery

Post by Buggie »

[rev]rato.skt wrote: Sat Mar 13, 2021 11:19 pmI'm still hopi that someone will put the option to add dns, only numbers are obsolete....
Look like you need this: https://github.com/OldUnreal/UnrealTour ... issues/171
If so, then it can be fixed in v469c.
Deaod wrote: Sun Mar 14, 2021 5:25 pmGiven that the base-game DeathMatchPlus does exactly the same ... im not going to argue with it, and leave this untouched i think. Btw, DeathMatchPlus.SpawnBot changes Level.Game.Difficulty to (what i think will just be ChallengeBotInfo).Difficulty.
You mean this https://github.com/OldUnreal/UnrealTour ... /issues/85 ?
Deaod
Average
Posts: 43
Joined: Fri Jul 10, 2020 9:22 am

Re: XServerQuery

Post by Deaod »

Ah, good point.

2.04: Fix BotSkill value
You do not have the required permissions to view the files attached to this post.
User avatar
sektor2111
Godlike
Posts: 6438
Joined: Sun May 09, 2010 6:15 pm
Location: On the roof.

Re: XServerQuery

Post by sektor2111 »

GameInfo is GameInfo and Bot is Bot

Code: Select all

class GameInfo extends Info
	native;
var byte  Difficulty;									// 0=easy, 1=medium, 2=hard, 3=very hard.
For GitHub "coders" Level Game has MAX 3 probably they do not have any clue how to decompile UScript...
Relevance code

Code: Select all

...
	if
	(	(Difficulty==0 && !Other.bDifficulty0 )
	||  (Difficulty==1 && !Other.bDifficulty1 )
	||  (Difficulty==2 && !Other.bDifficulty2 )
	||  (Difficulty==3 && !Other.bDifficulty3 )
	||  (!Other.bSinglePlayer && (Level.NetMode==NM_Standalone) ) 
	||  (!Other.bNet && ((Level.NetMode == NM_DedicatedServer) || (Level.NetMode == NM_ListenServer)) )
	||  (!Other.bNetSpecial  && (Level.NetMode==NM_Client)) )
		return False;
...
It's all about up to Level 3.
And Pawn

Code: Select all

class Pawn extends Actor 
	abstract
	native
	nativereplication;
...
var(AI) float		Skill;			// skill, scaled by game difficulty (add difficulty to this value)
...
	if ( Level.Game != None )
		Skill += Level.Game.Difficulty; 
	Skill = FClamp(Skill, 0, 3);
Code clamps Pawn at 3.
And Bot

Code: Select all

function InitializeSkill(float InSkill)
{
	Skill = InSkill;
	bNovice = ( Skill < 4 );
	if ( !bNovice )
		Skill -= 4;
	Skill = FClamp(Skill, 0, 3);
	ReSetSkill();
}

function ReSetSkill()
{
	//log(self$" at skill "$Skill$" novice "$bNovice);
	bThreePlus = ( (Skill >= 3) && Level.Game.IsA('DeathMatchPlus') && DeathMatchPlus(Level.Game).bThreePlus );
	bLeadTarget = ( !bNovice || bThreePlus );
	if ( bNovice )
		ReFireRate = Default.ReFireRate;
	else
		ReFireRate = Default.ReFireRate * (1 - 0.25 * skill);

	PreSetMovement();
}
It's why Bot must have a ChallengeBotInfo deal, not GameInfo, or else it will never show GodLike bots.
User avatar
[rev]rato.skt
Adept
Posts: 441
Joined: Mon Aug 16, 2010 1:09 pm

Re: XServerQuery

Post by [rev]rato.skt »

how cool, what good news! Thanks :rock: :rock: :rock: :gj:
Buggie wrote: Sun Mar 14, 2021 8:10 pm
[rev]rato.skt wrote: Sat Mar 13, 2021 11:19 pmI'm still hopi that someone will put the option to add dns, only numbers are obsolete....
Look like you need this: https://github.com/OldUnreal/UnrealTour ... issues/171
If so, then it can be fixed in v469c.
Brazilian Server:
Alma Negra - 34.95.189.187:7777
Classic - madruga.utbr.cf:7777
Duel - x1.utbr.cf:6666
User avatar
(G)ott
Average
Posts: 38
Joined: Wed Jun 15, 2011 5:34 pm
Personal rank: bullet eater

Re: XServerQuery

Post by (G)ott »

Version 2.1.0

Changelog:

Code: Select all

from 201 to 210
- added optional timestamp log.
- added config bShowTimeStamp & bShowAdvancedTimeStamp.
- fixed time check on query request.
- added config iNumSecToBlockIP.
- changed config iNumPacketsBeforLog to iNumPacketsBeforBlock !!
- fixed players country memory.
- removed querytype "NewNet".
- changed config bShowProtection is now by default "hidden".
- changed querytype "Protection" - it has now only focus to ACE.
- some small changes and cleanups.
Download on top post. -> fast trace


greetz (G)ott
User avatar
(G)ott
Average
Posts: 38
Joined: Wed Jun 15, 2011 5:34 pm
Personal rank: bullet eater

Re: XServerQuery

Post by (G)ott »

Version 2.1.1

Changelog:

Code: Select all

from 210 to 211
- fixed server will not shown, when ACE is installed and bShowProtection=true.
Stupid Bug :facepalm:

Download on top post. -> fast trace


greetz (G)ott
User avatar
asosed
Adept
Posts: 333
Joined: Fri May 15, 2020 2:36 pm
Location: Russia

Re: XServerQuery

Post by asosed »

(G)ott, did you fix the bot skill display issue that deaod fixed? viewtopic.php?f=34&t=6061&start=15#p127295 I see that the problem remains
And this problem "XServerQuery starts ignoring requests soon after mightnight according to real-time-clock of the server." viewtopic.php?f=34&t=6061#p127233
Image
User avatar
bearbeardut99
Novice
Posts: 9
Joined: Wed Jan 26, 2022 8:14 pm

Re: XServerQuery

Post by bearbeardut99 »

hello there !

I have been running xserverquery for a long time, but something is not right in my settings that i can't visualize the country flag of my own server. i have no problems when seeing flags from players but from the server itself it just won`t show up. Am I missing something ? I would appreciate some help.

thanks for the effort to keep ut99 alive and fun :gj:
Last edited by bearbeardut99 on Tue Mar 01, 2022 3:30 am, edited 1 time in total.
BearBeard#5925
Fun Sphere https://discord.gg/BPsdjcAZ7V
unreal://45.225.92.93:7787 FragNewNet
unreal://45.225.92.93:7797 FragNewNet


Image
User avatar
(G)ott
Average
Posts: 38
Joined: Wed Jun 15, 2011 5:34 pm
Personal rank: bullet eater

Re: XServerQuery

Post by (G)ott »

asosed wrote: Tue Jan 25, 2022 12:42 pm (G)ott, did you fix the bot skill display issue that deaod fixed? viewtopic.php?f=34&t=6061&start=15#p127295 I see that the problem remains
I'm sorry but I don't agree with this solution. There are two reasons:
- "Game Info" ist not the place to show the bots inividual skill. Maybe i will add a new colum in the PlayerInfo of the XBrowser which shows the skill, if its a bot.
- I think that "Bot Skill" is in Unreal a number between 0-3 and should be expanded to 0-7 in UT, but was cancelled. Skill is always FClamp(Skill, 0, 3). Maybe i will rename "Bot Skill" to "Difficulty" and set the output to "easy", "medium", "hard" or "very hard" (or similar).

Code: Select all

class DeathMatchPlus extends TournamentGameInfo config;
...
function string GetRules()
{
...
		Resultset = ResultSet$"\\botskill\\"$class'ChallengeBotInfo'.default.Skills[Difficulty];
...
}
...

Code: Select all

class GameInfo extends Info native;

var byte  Difficulty;									// 0=easy, 1=medium, 2=hard, 3=very hard.
...

Code: Select all

class UMenuNewGameClientWindow extends UMenuPageWindow;
...
defaultproperties
{
     ...
     SkillText="Skill Level:"
     Skills(0)="Easy"
     Skills(1)="Medium"
     Skills(2)="Hard"
     Skills(3)="Unreal"
     ...
}

Code: Select all

class UMenuBotConfigBase extends UMenuPageWindow;
...
defaultproperties
{
     BaseText="Base Skill:"
     BaseHelp="This is the base skill level of the bots."
     Skills(0)="Novice"
     Skills(1)="Average"
     Skills(2)="Skilled"
     Skills(3)="Masterful"
     ...
}
At the moment im a bit busy, so a new version of both Mods will not come in the next time.


asosed wrote: Tue Jan 25, 2022 12:42 pm And this problem "XServerQuery starts ignoring requests soon after mightnight according to real-time-clock of the server." viewtopic.php?f=34&t=6061#p127233
should be fixed

Code: Select all

from 201 to 210
- fixed time check on query request.

bearbeardut99 wrote: Wed Jan 26, 2022 8:22 pm hello there !

I have been running xserverquery for a long time, but something is now right in my settings that i can´t visualize the country flag of my own server. i have no problems when seeing flags from players but from the server itself it just won`t show up. Am I missing something ? I would appreciate some help.

thanks for the effort to keep ut99 alive and fun :gj:
Have you tried changing the "netAddress" manually in the XSQ ?

like:

Code: Select all

[XServerQuery.XServerQuery]
netAddress=45.225.92.93
If so, has it changed to another IP?
User avatar
Que
Inhuman
Posts: 812
Joined: Mon Dec 09, 2019 5:49 am
Personal rank: ...

Re: XServerQuery

Post by Que »

Have you tried changing the "netAddress" manually in the XSQ ?
This doesn't work for me either.
*Join our Discord Here.*
Our mods - MVX , SSB , SmartWFL , UTCmds , BotCommands , Smart Stats , join/leave announcer , NoSmoke , UTLogin , BrightSkins , Server Tran…
*Our Servers
Deaod
Average
Posts: 43
Joined: Fri Jul 10, 2020 9:22 am

Re: XServerQuery

Post by Deaod »

(G)ott wrote: Wed Feb 23, 2022 6:36 pm
asosed wrote: Tue Jan 25, 2022 12:42 pm (G)ott, did you fix the bot skill display issue that deaod fixed? viewtopic.php?f=34&t=6061&start=15#p127295 I see that the problem remains
I'm sorry but I don't agree with this solution. There are two reasons:
- "Game Info" ist not the place to show the bots inividual skill. Maybe i will add a new colum in the PlayerInfo of the XBrowser which shows the skill, if its a bot.
- I think that "Bot Skill" is in Unreal a number between 0-3 and should be expanded to 0-7 in UT, but was cancelled. Skill is always FClamp(Skill, 0, 3). Maybe i will rename "Bot Skill" to "Difficulty" and set the output to "easy", "medium", "hard" or "very hard" (or similar).
I'm not sure what the problem is with fixing this. Difficulty is set depending on BotInfo.Difficulty. The label of the value in the query response is BotSkill and should thus IMO reflect the setting the user chose for the skill of bots. Restoring that information seems like a pure bugfix to me.

Please take another look at the code surrounding the Difficulty setting. I know its tangled up with everything, but youll eventually see that the fix works and has minimal side-effects.

"Bot Skill" is a number between 0 and 3, yes, but there is also a bNovice (Bots), or bNoviceMode (Game) variable that effectively doubles the number of difficulty settings. Taken together UT absolutely supports 8 different skill settings for bots, and XServerQuery should respond with the setting the admin chose.

EDIT: For what its worth, the change buggie proposed has been integrated into 469c.
User avatar
Que
Inhuman
Posts: 812
Joined: Mon Dec 09, 2019 5:49 am
Personal rank: ...

Re: XServerQuery

Post by Que »

@(G)ott perhaps you could add to .ini an option to set flag prefix ie: AU
Which would display the Australian Flag next to server in UBrowser.
*Join our Discord Here.*
Our mods - MVX , SSB , SmartWFL , UTCmds , BotCommands , Smart Stats , join/leave announcer , NoSmoke , UTLogin , BrightSkins , Server Tran…
*Our Servers