From f99b7ec359e1da3fe904ff4c657fd561cd33d495 Mon Sep 17 00:00:00 2001 From: Chris <2648373+QuiCM@users.noreply.github.com> Date: Tue, 22 May 2018 10:10:22 +0930 Subject: [PATCH] Allow time parser to take spaces So you can pass in `10h 5m 2s` instead of `10h+5m+2s`. Works for things like `10h +5m -2s` as well --- TShockAPI/Utils.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TShockAPI/Utils.cs b/TShockAPI/Utils.cs index 1c4d681f..1ac60283 100644 --- a/TShockAPI/Utils.cs +++ b/TShockAPI/Utils.cs @@ -534,7 +534,7 @@ namespace TShockAPI var sb = new StringBuilder(3); for (int i = 0; i < str.Length; i++) { - if (Char.IsDigit(str[i]) || (str[i] == '-' || str[i] == '+')) + if (Char.IsDigit(str[i]) || (str[i] == '-' || str[i] == '+' || str[i] == ' ')) sb.Append(str[i]); else {