seta notification_CENTER_JOIN_PREVENT_QUEUE "1" "0 = off, 1 = centerprint"
seta notification_CENTER_JOIN_PREVENT_QUEUE_TEAM_CONFLICT "1" "0 = off, 1 = centerprint"
seta notification_CENTER_JOIN_PREVENT_QUEUE_TEAM "1" "0 = off, 1 = centerprint"
+seta notification_CENTER_JOIN_PREVENT_VERSIONMISMATCH "1" "0 = off, 1 = centerprint"
seta notification_CENTER_KEEPAWAY_DROPPED "1" "0 = off, 1 = centerprint"
seta notification_CENTER_KEEPAWAY_PICKUP "1" "0 = off, 1 = centerprint"
seta notification_CENTER_KEEPAWAY_PICKUP_SELF "1" "0 = off, 1 = centerprint"
MSG_CENTER_NOTIF(ITEM_WEAPON_PRIMORSEC, N_ENABLE, 0, 3, "item_wepname f2primsec f3primsec", CPID_ITEM, "item_centime 0", _("^F1%s %s^BG is unable to fire, but its ^F1%s^BG can"), "")
MSG_CENTER_NOTIF(ITEM_WEAPON_UNAVAILABLE, N_ENABLE, 0, 1, "item_wepname", CPID_ITEM, "item_centime 0", _("^F1%s^BG is ^F4not available^BG on this map"), "")
+ MSG_CENTER_NOTIF(JOIN_PREVENT_VERSIONMISMATCH, N_ENABLE, 0, 0, "", CPID_PREVENT_JOIN, "0 0", _("^K1Your Xonotic version is incompatible with the server's version!"), "")
MSG_CENTER_NOTIF(JOIN_NOSPAWNS, N_ENABLE, 0, 0, "", CPID_PREVENT_JOIN, "0 0", _("^K1No spawnpoints available!\nHope your team can fix it..."), "")
MSG_CENTER_NOTIF(JOIN_PLAYBAN, N_ENABLE, 0, 0, "", CPID_PREVENT_JOIN, "0 0", BOLD(_("^K1You aren't allowed to play because you are banned in this server")), "")
MSG_CENTER_NOTIF(JOIN_PREVENT, N_ENABLE, 0, 1, "f1", CPID_PREVENT_JOIN, "0 0", _("^K1You may not join the game at this time.\nThis match is limited to ^F2%s^BG players."), "")
bool joinAllowed(entity this, int team_index)
{
- if (CS(this).version_mismatch) return false;
+ if (CS(this).version_mismatch)
+ {
+ Send_Notification(NOTIF_ONE_ONLY, this, MSG_CENTER, CENTER_JOIN_PREVENT_VERSIONMISMATCH);
+ return false;
+ }
if (time < CS(this).jointime + MIN_SPEC_TIME) return false;
- if (teamplay && lockteams) return false;
+ if (teamplay && lockteams)
+ {
+ Send_Notification(NOTIF_ONE_ONLY, this, MSG_CENTER, CENTER_TEAMCHANGE_LOCKED);
+ return false;
+ }
if (QueueNeeded(this))
{