X-Git-Url: https://de.git.xonotic.org/?p=xonotic%2Fxonotic-data.pk3dir.git;a=blobdiff_plain;f=qcsrc%2Fserver%2Fscores.qc;h=ac3f52c72f446fb29ec0074d9eb43dfe6d2bbe9f;hp=7e1bfd1e560dc0b12f7286048aee1bd8c0b837d7;hb=765eed8d356d25d15047202838dc58db8cb80b89;hpb=d14f3f5afd18ad9cb251e487f1ca7632d84bf48b diff --git a/qcsrc/server/scores.qc b/qcsrc/server/scores.qc index 7e1bfd1e56..ac3f52c72f 100644 --- a/qcsrc/server/scores.qc +++ b/qcsrc/server/scores.qc @@ -194,6 +194,7 @@ void ScoreInfo_SetLabel_TeamScore(float i, string label, float scoreflags) } } +int Welcomemessage_too = 1; bool ScoreInfo_SendEntity(entity this, entity to, int sf) { float i; @@ -208,6 +209,15 @@ bool ScoreInfo_SendEntity(entity this, entity to, int sf) WriteString(MSG_ENTITY, teamscores_label(i)); WriteByte(MSG_ENTITY, teamscores_flags(i)); } + WriteByte(MSG_ENTITY, Welcomemessage_too); + // for some reason ScoreInfo_SendEntity is called twice on client connection + // send the welcome message only once + if (Welcomemessage_too) + { + // welcome message is sent here because it needs to know the gametype + SendWelcomemessage_msg_type(this, false, MSG_ENTITY); + Welcomemessage_too = 0; + } return true; } @@ -434,6 +444,7 @@ void WinningConditionHelper(entity this) s = strcat(s, ":P", ftos(cvar_purechanges_count)); s = strcat(s, ":S", ftos(nJoinAllowed(this, NULL))); s = strcat(s, ":F", ftos(serverflags)); + s = strcat(s, ":T", sv_termsofservice_url_escaped); s = strcat(s, ":M", modname); s = strcat(s, "::", GetPlayerScoreString(NULL, (fullstatus ? 1 : 2)));