seta hud_panel_pressedkeys_bg_border "" "if set to something else than \"\" = override default size of border around the background"
seta hud_panel_pressedkeys_bg_padding "" "if set to something else than \"\" = override default padding of contents from border"
seta hud_panel_pressedkeys_aspect "" "forced aspect on panel"
+seta hud_panel_pressedkeys_attack "" "show attack buttons too"
seta hud_panel_chat "" "enable/disable this panel"
seta hud_panel_chat_pos "" "position of this base of the panel"
seta hud_panel_pressedkeys_bg_border ""
seta hud_panel_pressedkeys_bg_padding ""
seta hud_panel_pressedkeys_aspect "1.600000"
+seta hud_panel_pressedkeys_attack "0"
seta hud_panel_chat 1
seta hud_panel_chat_pos "0.010000 0.700000"
seta hud_panel_pressedkeys_bg_border ""
seta hud_panel_pressedkeys_bg_padding ""
seta hud_panel_pressedkeys_aspect "1.600000"
+seta hud_panel_pressedkeys_attack "0"
seta hud_panel_chat 1
seta hud_panel_chat_pos "0 0.775000"
seta hud_panel_pressedkeys_bg_border ""
seta hud_panel_pressedkeys_bg_padding ""
seta hud_panel_pressedkeys_aspect "1.600000"
+seta hud_panel_pressedkeys_attack "0"
seta hud_panel_chat 1
seta hud_panel_chat_pos "0 0.775000"
seta hud_panel_pressedkeys_bg_border ""
seta hud_panel_pressedkeys_bg_padding ""
seta hud_panel_pressedkeys_aspect "1.600000"
+seta hud_panel_pressedkeys_attack "0"
seta hud_panel_chat 1
seta hud_panel_chat_pos "0.020000 0.780000"
seta hud_panel_pressedkeys_bg_border ""
seta hud_panel_pressedkeys_bg_padding ""
seta hud_panel_pressedkeys_aspect "1.600000"
+seta hud_panel_pressedkeys_attack "0"
seta hud_panel_chat 1
seta hud_panel_chat_pos "0 0.760000"
float autocvar_hud_panel_powerups_text;
float autocvar_hud_panel_pressedkeys;
float autocvar_hud_panel_pressedkeys_aspect;
+float autocvar_hud_panel_pressedkeys_attack;
float autocvar_hud_panel_racetimer;
float autocvar_hud_panel_radar;
float autocvar_hud_panel_radar_foreground_alpha;
}
vector keysize;
- keysize = eX * mySize_x * (1/3) + eY * mySize_y * 0.5;
+ keysize = eX * mySize_x * (1/3.0) + eY * mySize_y * (1/(3.0 - !autocvar_hud_panel_pressedkeys_attack));
float pressedkeys;
pressedkeys = getstatf(STAT_PRESSED_KEYS);
+ if(autocvar_hud_panel_pressedkeys_attack)
+ {
+ drawpic_aspect_skin(pos + eX * keysize_x * 0.5, ((pressedkeys & KEY_ATCK) ? "key_atck_inv.tga" : "key_atck.tga"), keysize, '1 1 1', panel_fg_alpha, DRAWFLAG_NORMAL);
+ drawpic_aspect_skin(pos + eX * keysize_x * 1.5, ((pressedkeys & KEY_ATCK2) ? "key_atck_inv.tga" : "key_atck.tga"), keysize, '1 1 1', panel_fg_alpha, DRAWFLAG_NORMAL);
+ pos_y += keysize_y;
+ }
+
drawpic_aspect_skin(pos, ((pressedkeys & KEY_CROUCH) ? "key_crouch_inv.tga" : "key_crouch.tga"), keysize, '1 1 1', panel_fg_alpha, DRAWFLAG_NORMAL);
drawpic_aspect_skin(pos + eX * keysize_x, ((pressedkeys & KEY_FORWARD) ? "key_forward_inv.tga" : "key_forward.tga"), keysize, '1 1 1', panel_fg_alpha, DRAWFLAG_NORMAL);
drawpic_aspect_skin(pos + eX * keysize_x * 2, ((pressedkeys & KEY_JUMP) ? "key_jump_inv.tga" : "key_jump.tga"), keysize, '1 1 1', panel_fg_alpha, DRAWFLAG_NORMAL);
HUD_Write_PanelCvar_q("_dom_layout");
break;
case HUD_PANEL_PRESSEDKEYS:
+ HUD_Write_PanelCvar_q("_attack");
HUD_Write_PanelCvar_q("_aspect");
break;
case HUD_PANEL_ENGINEINFO:
const float KEY_RIGHT = 8;
const float KEY_JUMP = 16;
const float KEY_CROUCH = 32;
+const float KEY_ATCK = 64;
+const float KEY_ATCK2 = 128;
///////////////////////////
// cvar constants
self.pressedkeys |= KEY_CROUCH;
else
self.pressedkeys &~= KEY_CROUCH;
+
+ if (self.BUTTON_ATCK)
+ self.pressedkeys |= KEY_ATCK;
+ else
+ self.pressedkeys &~= KEY_ATCK;
+ if (self.BUTTON_ATCK2)
+ self.pressedkeys |= KEY_ATCK2;
+ else
+ self.pressedkeys &~= KEY_ATCK2;
}
/*