• R/O
  • SSH

Commit

Tags
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

This is a fork of Zandronum Beta for Mac Os (Silicon and Intel)


Commit MetaInfo

Revisão8836885fd4326030f5113b39a2f41918620e6e8f (tree)
Hora2022-12-16 03:58:54
AutorAdam Kaminski <kaminskiadam9@gmai...>
CommiterAdam Kaminski

Mensagem de Log

Added the CVar "sv_distinguishteamchatlines", which distinguishes team chat messages from normal chat messages in the server console/logfile (addresses 0036).

Mudança Sumário

Diff

diff -r 69add5809cea -r 8836885fd432 docs/zandronum-history.txt
--- a/docs/zandronum-history.txt Thu Dec 15 12:18:10 2022 -0500
+++ b/docs/zandronum-history.txt Thu Dec 15 13:58:54 2022 -0500
@@ -35,6 +35,7 @@
3535 + - Added the CCMD "rcon_logout" so that clients with RCON access may logout if they want to. This also changes the old behaviour where a client who already had RCON access could lose it if they resent the wrong password to the server. [Kaminsky]
3636 + - Added ACS function: "SetGameplaySetting", allowing modders to change gameplay-related CVars on the fly. [Kaminsky]
3737 + - Added "offlineonly" and "onlineonly" options to the game settings feature of the GAMEMODE lump. This allows some CVars to only be configured for offline or online games, or both. [Kaminsky]
38++ - Added the CVar "sv_distinguishteamchatlines", which distinguishes team chat messages from normal chat messages in the server console/logfile when sv_markchatlines is enabled. [Kaminsky]
3839 - - Fixed: clients didn't initialize a sector's friction properly in some cases due to a superfluous check that wasn't removed earlier. [Kaminsky]
3940 - - Fixed: the server wouldn't initialize compatflags and compatflags2 properly if entered as command line parameters. [Kaminsky]
4041 - - Fixed: serverinfo CVars entered on the command line were restored in reverse order. [Kaminsky]
diff -r 69add5809cea -r 8836885fd432 src/sv_main.cpp
--- a/src/sv_main.cpp Thu Dec 15 12:18:10 2022 -0500
+++ b/src/sv_main.cpp Thu Dec 15 13:58:54 2022 -0500
@@ -275,6 +275,7 @@
275275 CVAR( Bool, sv_minimizetosystray, true, CVAR_ARCHIVE )
276276 CVAR( Int, sv_queryignoretime, 10, CVAR_ARCHIVE )
277277 CVAR( Bool, sv_markchatlines, false, CVAR_ARCHIVE )
278+CVAR( Int, sv_distinguishteamchatlines, 0, CVAR_ARCHIVE )
278279 CVAR( Flag, sv_nokill, dmflags2, DF2_NOSUICIDE )
279280 CVAR( Bool, sv_pure, true, CVAR_SERVERINFO | CVAR_LATCH )
280281 CVAR( Int, sv_maxclientsperip, 2, CVAR_ARCHIVE | CVAR_SERVERINFO )
@@ -1228,6 +1229,31 @@
12281229 if ( sv_markchatlines )
12291230 message = "CHAT ";
12301231
1232+ // [AK] Distinguish team chat messages from normal chat messages if we want to.
1233+ if (( sv_distinguishteamchatlines > 0 ) && ( ulMode == CHATMODE_TEAM ))
1234+ {
1235+ if ( PLAYER_IsTrueSpectator( &players[ulPlayer] ))
1236+ {
1237+ message += "<SPEC> ";
1238+ }
1239+ else if ( players[ulPlayer].bOnTeam )
1240+ {
1241+ // [AK] If sv_distinguishteamchatlines is set to 1, then show the team's name.
1242+ // If it's greater than 1, then show the team's number instead.
1243+ if ( sv_distinguishteamchatlines == 1 )
1244+ {
1245+ FString teamName = TEAM_GetName( players[ulPlayer].Team );
1246+ teamName.ToUpper( );
1247+
1248+ message.AppendFormat( "<%s> ", teamName.GetChars( ));
1249+ }
1250+ else
1251+ {
1252+ message.AppendFormat( "<TEAM #%d> ", players[ulPlayer].Team + 1 );
1253+ }
1254+ }
1255+ }
1256+
12311257 // Print this message in the server's local window.
12321258 if ( strnicmp( "/me", pszString, 3 ) == 0 )
12331259 {