Update patches to latest 1.21.4 #1

Merged
Chaoscaot merged 242 commits from update/1.21.4 into main 2025-04-23 22:27:11 +02:00
236 changed files with 2367 additions and 1033 deletions
Showing only changes of commit 336ea9dfeb - Show all commits

View File

@ -1063,7 +1063,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
*
* @param entity the entity whose equipment to change
* @param items the slots to change, where the values are the items to which
* the slot should be changed. null values will set the slot to air
* the slot should be changed. null values will set the slot to air, empty map is not allowed
*/
public void sendEquipmentChange(@NotNull LivingEntity entity, @NotNull Map<EquipmentSlot, ItemStack> items);

View File

@ -1161,6 +1161,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
public void sendEquipmentChange(LivingEntity entity, Map<EquipmentSlot, ItemStack> items) {
Preconditions.checkArgument(entity != null, "Entity cannot be null");
Preconditions.checkArgument(items != null, "items cannot be null");
Preconditions.checkArgument(!items.isEmpty(), "items cannot be empty");
if (this.getHandle().connection == null) {
return;