X-Git-Url: http://de.git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fcommon%2Fcounting.qh;h=1413a80902d1fb338abed1881ea942c2929bf608;hb=71e6c75bc408ae5a116f296797c49c0cef7be113;hp=2559bf3acd9ff8e822163d961f61c3e8fbd81d3b;hpb=e0ac5f9f14e169a1e19d0e36b85cab061a74ed93;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/common/counting.qh b/qcsrc/common/counting.qh index 2559bf3ac..1413a8090 100644 --- a/qcsrc/common/counting.qh +++ b/qcsrc/common/counting.qh @@ -192,6 +192,24 @@ string process_time(float outputtype, float seconds) ((output != "") ? sprintf(", %s", output) : "")); } + return output; + } + case 3: + { + string output = ""; + + output = count_hours(tmp_hours); + + if(tmp_weeks) { tmp_days += (tmp_weeks * 7); } + if(tmp_years) { tmp_days += (tmp_years * 365); } + if(tmp_days) + { + output = sprintf( + "%s%s", + count_days(tmp_days), + ((output != "") ? sprintf(", %s", output) : "")); + } + return output; } }