mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-20 18:07:43 +01:00
Upstream has released updates that appear to apply and compile correctly Paper Changes: 871f30038 fixed kick event leave message (#4766) 0aa0a1d97 Updated Upstream (CraftBukkit) d770f71f4 Add PlayerArmSwingEvent (#5353) 23d887b2a Swapped out Vec3#distanceTo call with a Vec3#distanceToSqr call to remove calls to Math.sqrt 5ff90b938 Fix collisions during world generation (#6129) 20ff0b058 [ci skip] Add a test plugin (#6133) 416ec9898 [ci skip] Remove extra newlines at EOF (#6127) 79d7dfbbe Ensure shulker bounding box is updated (#6010) d8ad276b7 [ci skip] More badges and things to README.md (#5338) bb44da842 Fix cancelling EntityPickupItemEvent for villagers (#6091) 351a2c38b Drop no longer needed patch (#6115) 648f6078d Route sign run_command click events through normal chat logic (#6109) dafc06460 Fix MobEffectArgument#getEffect reobf 4aef0354d [ci skip] Use Java toolchain for run tasks (#6108) 144e5f7ac Add option for logging named entity deaths (#6107) b5be382d0 Add methods to `ProtoWorld` for working with `BlockState`s (#5929)
20 lines
1.4 KiB
Diff
20 lines
1.4 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: DoctaEnkoda <bierquejason@gmail.com>
|
|
Date: Thu, 24 Jun 2021 02:28:32 +0200
|
|
Subject: [PATCH] Allow player join full server by permission
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
|
|
index 5141185821c798cb20f7936d7927d2256d9be75f..5fdbdc2d3deb09da018d0db1b495d9fb52e39b44 100644
|
|
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
|
|
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
|
|
@@ -764,7 +764,7 @@ public abstract class PlayerList {
|
|
event.disallow(PlayerLoginEvent.Result.KICK_BANNED, PaperAdventure.asAdventure(chatmessage)); // Paper - Adventure
|
|
} else {
|
|
// return this.players.size() >= this.maxPlayers && !this.d(gameprofile) ? new ChatMessage("multiplayer.disconnect.server_full") : null;
|
|
- if (this.players.size() >= this.maxPlayers && !this.canBypassPlayerLimit(gameprofile)) {
|
|
+ if (this.players.size() >= this.maxPlayers && (!player.hasPermission("purpur.joinfullserver") || !this.canBypassPlayerLimit(gameprofile))) { // Purpur
|
|
event.disallow(PlayerLoginEvent.Result.KICK_FULL, PaperAdventure.LEGACY_SECTION_UXRC.deserialize(org.spigotmc.SpigotConfig.serverFullMessage)); // Spigot // Paper - Adventure
|
|
}
|
|
}
|