mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2024-12-23 01:37:37 +00:00
Fixed WORLDEDIT-2707, regex in WorldEdit.getBlockPattern()
Regex in WorldEdit.getBlockPattern() was overly complex.
This commit is contained in:
parent
c2932cc54f
commit
da6103c33e
@ -671,7 +671,7 @@ public class WorldEdit {
|
||||
double chance;
|
||||
|
||||
// Parse special percentage syntax
|
||||
if (s.matches("[0-9]+(?:\\.(?:[0-9]+)?)?%.*")) {
|
||||
if (s.matches("[0-9]+(\\.[0-9]*)?%.*")) {
|
||||
String[] p = s.split("%");
|
||||
chance = Double.parseDouble(p[0]);
|
||||
block = getBlock(player, p[1]);
|
||||
|
Loading…
Reference in New Issue
Block a user