X-Git-Url: http://de.git.xonotic.org/?a=blobdiff_plain;f=data%2Fqcsrc%2Fclient%2Fsbar.qc;h=f0586cdacd7f5c653030cb81968818de8a93cbe6;hb=01a53c143145d0d348b6a9b4a71ee5494c428e8b;hp=6e6fe0af204d5082d307f5cc8b01e20c93bdd5d6;hpb=f0a1e43456813dcf3b5d0543c7aa313e118915f9;p=voretournament%2Fvoretournament.git diff --git a/data/qcsrc/client/sbar.qc b/data/qcsrc/client/sbar.qc index 6e6fe0af..f0586cda 100644 --- a/data/qcsrc/client/sbar.qc +++ b/data/qcsrc/client/sbar.qc @@ -1981,7 +1981,7 @@ void Sbar_Timer() void Sbar_Ring() { vector ring_pos, ring1_color, ring2_color; - vector text_pos, text_size; + vector text_pos, text1_size, text2_size; float ring_alpha, ring1_size, ring1_clip, ring2_size, ring2_clip; string text1_msg, text2_msg; @@ -1990,36 +1990,58 @@ void Sbar_Ring() ring1_size = 100; ring2_size = 60; ring_alpha = sbar_alpha_fg * 1; - text_size = '10 10 0'; + text1_size = '12 12 0'; + text2_size = '10 10 0'; switch(getstati(STAT_SBRING1_TYPE)) { case 0: + // ring disabled break; case 1: - // ring shows vore system delay + // ring shows vore system delay, empties with progress ring1_color = '0.5 0.5 1'; - ring1_clip = getstatf(STAT_SBRING1_CLIP); - text1_msg = "vore delay"; + text1_msg = "Vore delay"; + break; + case 2: + // ring shows stomach kick delay, empties with progress + ring1_color = '1 1 0.5'; + text1_msg = "Kick delay"; + break; + default: + print(strcat("^1Error:^7 Unknown ring type: ", ftos(getstati(STAT_SBRING1_TYPE)), "\n")); + break; + } + switch(getstati(STAT_SBRING2_TYPE)) + { + case 0: + // ring disabled + break; + case 1: + // ring shows regurgitation preparing, fills with progress + ring2_color = '1 0.5 1'; + text2_msg = "Regurgitating..."; break; default: print(strcat("^1Error:^7 Unknown ring type: ", ftos(getstati(STAT_SBRING1_TYPE)), "\n")); break; } + ring1_clip = getstatf(STAT_SBRING1_CLIP); + ring2_clip = getstatf(STAT_SBRING2_CLIP); if(text1_msg != "") { DrawCircleClippedPic(ring_pos, ring1_size, "gfx/hud/sb_ring.tga", ring1_clip, ring1_color, ring_alpha, DRAWFLAG_ADDITIVE); - text_pos_x = ring_pos_x - stringwidth(text1_msg, FALSE, text_size) / 2; + text_pos_x = ring_pos_x - stringwidth(text1_msg, FALSE, text1_size) / 2; text_pos_y = ring_pos_y - ring1_size / 2; - drawstring(text_pos, text1_msg, text_size, ring1_color, sbar_alpha_fg, DRAWFLAG_NORMAL); + drawstring(text_pos, text1_msg, text1_size, ring1_color, sbar_alpha_fg, DRAWFLAG_NORMAL); } if(text2_msg != "") { DrawCircleClippedPic(ring_pos, ring2_size, "gfx/hud/sb_ring.tga", ring2_clip, ring2_color, ring_alpha, DRAWFLAG_ADDITIVE); - text_pos_x = ring_pos_x - stringwidth(text2_msg, FALSE, text_size) / 2; + text_pos_x = ring_pos_x - stringwidth(text2_msg, FALSE, text2_size) / 2; text_pos_y = ring_pos_y + ring1_size / 2; - drawstring(text_pos, text2_msg, text_size, ring2_color, sbar_alpha_fg, DRAWFLAG_NORMAL); + drawstring(text_pos, text2_msg, text2_size, ring2_color, sbar_alpha_fg, DRAWFLAG_NORMAL); } }