if(fh >= 0)
{
fputs(fh, strcat("seta hud_skin \"", cvar_string("hud_skin"), "\"", "\n"));
- fputs(fh, strcat("seta hud_bg \"", cvar_string("hud_bg"), "\"", "\n"));
- fputs(fh, strcat("seta hud_bg_color \"", cvar_string("hud_bg_color"), "\"", "\n"));
- fputs(fh, strcat("seta hud_bg_color_team \"", cvar_string("hud_bg_color_team"), "\"", "\n"));
- fputs(fh, strcat("seta hud_bg_alpha \"", cvar_string("hud_bg_alpha"), "\"", "\n"));
- fputs(fh, strcat("seta hud_bg_border \"", cvar_string("hud_bg_border"), "\"", "\n"));
- fputs(fh, strcat("seta hud_bg_padding \"", cvar_string("hud_bg_padding"), "\"", "\n"));
- fputs(fh, strcat("seta hud_fg_alpha \"", cvar_string("hud_fg_alpha"), "\"", "\n"));
+ fputs(fh, strcat("seta hud_panel_bg \"", cvar_string("hud_panel_bg"), "\"", "\n"));
+ fputs(fh, strcat("seta hud_panel_bg_color \"", cvar_string("hud_panel_bg_color"), "\"", "\n"));
+ fputs(fh, strcat("seta hud_panel_bg_color_team \"", cvar_string("hud_panel_bg_color_team"), "\"", "\n"));
+ fputs(fh, strcat("seta hud_panel_bg_alpha \"", cvar_string("hud_panel_bg_alpha"), "\"", "\n"));
+ fputs(fh, strcat("seta hud_panel_bg_border \"", cvar_string("hud_panel_bg_border"), "\"", "\n"));
+ fputs(fh, strcat("seta hud_panel_bg_padding \"", cvar_string("hud_panel_bg_padding"), "\"", "\n"));
+ fputs(fh, strcat("seta hud_panel_fg_alpha \"", cvar_string("hud_panel_fg_alpha"), "\"", "\n"));
fputs(fh, "\n");
fputs(fh, strcat("seta hud_dock \"", cvar_string("hud_dock"), "\"", "\n"));
fputs(fh, strcat("seta hud_panel_", panel_name, "_complainbubble_color_unavailable \"", cvar_string(strcat("hud_panel_", panel_name, "_complainbubble_color_unavailable")), "\"", "\n"));
fputs(fh, strcat("seta hud_panel_", panel_name, "_ammo_color \"", cvar_string(strcat("hud_panel_", panel_name, "_ammo_color")), "\"", "\n"));
fputs(fh, strcat("seta hud_panel_", panel_name, "_ammo_alpha \"", cvar_string(strcat("hud_panel_", panel_name, "_ammo_alpha")), "\"", "\n"));
- fputs(fh, strcat("seta hud_panel_", panel_name, "_aspect \"", cvar_string(strcat("hud_panel_", panel_name, "_ammo_alpha")), "\"", "\n"));
+ fputs(fh, strcat("seta hud_panel_", panel_name, "_aspect \"", cvar_string(strcat("hud_panel_", panel_name, "_aspect")), "\"", "\n"));
break;
case HUD_PANEL_AMMO:
fputs(fh, strcat("seta hud_panel_", panel_name, "_onlycurrent \"", cvar_string(strcat("hud_panel_", panel_name, "_onlycurrent")), "\"", "\n"));
}
}
-#define acc_color(i) stov(cvar_string(strcat("hud_panel_weapons_accuracy_color", ftos(i))))
-#define MAX_ACCURACY_LEVELS 10
-float acc_lev[MAX_ACCURACY_LEVELS];
-
void HUD_Weapons(void)
{
if(!autocvar_hud_panel_weapons && !autocvar__hud_configure)
vector wpnpos;
vector wpnsize;
- float acc_levels;
- if(autocvar_hud_panel_weapons_accuracy && !(gametype == GAME_RACE || gametype == GAME_CTS))
- {
- acc_levels = tokenize(cvar_string("hud_panel_weapons_accuracy_color_levels"));
- if (acc_levels > MAX_ACCURACY_LEVELS)
- acc_levels = MAX_ACCURACY_LEVELS;
-
- for (i = 0; i < acc_levels; ++i)
- acc_lev[i] = stof(argv(i));
- }
-
for(i = 0; i < weapon_cnt; ++i)
{
wpnpos = pos + eX * column * mySize_x*(1/columns) + eY * row * mySize_y*(1/rows);
if(WEP_VALID(w)) {
HUD_KillNotify_Push(s1, "", 0, DEATH_GENERIC);
if (alsoprint)
- print("^1", s1, "^1 ", Weapon_SuicideMessage(type), "\n");
+ print("^1", sprintf(Weapon_SuicideMessage(type), strcat(s1, "^1")), "\n");
} else if (type == DEATH_KILL) {
HUD_KillNotify_Push(s1, "", 0, DEATH_KILL);
if (alsoprint)
} else if(msg == MSG_KILL) {
w = DEATH_WEAPONOF(type);
if(WEP_VALID(w)) {
- HUD_KillNotify_Push(s2, s1, 1, w);
+ HUD_KillNotify_Push(s1, s2, 1, type);
if (alsoprint)
- print("^1", s1, "^1 ", Weapon_KillMessage(type), "\n");
+ print("^1", sprintf(Weapon_KillMessage(type), strcat(s2, "^1"), strcat(s1, "^1")), "\n"); // default order: victim, killer
}
else if(type == KILL_TEAM_RED || type == KILL_TEAM_BLUE || type == KILL_TEAM_SPREE) {
HUD_KillNotify_Push(s1, s2, 1, type);
a = 0;
}
+ float w;
+ w = DEATH_WEAPONOF(killnotify_deathtype[j]);
+
// TODO: maybe print in team colors?
//
// Y [used by] X
{
s = "weaponelectro";
}
- else if(WEP_VALID(killnotify_deathtype[j]))
+ else if(killnotify_deathtype[j] & HITTYPE_SECONDARY && w == WEP_LASER)
+ {
+ s = "notify_melee_laser";
+ }
+ else if(killnotify_deathtype[j] & HITTYPE_SECONDARY && w == WEP_SHOTGUN)
+ {
+ s = "notify_melee_shotgun";
+ }
+ else if(WEP_VALID(w))
{
- self = get_weaponinfo(killnotify_deathtype[j]);
+ self = get_weaponinfo(w);
s = strcat("weapon", self.netname);
}
else if(killnotify_deathtype[j] == KILL_TEAM_RED)