From 4b45b4fd5e8324f2f58ca526e0f65d5da48bc82a Mon Sep 17 00:00:00 2001 From: MaxED Date: Fri, 29 Apr 2016 23:19:02 +0000 Subject: [PATCH] Fixed, Things mode: fixed a crash when switching to Things mode when more than 256 things were selected. --- Source/Plugins/BuilderModes/ClassicModes/ThingsMode.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/Plugins/BuilderModes/ClassicModes/ThingsMode.cs b/Source/Plugins/BuilderModes/ClassicModes/ThingsMode.cs index de189236..b6937b37 100644 --- a/Source/Plugins/BuilderModes/ClassicModes/ThingsMode.cs +++ b/Source/Plugins/BuilderModes/ClassicModes/ThingsMode.cs @@ -999,13 +999,13 @@ namespace CodeImp.DoomBuilder.BuilderModes // Make text labels for selected linedefs ICollection orderedselection = General.Map.Map.GetSelectedThings(true); + labels = new Dictionary(orderedselection.Count); // Otherwise significant delays will occure. // Also we probably won't care about selection ordering when selecting this many anyway if(orderedselection.Count > MAX_THING_LABELS) return; int index = 0; - labels = new Dictionary(orderedselection.Count); foreach(Thing thing in orderedselection) { TextLabel l = new TextLabel();