Merge branch 'master' into pre/1.13

This commit is contained in:
Shane Freeder
2018-08-17 05:10:45 +01:00
18 changed files with 191 additions and 53 deletions

View File

@@ -9,7 +9,7 @@ Allows you to do dynamic whitelisting and change of kick message
diff --git a/src/main/java/com/destroystokyo/paper/event/profile/ProfileWhitelistVerifyEvent.java b/src/main/java/com/destroystokyo/paper/event/profile/ProfileWhitelistVerifyEvent.java
new file mode 100644
index 00000000..a11f811e
index 000000000..b57fff9fb
--- /dev/null
+++ b/src/main/java/com/destroystokyo/paper/event/profile/ProfileWhitelistVerifyEvent.java
@@ -0,0 +0,0 @@
@@ -66,7 +66,7 @@ index 00000000..a11f811e
+ }
+
+ /**
+ * Gets the currently planned message to send to the user if they are not whitelisted
+ * @return the currently planned message to send to the user if they are not whitelisted
+ */
+ public String getKickMessage() {
+ return kickMessage;
@@ -87,7 +87,7 @@ index 00000000..a11f811e
+ }
+
+ /**
+ * Whether the player is whitelisted to play on this server (whitelist may be off is why its true)
+ * @return Whether the player is whitelisted to play on this server (whitelist may be off is why its true)
+ */
+ public boolean isWhitelisted() {
+ return whitelisted;
@@ -95,20 +95,21 @@ index 00000000..a11f811e
+
+ /**
+ * Changes the players whitelisted state. false will deny the login
+ * @param whitelisted The new whitelisted state
+ */
+ public void setWhitelisted(boolean whitelisted) {
+ this.whitelisted = whitelisted;
+ }
+
+ /**
+ * Returns if the player obtained whitelist status by having op
+ * @return if the player obtained whitelist status by having op
+ */
+ public boolean isOp() {
+ return isOp;
+ }
+
+ /**
+ * Returns if the server even has whitelist on
+ * @return if the server even has whitelist on
+ */
+ public boolean isWhitelistEnabled() {
+ return whitelistEnabled;