]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Make time work after ready restart, also fix time being off by 1
authorMario <zacjardine@y7mail.com>
Thu, 1 Oct 2015 13:08:34 +0000 (23:08 +1000)
committerMario <zacjardine@y7mail.com>
Thu, 1 Oct 2015 13:08:34 +0000 (23:08 +1000)
qcsrc/server/miscfunctions.qc

index 5317fe6841b5ee8fec6fde781d9d12c090010c2f..a6164747dbdfa8fba56b601c5ea995496c4a35a1 100644 (file)
@@ -300,7 +300,7 @@ string formatmessage(string msg)
                        case "s": replacement = ftos(vlen(self.velocity - self.velocity_z * '0 0 1')); break;
                        case "S": replacement = ftos(vlen(self.velocity)); break;
                        case "t": replacement = seconds_tostring(ceil(max(0, autocvar_timelimit * 60 + game_starttime - time))); break;
-                       case "T": replacement = seconds_tostring(time); break;
+                       case "T": replacement = seconds_tostring(floor(time - game_starttime)); break;
                        default:
                        {
                                MUTATOR_CALLHOOK(FormatMessage, escape, replacement, msg);