mirror of
https://github.com/PaperMC/Paper.git
synced 2025-05-02 08:51:39 +00:00
12 lines
762 B
Diff
12 lines
762 B
Diff
--- a/net/minecraft/server/commands/RideCommand.java
|
|
+++ b/net/minecraft/server/commands/RideCommand.java
|
|
@@ -58,7 +_,7 @@
|
|
Entity vehicle1 = target.getVehicle();
|
|
if (vehicle1 != null) {
|
|
throw ERROR_ALREADY_RIDING.create(target.getDisplayName(), vehicle1.getDisplayName());
|
|
- } else if (vehicle.getType() == EntityType.PLAYER) {
|
|
+ } else if (vehicle.getType() == EntityType.PLAYER && !io.papermc.paper.configuration.GlobalConfiguration.get().commands.rideCommandAllowPlayerAsVehicle) { // Paper - allow player as vehicle
|
|
throw ERROR_MOUNTING_PLAYER.create();
|
|
} else if (target.getSelfAndPassengers().anyMatch(passenger -> passenger == vehicle)) {
|
|
throw ERROR_MOUNTING_LOOP.create();
|