Merge branch 'breaking' into DenyTeleportBugfix

This commit is contained in:
mindw0rm
2019-10-22 17:20:43 +02:00
11 changed files with 77 additions and 38 deletions

View File

@ -4,20 +4,20 @@ repositories {
def textVersion = "3.0.2"
dependencies {
implementation("org.yaml:snakeyaml:1.23")
implementation("com.google.code.gson:gson:2.8.0") {
implementation("org.yaml:snakeyaml:1.25")
implementation("com.google.code.gson:gson:2.8.6") {
because("Minecraft uses GSON 2.8.0")
force = true
}
implementation("org.projectlombok:lombok:1.18.8")
implementation("org.projectlombok:lombok:1.18.10")
compileOnly("org.projectlombok:lombok:1.18.8")
testCompileOnly("org.projectlombok:lombok:1.18.8")
annotationProcessor("org.projectlombok:lombok:1.18.8")
testAnnotationProcessor("org.projectlombok:lombok:1.18.8")
implementation("com.github.Sauilitired:Jenkins4J:2.0-SNAPSHOT")
implementation("com.squareup.okhttp3:okhttp:3.14.0")
implementation("com.squareup.okio:okio:2.2.2")
implementation("org.jetbrains.kotlin:kotlin-stdlib:1.3.30")
implementation("com.squareup.okhttp3:okhttp:4.2.2")
implementation("com.squareup.okio:okio:2.4.1")
implementation("org.jetbrains.kotlin:kotlin-stdlib:1.3.50")
}
sourceCompatibility = 1.8

View File

@ -24,9 +24,9 @@ import java.util.List;
import java.util.stream.Collectors;
@CommandDeclaration(command = "debugpaste", aliases = "dp", usage = "/plot debugpaste",
description = "Upload settings.yml, worlds.yml, PlotSquared.use_THIS.yml and your latest.log to https://athion.net/ISPaster/paste",
permission = "plots.debugpaste", category = CommandCategory.DEBUG) public class DebugPaste
extends SubCommand {
description = "Upload settings.yml, worlds.yml, PlotSquared.use_THIS.yml your latest.log and Multiverse's worlds.yml (if being used) to https://athion.net/ISPaster/paste",
permission = "plots.debugpaste", category = CommandCategory.DEBUG, confirmation = true, requiredType = RequiredType.NONE)
public class DebugPaste extends SubCommand {
private static String readFile(@NonNull final File file) throws IOException {
final List<String> lines;
@ -115,6 +115,15 @@ import java.util.stream.Collectors;
"&cSkipping PlotSquared.use_THIS.yml because it's empty");
}
try {
final File MultiverseWorlds =
new File(PlotSquared.get().IMP.getDirectory(), "../Multiverse-Core/worlds.yml");
incendoPaster
.addFile(new IncendoPaster.PasteFile("MultiverseCore/worlds.yml", readFile(MultiverseWorlds)));
} catch (final IOException ignored) {
MainUtil.sendMessage(player, "&cSkipping Multiverse worlds.yml because the plugin is not in use");
}
try {
final String rawResponse = incendoPaster.upload();
final JsonObject jsonObject =

View File

@ -26,7 +26,7 @@ public class Settings extends Config {
@Final public static String COMMIT; // These values are set from P2 before loading
@Final public static String PLATFORM; // These values are set from P2 before loading
@Comment("Show additional information in console") public static boolean DEBUG = true;
@Comment("Show additional information in console") public static boolean DEBUG = false;
@Comment({"The big annoying text that appears when you enter a plot",
"For a single plot: `/plot flag set titles false`", "For just you: `/plot toggle titles`"})
public static boolean TITLES = true;
@ -256,10 +256,10 @@ public class Settings extends Config {
public static final class Done {
@Comment("Require a done plot to download") public static boolean REQUIRED_FOR_DOWNLOAD =
@Comment("Require a plot marked as done to download") public static boolean REQUIRED_FOR_DOWNLOAD =
false;
@Comment("Only done plots can be rated") public static boolean REQUIRED_FOR_RATINGS = false;
@Comment("Restrict building when a plot is done") public static boolean RESTRICT_BUILDING =
@Comment("Only plots marked as done can be rated") public static boolean REQUIRED_FOR_RATINGS = false;
@Comment("Restrict building when a plot is marked as done") public static boolean RESTRICT_BUILDING =
false;
@Comment("The limit being how many plots a player can claim") public static boolean
COUNTS_TOWARDS_LIMIT = true;
@ -269,14 +269,15 @@ public class Settings extends Config {
public static final class Chat {
@Comment("Sometimes console color doesn't work, you can disable it here")
public static boolean CONSOLE_COLOR = true;
@Comment("Should chat be interactive") public static boolean INTERACTIVE = true;
@Comment("Should the chat be interactive?") public static boolean INTERACTIVE = true;
}
@Comment("Relating to how many plots someone can claim ") public static final class Limit {
@Comment("Should the limit be global (over multiple worlds)") public static boolean GLOBAL =
false;
@Comment("The range of permissions to check e.g. plots.plot.127") public static int
@Comment({"The max. range of permissions to check e.g. plots.plot.127", "The value covers the range to check only, you need to assign the permission to players/groups still",
"Modifying the value does NOT change the amount of plots players can claim"}) public static int
MAX_PLOTS = 127;
}
@ -291,7 +292,7 @@ public class Settings extends Config {
@Comment("Teleport to your plot on death") public static boolean ON_DEATH = false;
@Comment("Teleport to your plot on login") public static boolean ON_LOGIN = false;
@Comment("Teleport to your plot on claim") public static boolean ON_CLAIM = true;
@Comment("Add a teleportation delay to all commands") public static int DELAY = 0;
@Comment("Add a delay to all teleport commands") public static int DELAY = 0;
@Comment("The visit command is ordered by world instead of globally") public static boolean
PER_WORLD_VISIT = false;
}
@ -322,7 +323,7 @@ public class Settings extends Config {
@Comment(
{"Enable or disable part of the plugin", "Note: A cache will use some memory if enabled"})
{"Enable or disable parts of the plugin", "Note: A cache will use some memory if enabled"})
public static final class Enabled_Components { // Group the following values into a new config section
@Comment("The database stores all the plots") public static boolean DATABASE = true;
@Comment("Events are needed to track a lot of things") public static boolean EVENTS = true;
@ -339,7 +340,7 @@ public class Settings extends Config {
@Comment("Allow WorldEdit to be restricted to plots") public static boolean
WORLDEDIT_RESTRICTIONS = true;
@Comment("Allow economy to be used") public static boolean ECONOMY = true;
@Comment("Send anonymous usage statistics. Bukkit only setting.") public static boolean
@Comment("Send anonymous usage statistics to bStats. Bukkit only setting.") public static boolean
METRICS = true;
@Comment("Expiry will clear old or simplistic plots") public static boolean PLOT_EXPIRY =
false;
@ -355,7 +356,7 @@ public class Settings extends Config {
@Comment("Actively purge invalid database entries") public static boolean DATABASE_PURGER =
false;
@Comment("Delete plots when a player is banned") public static boolean BAN_DELETER = false;
@Comment("Prevent possibly unsafe blocks from being used in plot components")
@Comment({"Prevent possibly unsafe blocks from being used in plot components", "Can be bypassed with `/plot debugallowunsafe`"})
public static boolean PREVENT_UNSAFE = true;
}
}