From fbf4b259d627a973a019aeb16e27403debedada1 Mon Sep 17 00:00:00 2001 From: biwa Date: Sat, 20 Apr 2019 13:22:35 +0200 Subject: [PATCH] - Fixed a freeze in the Tag Range plug-in when using the "relative" and "skip used tags" options. Fixes #125. --- Source/Plugins/TagRange/TagRangeForm.cs | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Source/Plugins/TagRange/TagRangeForm.cs b/Source/Plugins/TagRange/TagRangeForm.cs index 4a004d65..614248ed 100755 --- a/Source/Plugins/TagRange/TagRangeForm.cs +++ b/Source/Plugins/TagRange/TagRangeForm.cs @@ -102,10 +102,12 @@ namespace CodeImp.DoomBuilder.TagRange //mxd. Get relative tag range if(relative) { + int addtag = 0; // biwa + // Go for the number of tags we need for(int i = 0; i < selectioncount; i++) { - int newtag = initialtags[i] + starttag; + int newtag = initialtags[i] + starttag + addtag; if(newtag > General.Map.FormatInterface.MaxTag || newtag < General.Map.FormatInterface.MinTag) { @@ -124,7 +126,8 @@ namespace CodeImp.DoomBuilder.TagRange return newtags; } - starttag += increment; //mxd + newtag += increment; //mxd // biwa + addtag += increment; // biwa } } else @@ -133,7 +136,7 @@ namespace CodeImp.DoomBuilder.TagRange } newtags.Add(newtag); - starttag += increment; + addtag += increment; } } else //mxd. Get absolute tag range