batch of notify and pressedkeys updates
authorFruitieX <rasse@rasse-lappy.localdomain>
Sat, 10 Jul 2010 20:26:32 +0000 (23:26 +0300)
committerFruitieX <rasse@rasse-lappy.localdomain>
Sat, 10 Jul 2010 20:26:32 +0000 (23:26 +0300)
46 files changed:
gfx/hud/default/notify_teamkill.tga [deleted file]
gfx/hud/default/notify_teamkill_blue.tga [new file with mode: 0644]
gfx/hud/default/notify_teamkill_red.tga [new file with mode: 0644]
gfx/hud/wickedhud/flag_blue_carrying.tga
gfx/hud/wickedhud/flag_blue_lost.tga
gfx/hud/wickedhud/flag_blue_shielded.tga
gfx/hud/wickedhud/flag_blue_taken.tga
gfx/hud/wickedhud/flag_red_carrying.tga
gfx/hud/wickedhud/flag_red_lost.tga
gfx/hud/wickedhud/flag_red_shielded.tga
gfx/hud/wickedhud/flag_red_taken.tga
gfx/hud/wickedhud/key_backward.tga
gfx/hud/wickedhud/key_backward_inv.tga
gfx/hud/wickedhud/key_crouch.tga
gfx/hud/wickedhud/key_crouch_inv.tga
gfx/hud/wickedhud/key_forward.tga
gfx/hud/wickedhud/key_forward_inv.tga
gfx/hud/wickedhud/key_jump.tga
gfx/hud/wickedhud/key_jump_inv.tga
gfx/hud/wickedhud/key_left.tga
gfx/hud/wickedhud/key_left_inv.tga
gfx/hud/wickedhud/key_right.tga
gfx/hud/wickedhud/key_right_inv.tga
gfx/hud/wickedhud/notify_camping.tga
gfx/hud/wickedhud/notify_death.tga
gfx/hud/wickedhud/notify_lava.tga
gfx/hud/wickedhud/notify_selfkill.tga
gfx/hud/wickedhud/notify_slime.tga
gfx/hud/wickedhud/notify_teamkill.tga [deleted file]
gfx/hud/wickedhud/notify_teamkill_blue.tga [new file with mode: 0644]
gfx/hud/wickedhud/notify_teamkill_red.tga [new file with mode: 0644]
gfx/hud/wickedhud/notify_water.tga
gfx/hud/wickedhud/race_newfail.tga
gfx/hud/wickedhud/race_newrankgreen.tga
gfx/hud/wickedhud/race_newrankyellow.tga
gfx/hud/wickedhud/race_newrecordserver.tga
gfx/hud/wickedhud/race_newtime.tga
gfx/hud/wickedhud/voteprogress_back.tga
gfx/hud/wickedhud/voteprogress_prog.tga
gfx/hud/wickedhud/voteprogress_voted.tga
gfx/hud/wickedhud/weapon_complainbubble.tga [new file with mode: 0644]
hud_wickedhud_default.cfg
qcsrc/client/autocvars.qh
qcsrc/client/hud.qc
qcsrc/common/constants.qh
qcsrc/server/ctf.qc

diff --git a/gfx/hud/default/notify_teamkill.tga b/gfx/hud/default/notify_teamkill.tga
deleted file mode 100644 (file)
index a40920b..0000000
Binary files a/gfx/hud/default/notify_teamkill.tga and /dev/null differ
diff --git a/gfx/hud/default/notify_teamkill_blue.tga b/gfx/hud/default/notify_teamkill_blue.tga
new file mode 100644 (file)
index 0000000..a40920b
Binary files /dev/null and b/gfx/hud/default/notify_teamkill_blue.tga differ
diff --git a/gfx/hud/default/notify_teamkill_red.tga b/gfx/hud/default/notify_teamkill_red.tga
new file mode 100644 (file)
index 0000000..a40920b
Binary files /dev/null and b/gfx/hud/default/notify_teamkill_red.tga differ
index ace6a5f2c3a01c554eda6a1ba10944252499d5c2..360df33b10f1f3e64bfd0134f2dba894ca67fddc 100644 (file)
Binary files a/gfx/hud/wickedhud/flag_blue_carrying.tga and b/gfx/hud/wickedhud/flag_blue_carrying.tga differ
index 67d894d82dfce9467ee18d6e90604b224d1eadab..1f037ce92558a1eca69a2958532916c2d30142d0 100644 (file)
Binary files a/gfx/hud/wickedhud/flag_blue_lost.tga and b/gfx/hud/wickedhud/flag_blue_lost.tga differ
index a8993f6b2cc58a3e92f5ae12ceba9e1a81d970de..1337e24cda3fa0ee40854cf44e75d8865ee82e49 100644 (file)
Binary files a/gfx/hud/wickedhud/flag_blue_shielded.tga and b/gfx/hud/wickedhud/flag_blue_shielded.tga differ
index 6847e7cc19ed17384a8112b0d36b9bbfd1d4e3d7..6df08ada64d9406454b10b0c084a0590cb73673f 100644 (file)
Binary files a/gfx/hud/wickedhud/flag_blue_taken.tga and b/gfx/hud/wickedhud/flag_blue_taken.tga differ
index 33930833233d10c4649fe955dc7fb7ce6456109d..7a8b4625c14a48e0a8d129c3bb1b54f30efe60db 100644 (file)
Binary files a/gfx/hud/wickedhud/flag_red_carrying.tga and b/gfx/hud/wickedhud/flag_red_carrying.tga differ
index f96e02147e738af1d0f051efe1b9b4138d04f00b..20380c0f33a0a6d346e6357e1adca572503a14cd 100644 (file)
Binary files a/gfx/hud/wickedhud/flag_red_lost.tga and b/gfx/hud/wickedhud/flag_red_lost.tga differ
index e7ec491fd6bcc7bb49fcf053de2642a179a492c5..fe0a8ad37f966dacf7bd03dd43316443114c61df 100644 (file)
Binary files a/gfx/hud/wickedhud/flag_red_shielded.tga and b/gfx/hud/wickedhud/flag_red_shielded.tga differ
index bf71977e149ab7de484f221c14fab285c61a411f..c1a560a9c135f19a500ae37dc94ebcc8b3423273 100644 (file)
Binary files a/gfx/hud/wickedhud/flag_red_taken.tga and b/gfx/hud/wickedhud/flag_red_taken.tga differ
index 4de0f33221888c307f98b5fa2883d9a556785d0a..5588a4b49928edd2529bf8fdb5b1ef1819ee21e8 100644 (file)
Binary files a/gfx/hud/wickedhud/key_backward.tga and b/gfx/hud/wickedhud/key_backward.tga differ
index bef0d1ca3ddde1e9d03bffd0c5e6326d2495d3d1..8217ae3a2cd93bf5c861ba503a98156b3a917ee7 100644 (file)
Binary files a/gfx/hud/wickedhud/key_backward_inv.tga and b/gfx/hud/wickedhud/key_backward_inv.tga differ
index 00b2dfe449da7c70a099da3c026deb08d74e0f6e..386bba0277c1442a8fe968ebde14ed9de647d5eb 100644 (file)
Binary files a/gfx/hud/wickedhud/key_crouch.tga and b/gfx/hud/wickedhud/key_crouch.tga differ
index 2cdbda804d6b9b21970059b1a3ad2e151fb071ab..c2528a5564ab410adb45cea40ab11c2cf87439d6 100644 (file)
Binary files a/gfx/hud/wickedhud/key_crouch_inv.tga and b/gfx/hud/wickedhud/key_crouch_inv.tga differ
index dfe223381bf585b6c80d017448398f9c2c5c6459..e33b59ce3ee94d7f093af51d35100b7be45b86fd 100644 (file)
Binary files a/gfx/hud/wickedhud/key_forward.tga and b/gfx/hud/wickedhud/key_forward.tga differ
index 7bbea6070fe830fb5f2602bc7d2b145a57e1e9e8..ccc763ede834c91fbba270bb4fd390312577290c 100644 (file)
Binary files a/gfx/hud/wickedhud/key_forward_inv.tga and b/gfx/hud/wickedhud/key_forward_inv.tga differ
index d02b2dbc88961f7d2be95ecdbdf58c6c2e4fdfde..d1ddcbbb0bd0777b8300414ff3fa041ec6c644d5 100644 (file)
Binary files a/gfx/hud/wickedhud/key_jump.tga and b/gfx/hud/wickedhud/key_jump.tga differ
index c54bb3763c0ed2b7f3d672cacf62d0fb20aad1ae..d54798022272898a82ec61b868099cc720247d19 100644 (file)
Binary files a/gfx/hud/wickedhud/key_jump_inv.tga and b/gfx/hud/wickedhud/key_jump_inv.tga differ
index 60fe71f17e0eca70dfd3d75b013f5d1613a9feb3..ed991f4b88184bd06519fbedb203416743176be9 100644 (file)
Binary files a/gfx/hud/wickedhud/key_left.tga and b/gfx/hud/wickedhud/key_left.tga differ
index 92bc615e44891dd933a01abbbcf971eaa3b4c1f0..e607ddbf5abeeba06abc7ade1221cbee4dfc4e81 100644 (file)
Binary files a/gfx/hud/wickedhud/key_left_inv.tga and b/gfx/hud/wickedhud/key_left_inv.tga differ
index 308c03b1e56d0c1b183448713c8e19a40024594e..83baa31e03bdd2f8015220394ee2af06d7622e1b 100644 (file)
Binary files a/gfx/hud/wickedhud/key_right.tga and b/gfx/hud/wickedhud/key_right.tga differ
index 8f04be424ec8bd9e602877035796d29269fb93a7..3bd886755287ccc81f14796122cda39431629c6c 100644 (file)
Binary files a/gfx/hud/wickedhud/key_right_inv.tga and b/gfx/hud/wickedhud/key_right_inv.tga differ
index 2766dd1ccf968b512018d167b4c8b02035faf3e6..1454d5ce0df83ba730ba27be9422b551ccd68e79 100644 (file)
Binary files a/gfx/hud/wickedhud/notify_camping.tga and b/gfx/hud/wickedhud/notify_camping.tga differ
index d5e8045a20469d1e9489af8ec504fe9eb4cd055f..b42738bb32e8aa661c7a3ca27b9abd00a7ec934b 100644 (file)
Binary files a/gfx/hud/wickedhud/notify_death.tga and b/gfx/hud/wickedhud/notify_death.tga differ
index 3976e8ba3fef0cbb0f3295137adc3b28ddc61d30..100c0fae032f73cc840c17d0f48b52c4a5848dfa 100644 (file)
Binary files a/gfx/hud/wickedhud/notify_lava.tga and b/gfx/hud/wickedhud/notify_lava.tga differ
index 646a1a23814b5c07b5cab4679fae6e211cd3812f..b05b6af56e639294107b713307ce30d4ee277ea1 100644 (file)
Binary files a/gfx/hud/wickedhud/notify_selfkill.tga and b/gfx/hud/wickedhud/notify_selfkill.tga differ
index c08a6a3d483ac7223bcece355acf9c7aaa405e6c..68da649d35fd2908b35c7d52a382cb55d646d719 100644 (file)
Binary files a/gfx/hud/wickedhud/notify_slime.tga and b/gfx/hud/wickedhud/notify_slime.tga differ
diff --git a/gfx/hud/wickedhud/notify_teamkill.tga b/gfx/hud/wickedhud/notify_teamkill.tga
deleted file mode 100644 (file)
index a40920b..0000000
Binary files a/gfx/hud/wickedhud/notify_teamkill.tga and /dev/null differ
diff --git a/gfx/hud/wickedhud/notify_teamkill_blue.tga b/gfx/hud/wickedhud/notify_teamkill_blue.tga
new file mode 100644 (file)
index 0000000..0ba677d
Binary files /dev/null and b/gfx/hud/wickedhud/notify_teamkill_blue.tga differ
diff --git a/gfx/hud/wickedhud/notify_teamkill_red.tga b/gfx/hud/wickedhud/notify_teamkill_red.tga
new file mode 100644 (file)
index 0000000..0ba677d
Binary files /dev/null and b/gfx/hud/wickedhud/notify_teamkill_red.tga differ
index 8315f1266b0d32854b611862eaf61b9ea0478c6d..6edb791b3e0b805167ec3670e0d8e440bfe150b3 100644 (file)
Binary files a/gfx/hud/wickedhud/notify_water.tga and b/gfx/hud/wickedhud/notify_water.tga differ
index cd1164bdf7c89ec4c79aa1fda37ed78143188a82..89d0ec59aab31699506b08be5aa837cf092404b9 100644 (file)
Binary files a/gfx/hud/wickedhud/race_newfail.tga and b/gfx/hud/wickedhud/race_newfail.tga differ
index c8fa1577cbe4ac283f79648b905f3c5f08c240e5..d3fe40dfd322c557a3e099c005c853b5a5072279 100644 (file)
Binary files a/gfx/hud/wickedhud/race_newrankgreen.tga and b/gfx/hud/wickedhud/race_newrankgreen.tga differ
index 0af3c593f587035ad96c4b9b6b479c5b0647da28..d3fe40dfd322c557a3e099c005c853b5a5072279 100644 (file)
Binary files a/gfx/hud/wickedhud/race_newrankyellow.tga and b/gfx/hud/wickedhud/race_newrankyellow.tga differ
index aa8bae1a8189d8d4b98f8df00b9de6e0f7720212..7c1e6db6158ec7a9eba12ed0dde115457cabbd29 100644 (file)
Binary files a/gfx/hud/wickedhud/race_newrecordserver.tga and b/gfx/hud/wickedhud/race_newrecordserver.tga differ
index c9647b927b36dcbf67c93a99a9ee8249cbc07173..1ec30476e36adb17328f86b86c000866820f69ba 100644 (file)
Binary files a/gfx/hud/wickedhud/race_newtime.tga and b/gfx/hud/wickedhud/race_newtime.tga differ
index 2348be8251e606d6dc600a100816fc3f445c7a08..3be8d40866930ae6eb807bb4c741832c64c9636a 100644 (file)
Binary files a/gfx/hud/wickedhud/voteprogress_back.tga and b/gfx/hud/wickedhud/voteprogress_back.tga differ
index 574d5d70a68b67f2db1106093c35bddbfec42965..f24f52415876e25736de02166ec0392fc2f705c2 100644 (file)
Binary files a/gfx/hud/wickedhud/voteprogress_prog.tga and b/gfx/hud/wickedhud/voteprogress_prog.tga differ
index ffc90a255ca1b3466f94af61e85188f092089850..ee06048fcdcf90edf1bdab32703d67075c3a0049 100644 (file)
Binary files a/gfx/hud/wickedhud/voteprogress_voted.tga and b/gfx/hud/wickedhud/voteprogress_voted.tga differ
diff --git a/gfx/hud/wickedhud/weapon_complainbubble.tga b/gfx/hud/wickedhud/weapon_complainbubble.tga
new file mode 100644 (file)
index 0000000..d0f73dd
Binary files /dev/null and b/gfx/hud/wickedhud/weapon_complainbubble.tga differ
index 7fc258413a7556e53788d1454e1b03163b5fa619..ab3e38e1f854c40385f8e93836c6a8f26185ab2a 100644 (file)
@@ -155,6 +155,7 @@ seta hud_pressedkeys_bg_color_team "" "override panel color with team color in t
 seta hud_pressedkeys_bg_alpha 0 "if set to something else than \"\" = override default panel background alpha"
 seta hud_pressedkeys_bg_border "" "if set to something else than \"\" = override default size of border around the background"
 seta hud_pressedkeys_bg_padding "" "if set to something else than \"\" = override default padding of contents from border"
+seta hud_pressedkeys_aspect 1.6 "forced aspect on panel"
 
 seta hud_chat 1 "enable/disable this panel"
 seta hud_chat_pos "0.020000 0.790000" "position of this base of the panel"
index f12d5bbcfe16061d192352d49073e7c854b359d0..dba5d6190262d72258b56d6e64aecaac4ff21dd2 100644 (file)
@@ -183,6 +183,7 @@ var string autocvar_hud_pressedkeys_bg_color_team;
 var string autocvar_hud_pressedkeys_bg_alpha;
 var string autocvar_hud_pressedkeys_bg_border;
 var string autocvar_hud_pressedkeys_bg_padding;
+var float autocvar_hud_pressedkeys_aspect;
 
 var float autocvar_hud_chat;
 var vector autocvar_hud_chat_pos;
index 18e71d265dcc5bb952750faaccb77838518f792d..d4196054159dedf435a15e352ece2c3faf19a4ca 100644 (file)
@@ -2575,6 +2575,9 @@ void HUD_KillNotify(string s1, string s2, string s3, float type, float msg)
                } else if(type == INFO_RETURNFLAG) {
                        HUD_KillNotify_Push(s1, s2, 0, INFO_RETURNFLAG);
                        print(s1, "^7 returned the ", s2, "\n");
+               } else if(type == INFO_CAPTUREFLAG) {
+                       HUD_KillNotify_Push(s1, s2, 0, INFO_CAPTUREFLAG);
+                       print(s1, "^7 captured the ", s2, s3, "\n");
                }
        }
 }
@@ -2700,7 +2703,6 @@ void HUD_Notify (void)
        fadetime = autocvar_hud_notify_fadetime;
 
        string s;
-       vector color;
 
        vector pos_attacker, pos_victim;
        vector weap_pos;
@@ -2743,105 +2745,99 @@ void HUD_Notify (void)
                        if(killnotify_deathtype[j] == DEATH_GENERIC)
                        {
                                s = "notify_death";
-                               color = '1 1 1';
                        }
                        else if(killnotify_deathtype[j] == DEATH_NOAMMO)
                        {
                                s = "notify_outofammo";
-                               color = '1 1 1';
                        }
                        else if(killnotify_deathtype[j] == DEATH_KILL)
                        {
                                s = "notify_selfkill";
-                               color = '1 1 1';
                        }
                        else if(killnotify_deathtype[j] == DEATH_CAMP)
                        {
                                s = "notify_camping";
-                               color = '1 1 1';
                        }
                        else if(killnotify_deathtype[j] == KILL_TEAM_RED)
                        {
-                               s = "notify_teamkill";
-                               color = '1 0 0';
+                               s = "notify_teamkill_red";
                        }
                        else if(killnotify_deathtype[j] == KILL_TEAM_BLUE)
                        {
-                               s = "notify_teamkill";
-                               color = '0 0 1';
+                               s = "notify_teamkill_blue";
                        }
                        else if(killnotify_deathtype[j] == DEATH_DROWN)
                        {
-                               s = "notify_";
-                               color = '1 1 1';
+                               s = "notify_water";
                        }
                        else if(killnotify_deathtype[j] == DEATH_SLIME)
                        {
-                               s = "notify_";
-                               color = '1 1 1';
+                               s = "notify_slime";
                        }
                        else if(killnotify_deathtype[j] == DEATH_LAVA)
                        {
-                               s = "notify_";
-                               color = '1 1 1';
+                               s = "notify_lava";
                        }
                        else if(killnotify_deathtype[j] == DEATH_FALL)
                        {
-                               s = "notify_";
-                               color = '1 1 1';
+                               s = "notify_fall";
                        }
                        else if(killnotify_deathtype[j] == DEATH_SHOOTING_STAR)
                        {
-                               s = "notify_";
-                               color = '1 1 1';
+                               s = "notify_shootingstar";
                        }
                        else if(killnotify_deathtype[j] == DEATH_HURTTRIGGER || killnotify_deathtype[j] == DEATH_CUSTOM)
                        {
-                               s = "notify_";
-                               color = '1 1 1';
+                               s = "notify_death";
                        }
+                       // TODO: ctf icons...
                        else if(killnotify_deathtype[j] == INFO_GOTFLAG)
                        {
                                if(killnotify_victims[j] == "^1RED^7 flag")
                                {
-                                       s = "flag_red_carrying";
-                                       color = '1 0 0';
+                                       s = "notify_red_taken";
                                }
                                else
                                {
-                                       s = "flag_blue_carrying";
-                                       color = '0 0 1';
+                                       s = "notify_blue_taken";
                                }
                        }
                        else if(killnotify_deathtype[j] == INFO_RETURNFLAG)
                        {
                                if(killnotify_victims[j] == "^1RED^7 flag")
                                {
-                                       s = "flag_red_taken";
-                                       color = '1 0 0';
+                                       s = "notify_red_returned";
                                }
                                else
                                {
-                                       s = "flag_blue_taken";
-                                       color = '0 0 1';
+                                       s = "notify_blue_returned";
                                }
                        }
                        else if(killnotify_deathtype[j] == INFO_LOSTFLAG)
                        {
                                if(killnotify_victims[j] == "^1RED^7 flag")
                                {
-                                       s = "flag_red_lost";
-                                       color = '1 0 0';
+                                       s = "notify_red_lost";
+                               }
+                               else
+                               {
+                                       s = "notify_blue_lost";
+                               }
+                       }
+                       else if(killnotify_deathtype[j] == INFO_CAPTUREFLAG)
+                       {
+                               if(killnotify_victims[j] == "^1RED^7 flag")
+                               {
+                                       s = "notify_red_captured";
                                }
                                else
                                {
-                                       s = "flag_blue_lost";
-                                       color = '0 0 1';
+                                       s = "notify_blue_captured";
                                }
                        }
                        if(s != "" && a)
                        {
-                               drawpic_aspect_skin(weap_pos, s, '2 1 0' * height, color, panel_fg_alpha * a, DRAWFLAG_NORMAL);
+                               drawpic_aspect_skin(weap_pos, s, '2 1 0' * height, '1 1 1', panel_fg_alpha * a, DRAWFLAG_NORMAL);
                                drawcolorcodedstring(pos_attacker, attacker, fontsize, panel_fg_alpha * a, DRAWFLAG_NORMAL);
                        }
                }
@@ -2867,57 +2863,47 @@ void HUD_Notify (void)
                        if(autocvar__hud_configure) // example actions for config mode
                        {
                                s = "weaponelectro";
-                               color = '1 1 1';
                        }
                        else if(WEP_VALID(killnotify_deathtype[j]))
                        {
                                self = get_weaponinfo(killnotify_deathtype[j]);
                                s = strcat("weapon", self.netname);
-                               color = '1 1 1';
                        }
                        else if(killnotify_deathtype[j] == KILL_TEAM_RED)
                        {
-                               s = "notify_teamkill";
-                               color = '1 0 0';
+                               s = "notify_teamkill_red";
                        }
                        else if(killnotify_deathtype[j] == KILL_TEAM_BLUE)
                        {
-                               s = "notify_teamkill";
-                               color = '0 0 1';
+                               s = "notify_teamkill_red";
                        }
                        else if(killnotify_deathtype[j] == DEATH_DROWN)
                        {
                                s = "notify_water";
-                               color = '1 1 1';
                        }
                        else if(killnotify_deathtype[j] == DEATH_SLIME)
                        {
                                s = "notify_slime";
-                               color = '1 1 1';
                        }
                        else if(killnotify_deathtype[j] == DEATH_LAVA)
                        {
                                s = "notify_lava";
-                               color = '1 1 1';
                        }
                        else if(killnotify_deathtype[j] == DEATH_FALL)
                        {
                                s = "notify_fall";
-                               color = '1 1 1';
                        }
                        else if(killnotify_deathtype[j] == DEATH_SHOOTING_STAR)
                        {
                                s = "notify_shootingstar";
-                               color = '1 1 1';
                        }
                        else if(killnotify_deathtype[j] == DEATH_HURTTRIGGER || killnotify_deathtype[j] == DEATH_CUSTOM) // DEATH_CUSTOM is also void, right?
                        {
                                s = "notify_void";
-                               color = '1 1 1';
                        }
                        if(s != "" && a)
                        {
-                               drawpic_aspect_skin(weap_pos, s, '2 1 0' * height, color, panel_fg_alpha * a, DRAWFLAG_NORMAL);
+                               drawpic_aspect_skin(weap_pos, s, '2 1 0' * height, '1 1 1', panel_fg_alpha * a, DRAWFLAG_NORMAL);
                                drawcolorcodedstring(pos_attacker, attacker, fontsize, panel_fg_alpha * a, DRAWFLAG_NORMAL);
                                drawcolorcodedstring(pos_victim, victim, fontsize, panel_fg_alpha * a, DRAWFLAG_NORMAL);
                        }
@@ -2998,7 +2984,7 @@ void HUD_Timer(void)
 //
 void HUD_Radar(void)
 {
-       if (!(autocvar_hud_radar != 0 && (autocvar_hud_radar == 2 || teamplay || autocvar__hud_configure)))
+       if ((autocvar_hud_radar == 0 || (autocvar_hud_radar != 2 && !teamplay)) && !autocvar__hud_configure)
                return;
 
        float id = HUD_PANEL_RADAR;
@@ -4054,23 +4040,26 @@ void HUD_DrawPressedKeys(void)
                mySize -= '2 2 0' * panel_bg_padding;
        }
 
-       // always force 2:1 aspect
-       vector newSize;
-       if(mySize_x/mySize_y > 2)
+       // force custom aspect
+       if(autocvar_hud_pressedkeys_aspect)
        {
-               newSize_x = 2 * mySize_y;
-               newSize_y = mySize_y;
+               vector newSize;
+               if(mySize_x/mySize_y > autocvar_hud_pressedkeys_aspect)
+               {
+                       newSize_x = autocvar_hud_pressedkeys_aspect * mySize_y;
+                       newSize_y = mySize_y;
 
-               pos_x = pos_x + (mySize_x - newSize_x) / 2;
-       }
-       else
-       {
-               newSize_y = 1/2 * mySize_x;
-               newSize_x = mySize_x;
+                       pos_x = pos_x + (mySize_x - newSize_x) / 2;
+               }
+               else
+               {
+                       newSize_y = 1/autocvar_hud_pressedkeys_aspect * mySize_x;
+                       newSize_x = mySize_x;
 
-               pos_y = pos_y + (mySize_y - newSize_y) / 2;
+                       pos_y = pos_y + (mySize_y - newSize_y) / 2;
+               }
+               mySize = newSize;
        }
-       mySize = newSize;
 
        vector keysize;
        keysize = eX * mySize_x * (1/3) + eY * mySize_y * 0.5;
index 9eebbfb6c6753d53c73562bcd54cc82182c99cd4..775628e06871c5302191dadc321afa52c6e2651d 100644 (file)
@@ -575,6 +575,7 @@ float INFO_GOTFLAG = 10319;
 float INFO_PICKUPFLAG = 10320;
 float INFO_LOSTFLAG = 10321;
 float INFO_RETURNFLAG = 10322;
+float INFO_CAPTUREFLAG = 10323;
 
 // weapon requests
 float WR_SETUP         = 1; // (SVQC) setup weapon data
index 4148136daf62dd0454c3c80f9c92c3359edeb75e..6e314c88efd50f223f1c6ef15a8a1ae2a7c721e6 100644 (file)
@@ -473,7 +473,7 @@ void FlagTouch()
                                h0 = strcat(h0, "^7's"); // h0: display text for previous netname
                        if (flagcaptimerecord == 0)
                        {
-                               bprint(other.netname, "^7 captured the ", other.flagcarried.netname, " in ", s, " seconds\n");
+                               s = strcat(" in ", s, " seconds");
                                flagcaptimerecord = t;
                                db_put(ServerProgsDB, strcat(GetMapname(), "/captimerecord/time"), ftos(t));
                                db_put(ServerProgsDB, strcat(GetMapname(), "/captimerecord/netname"), h1);
@@ -481,7 +481,7 @@ void FlagTouch()
                        }
                        else if (t < flagcaptimerecord)
                        {
-                               bprint(other.netname, "^7 captured the ", other.flagcarried.netname, " in ", s, ", breaking ", strcat(h0, " previous record of ", s0, " seconds\n"));
+                               s = strcat(" in ", s, " seconds, breaking ", h0, " previous record of ", s0, " seconds");
                                flagcaptimerecord = t;
                                db_put(ServerProgsDB, strcat(GetMapname(), "/captimerecord/time"), ftos(t));
                                db_put(ServerProgsDB, strcat(GetMapname(), "/captimerecord/netname"), h1);
@@ -489,11 +489,13 @@ void FlagTouch()
                        }
                        else
                        {
-                               bprint(other.netname, "^7 captured the ", other.flagcarried.netname, " in ", s, ", failing to break ", strcat(h0, " record of ", s0, " seconds\n"));
+                               s = strcat(" in ", s, " seconds, failing to break ", h0, " record of ", s0, " seconds");
                        }
                }
                else
-                       bprint(other.netname, "^7 captured the ", other.flagcarried.netname, "\n");
+                       s = "";
+
+               Send_KillNotification (other.netname, other.flagcarried.netname, s, INFO_CAPTUREFLAG, MSG_INFO);
 
                PlayerTeamScore_Add(other, SP_CTF_CAPS, ST_CTF_CAPS, 1);
                LogCTF("capture", other.flagcarried.team, other);