Add /purpur command for reloading purpur.yml

This commit is contained in:
William Blake Galbreath
2019-06-29 19:40:42 -05:00
parent 65f744bbdb
commit 31b9908398
12 changed files with 135 additions and 62 deletions

View File

@@ -1,4 +1,4 @@
From 9da2048d2a3c85e768563be742404530ab681d5a Mon Sep 17 00:00:00 2001
From 85436bf8d0c03d671b7afc8abfcade610999485d Mon Sep 17 00:00:00 2001
From: William Blake Galbreath <blake.galbreath@gmail.com>
Date: Sat, 29 Jun 2019 02:32:40 -0500
Subject: [PATCH] Controllable Minecarts
@@ -6,8 +6,8 @@ Subject: [PATCH] Controllable Minecarts
---
.../java/net/minecraft/server/Entity.java | 1 +
.../server/EntityMinecartAbstract.java | 35 +++++++++++++++++++
.../java/net/pl3x/purpur/PurpurConfig.java | 28 +++++++++++++++
3 files changed, 64 insertions(+)
.../java/net/pl3x/purpur/PurpurConfig.java | 25 +++++++++++++
3 files changed, 61 insertions(+)
diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/minecraft/server/Entity.java
index ca429be7db..ee099b6728 100644
@@ -81,33 +81,24 @@ index 6df2930e2d..d300c05333 100644
this.setMot(new Vec3D(this.getMot().x * this.derailedX, this.getMot().y * this.derailedY, this.getMot().z * this.derailedZ));
// CraftBukkit end
diff --git a/src/main/java/net/pl3x/purpur/PurpurConfig.java b/src/main/java/net/pl3x/purpur/PurpurConfig.java
index 9c7b8f3827..c734ecaafe 100644
index 448d21d9e1..b5aa94e802 100644
--- a/src/main/java/net/pl3x/purpur/PurpurConfig.java
+++ b/src/main/java/net/pl3x/purpur/PurpurConfig.java
@@ -1,7 +1,12 @@
@@ -1,9 +1,13 @@
package net.pl3x.purpur;
import com.google.common.base.Throwables;
+import net.minecraft.server.Block;
+import net.minecraft.server.Blocks;
+import net.minecraft.server.IRegistry;
+import net.minecraft.server.MinecraftKey;
import net.minecraft.server.MinecraftServer;
import org.bukkit.Bukkit;
import org.bukkit.command.Command;
+import org.bukkit.configuration.ConfigurationSection;
import org.bukkit.configuration.InvalidConfigurationException;
import org.bukkit.configuration.file.YamlConfiguration;
@@ -10,7 +15,9 @@ import java.io.IOException;
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import java.lang.reflect.Modifier;
+import java.util.HashMap;
import java.util.List;
+import java.util.Map;
import java.util.logging.Level;
public class PurpurConfig {
@@ -279,4 +286,25 @@ public class PurpurConfig {
@@ -293,4 +297,25 @@ public class PurpurConfig {
ridableZombiePigman = getBoolean("settings.ridable.zombie_pigman", ridableZombiePigman);
ridableZombieVillager = getBoolean("settings.ridable.zombie_villager", ridableZombieVillager);
}