mirror of
https://github.com/ChestShop-authors/ChestShop-3.git
synced 2024-09-27 14:13:05 +02:00
Allow multiline comments and improve comment about Floodgate
This commit is contained in:
parent
f68a3203ac
commit
a3c5ec618a
@ -19,7 +19,9 @@ public class FieldParser {
|
|||||||
StringBuilder builder = new StringBuilder(50);
|
StringBuilder builder = new StringBuilder(50);
|
||||||
|
|
||||||
if (field.isAnnotationPresent(ConfigurationComment.class)) {
|
if (field.isAnnotationPresent(ConfigurationComment.class)) {
|
||||||
builder.append("# ").append(field.getAnnotation(ConfigurationComment.class).value()).append('\n');
|
for (String commentLine : field.getAnnotation(ConfigurationComment.class).value().split("\n")) {
|
||||||
|
builder.append("# ").append(commentLine).append('\n');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
ValueParser parser = Configuration.getParser(field);
|
ValueParser parser = Configuration.getParser(field);
|
||||||
|
@ -197,7 +197,9 @@ public class Properties {
|
|||||||
@ConfigurationComment("This makes sure that the UUIDs of player shop accounts match the server's online-mode setting. Disabling this might lead to issues with offline players and is therefore unsupported!")
|
@ConfigurationComment("This makes sure that the UUIDs of player shop accounts match the server's online-mode setting. Disabling this might lead to issues with offline players and is therefore unsupported!")
|
||||||
public static boolean ENSURE_CORRECT_PLAYERID = true;
|
public static boolean ENSURE_CORRECT_PLAYERID = true;
|
||||||
|
|
||||||
@ConfigurationComment("This regexp validates the name of the player. If the name doesn't match, the player will neither be able to create a valid shop sign, nor buy/sell from a shop. Note to Bedrock players: If you have Floodgate on your server, you should set this regexp to ^\\\\*?\\\\w+$ and ENSURE_CORRECT_PLAYERID to false")
|
@ConfigurationComment("This regexp validates the name of the player. If the name doesn't match, the player will neither be able to create a valid shop sign, nor buy/sell from a shop.\n" +
|
||||||
|
"Note for Bedrock support: If you have Floodgate on your server, you should set this regexp to ^\\\\*?\\\\w+$ and ENSURE_CORRECT_PLAYERID to false\n" +
|
||||||
|
"If your Floodgate prefix is not *, change the first * in the regexp (the one before the question mark) to whatever your prefix is.")
|
||||||
public static String VALID_PLAYERNAME_REGEXP = "^\\\\w+$";
|
public static String VALID_PLAYERNAME_REGEXP = "^\\\\w+$";
|
||||||
|
|
||||||
@PrecededBySpace
|
@PrecededBySpace
|
||||||
|
Loading…
Reference in New Issue
Block a user