From aa0c8c067ef96f640ad9f7ca0f6e8a6e8e70e762 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Aguilera=20Puerto?= Date: Thu, 6 Aug 2020 15:41:17 +0200 Subject: [PATCH] Fix fillgas too, make both case insensitive --- Content.Server/Atmos/AtmosCommands.cs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Content.Server/Atmos/AtmosCommands.cs b/Content.Server/Atmos/AtmosCommands.cs index 96a9580169..86d838cc11 100644 --- a/Content.Server/Atmos/AtmosCommands.cs +++ b/Content.Server/Atmos/AtmosCommands.cs @@ -78,7 +78,7 @@ namespace Content.Server.Atmos if(!int.TryParse(args[0], out var x) || !int.TryParse(args[1], out var y) || !int.TryParse(args[2], out var id) - || !(int.TryParse(args[3], out gasId) || Enum.TryParse(args[3], out gas)) + || !(int.TryParse(args[3], out gasId) || Enum.TryParse(args[3], true, out gas)) || !float.TryParse(args[4], out var moles)) return; if (gas != (Gas) (-1)) @@ -149,9 +149,12 @@ namespace Content.Server.Atmos var gas = (Gas) (-1); if (args.Length < 3) return; if(!int.TryParse(args[0], out var id) - || !(int.TryParse(args[1], out gasId) || Enum.TryParse(args[1], out gas)) + || !(int.TryParse(args[1], out gasId) || Enum.TryParse(args[1], true, out gas)) || !float.TryParse(args[2], out var moles)) return; + if (gas != (Gas) (-1)) + gasId = (int)gas; + var gridId = new GridId(id); var mapMan = IoCManager.Resolve();