aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/shcm/shsupercm
diff options
context:
space:
mode:
authorSHsuperCM <shsupercm@gmail.com>2021-09-18 16:51:19 +0300
committerSHsuperCM <shsupercm@gmail.com>2021-09-18 16:51:19 +0300
commit2f45ca5175ea1a42afc8cc9f58a86af8abe45a8c (patch)
tree6987dacdec19fdd03ee3e6462069905570c27dde /src/main/java/shcm/shsupercm
parentb3dd941dbed08e387876aa1b3fe779c0b7f50b83 (diff)
downloadCITResewn-2f45ca5175ea1a42afc8cc9f58a86af8abe45a8c.tar.gz
CITResewn-2f45ca5175ea1a42afc8cc9f58a86af8abe45a8c.tar.bz2
CITResewn-2f45ca5175ea1a42afc8cc9f58a86af8abe45a8c.zip
Fixed nbt property's regex matching not working
Diffstat (limited to 'src/main/java/shcm/shsupercm')
-rw-r--r--src/main/java/shcm/shsupercm/fabric/citresewn/pack/cits/CIT.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/shcm/shsupercm/fabric/citresewn/pack/cits/CIT.java b/src/main/java/shcm/shsupercm/fabric/citresewn/pack/cits/CIT.java
index 3675900..1492d4f 100644
--- a/src/main/java/shcm/shsupercm/fabric/citresewn/pack/cits/CIT.java
+++ b/src/main/java/shcm/shsupercm/fabric/citresewn/pack/cits/CIT.java
@@ -181,7 +181,7 @@ public abstract class CIT {
final String pattern = matchProperty;
match = s -> matchesPattern(caseSensitive ? s : s.toLowerCase(), pattern, 0, s.length(), 0, pattern.length());
} else if (matchProperty.startsWith(caseSensitive ? "regex:" : "iregex:")) {
- matchProperty = caseSensitive ? matchProperty.substring(5) : matchProperty.substring(6).toLowerCase(Locale.ENGLISH);
+ matchProperty = caseSensitive ? matchProperty.substring(6) : matchProperty.substring(7).toLowerCase(Locale.ENGLISH);
if ((path[path.length - 1].equals("Name") || path[path.length - 1].equals("Lore")) && !matchProperty.startsWith("{"))
matchProperty = "\\{\"text\":\"" + matchProperty + "\"}";
final Pattern pattern = Pattern.compile(matchProperty);