if (gametype.m_1v1)
Announcer_Duel();
else
- centerprint_SetTitle(strcat("^BG", MapInfo_Type_ToText(gametype)), 0); // Show game type as title
+ centerprint_SetTitle(strcat("^BG", MapInfo_Type_ToText(gametype))); // Show game type as title
if(time + 5.0 < startTime) // if connecting to server while restart was active don't always play prepareforbattle
- Local_Notification(MSG_ANNCE, ANNCE_PREPARE);
+ if(teamplay)
+ Local_Notification(MSG_ANNCE, ANNCE_PREPARE_TEAM);
+ else
+ Local_Notification(MSG_ANNCE, ANNCE_PREPARE);
}
announcer_countdown.nextthink = startTime - floor(startTime - time + 0.5); //synchronize nextthink to startTime
int centerprint_countdown_num[CENTERPRINT_MAX_MSGS];
bool centerprint_showing;
+float centerprint_medal_expire_time;
+string centerprint_medal_icon;
+float centerprint_medal_times;
+
string centerprint_title;
- float centerprint_title_offset;
+ string centerprint_title_left;
+ string centerprint_title_right;
void centerprint_Add(int new_id, string strMessage, float duration, int countdown_num)
{
}
}
- void centerprint_ClearTitle()
+void centerprint_Medal(string icon, float times)
+{
+ if(!autocvar_hud_panel_centerprint_medals) return;
+
+ //LOG_INFOF("centerprint_Medal: icon: %s times: %d", icon, times);
+ //centerprint_medal_expire_time = time + autocvar_hud_panel_centerprint_time;
+ centerprint_medal_expire_time = time + MSG_MEDAL_TIME;
+ centerprint_medal_times = times;
+ if(centerprint_medal_icon)
+ strunzone(centerprint_medal_icon);
+ centerprint_medal_icon = strzone(strcat("gfx/medal/", icon));
+
+ centerprint_showing = true;
+}
+
+ void centerprint_SetDuelTitle(string left, string right, string div)
{
- strfree(centerprint_title);
- centerprint_title_offset = 0;
+ strcpy(centerprint_title_left, left);
+ strcpy(centerprint_title_right, right);
+ centerprint_SetTitle(sprintf("^BG%s^BG %s %s", left, div, right));
}
- void centerprint_SetTitle(string title, float offset)
+ void centerprint_SetTitle(string title)
{
- if(title != centerprint_title) {
+ if(title != centerprint_title)
strcpy(centerprint_title, CCR(title));
- centerprint_title_offset = offset;
- }
+ }
+
+ void centerprint_ClearTitle()
+ {
+ strfree(centerprint_title);
+ strfree(centerprint_title_left);
+ strfree(centerprint_title_right);
}
float hud_configure_cp_generation_time;