From: Samual Lenks Date: Fri, 1 Mar 2013 20:56:27 +0000 (-0500) Subject: Partly fix wait message X-Git-Tag: xonotic-v0.7.0~62^2~23^2~54 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=5f34e3792d998cf7eaafa98d62eef0c7cb9d7d39;p=xonotic%2Fxonotic-data.pk3dir.git Partly fix wait message --- diff --git a/qcsrc/common/notifications.qh b/qcsrc/common/notifications.qh index 421e958be..00c9f08ac 100644 --- a/qcsrc/common/notifications.qh +++ b/qcsrc/common/notifications.qh @@ -447,9 +447,9 @@ void Send_CSQC_Centerprint_Generic(entity e, float id, string s, float duration, MSG_CENTER_NOTIF(1, CENTER_KEYHUNT_HELP, 0, 0, "", CPID_KEYHUNT, "0 0", _("^BGAll keys are in your team's hands!\nHelp the key carriers to meet!"), "") \ MULTITEAM_CENTER(1, CENTER_KEYHUNT_INTERFERE_, 4, 0, 0, "", CPID_KEYHUNT, "0 0", _("^BGAll keys are in ^TC^TT team^BG's hands!\nInterfere ^F4NOW^BG!"), "") \ MSG_CENTER_NOTIF(1, CENTER_KEYHUNT_MEET, 0, 0, "", CPID_KEYHUNT, "0 0", _("^BGAll keys are in your team's hands!\nMeet the other key carriers ^F4NOW^BG!"), "") \ - MSG_CENTER_NOTIF(1, CENTER_KEYHUNT_SCAN, 0, 0, "", CPID_KEYHUNT, "-1 0", _("^BGScanning frequency range..."), "") \ + MSG_CENTER_NOTIF(1, CENTER_KEYHUNT_SCAN, 0, 0, "", CPID_KEYHUNT, "0 0", _("^BGScanning frequency range..."), "") \ MULTITEAM_CENTER(1, CENTER_KEYHUNT_START_, 4, 0, 0, "", CPID_KEYHUNT, "0 0", _("^BGYou are starting with the ^TC^TT key"), "") \ - MSG_CENTER_NOTIF(1, CENTER_KEYHUNT_WAIT, 0, 4, "kh_teams", CPID_KEYHUNT, "-1 0", _("^BGWaiting for players to join...\nNeed active players for: %s"), "") \ + MSG_CENTER_NOTIF(1, CENTER_KEYHUNT_WAIT, 0, 4, "kh_teams", CPID_KEYHUNT, "0 0", _("^BGWaiting for players to join...\nNeed active players for: %s"), "") \ MSG_CENTER_NOTIF(1, CENTER_LMS_CAMPCHECK, 0, 0, "", CPID_LMS_CAMP, "0 0", _("^F2Don't camp!"), "") \ MSG_CENTER_NOTIF(1, CENTER_MOTD, 1, 0, "s1", CPID_MOTD, "-1 0", _("^BG%s"), "") \ MSG_CENTER_NOTIF(1, CENTER_MINSTA_FINDAMMO, 0, 0, "", CPID_MINSTA_FINDAMMO, "1 9", _("^F4^COUNT^BG left to find some ammo!"), "") \ @@ -734,22 +734,22 @@ string notif_arg_kh_teams(float f1, float f2, float f3, float f4) { return sprintf("%s%s%s%s", (f1 ? - sprintf("%s%s", Team_ColoredFullName(f1), ((f2 + f3 + f4) ? ", " : "")) + sprintf("%s%s", Team_ColoredFullName(f1 - 1), ((f2 + f3 + f4) ? ", " : "")) : "" ), (f2 ? - sprintf("%s%s", Team_ColoredFullName(f2), ((f3 + f4) ? ", " : "")) + sprintf("%s%s", Team_ColoredFullName(f2 - 1), ((f3 + f4) ? ", " : "")) : "" ), (f3 ? - sprintf("%s%s", Team_ColoredFullName(f3), (f4 ? ", " : "")) + sprintf("%s%s", Team_ColoredFullName(f3 - 1), (f4 ? ", " : "")) : "" ), (f4 ? - Team_ColoredFullName(f4) + Team_ColoredFullName(f4 - 1) : "" ) diff --git a/qcsrc/server/mutators/gamemode_keyhunt.qc b/qcsrc/server/mutators/gamemode_keyhunt.qc index 9a84d65cb..de12e76cb 100644 --- a/qcsrc/server/mutators/gamemode_keyhunt.qc +++ b/qcsrc/server/mutators/gamemode_keyhunt.qc @@ -128,13 +128,13 @@ void kh_Controller_SetThink(float t, kh_Think_t func) // runs occasionaly if(t == 0) kh_controller.nextthink = time; // force } - +void kh_WaitForPlayers(); void kh_Controller_Think() // called a lot { if(intermission_running) return; if(self.cnt > 0) - self.cnt -= 1; + { if(self.think != kh_WaitForPlayers) { self.cnt -= 1; } } else if(self.cnt == 0) { self.cnt -= 1; @@ -855,7 +855,7 @@ void kh_WaitForPlayers() // delay start of the round until enough players are p } float p1 = kh_CheckPlayers(0), p2 = kh_CheckPlayers(1), p3 = kh_CheckPlayers(2), p4 = kh_CheckPlayers(3); - if(p1 || p2 || p3 || p4) + if not(p1 || p2 || p3 || p4) { Send_Notification(NOTIF_ANY, world, MSG_CENTER, CENTER_ARENA_ROUNDSTART, autocvar_g_balance_keyhunt_delay_round); kh_Controller_SetThink(autocvar_g_balance_keyhunt_delay_round, kh_StartRound);