Remap CraftBukkit to Mojang+Yarn Mappings
By: Initial Source <noreply+automated@papermc.io>
This commit is contained in:
parent
a265d64138
commit
30e4583dbe
1780 changed files with 44628 additions and 41274 deletions
|
@ -0,0 +1,34 @@
|
|||
--- a/net/minecraft/server/commands/WeatherCommand.java
|
||||
+++ b/net/minecraft/server/commands/WeatherCommand.java
|
||||
@@ -34,11 +34,11 @@
|
||||
}
|
||||
|
||||
private static int getDuration(CommandSourceStack source, int duration, IntProvider provider) {
|
||||
- return duration == -1 ? provider.sample(source.getServer().overworld().getRandom()) : duration;
|
||||
+ return duration == -1 ? provider.sample(source.getLevel().getRandom()) : duration; // CraftBukkit - SPIGOT-7680: per-world
|
||||
}
|
||||
|
||||
private static int setClear(CommandSourceStack source, int duration) {
|
||||
- source.getServer().overworld().setWeatherParameters(WeatherCommand.getDuration(source, duration, ServerLevel.RAIN_DELAY), 0, false, false);
|
||||
+ source.getLevel().setWeatherParameters(WeatherCommand.getDuration(source, duration, ServerLevel.RAIN_DELAY), 0, false, false); // CraftBukkit - SPIGOT-7680: per-world
|
||||
source.sendSuccess(() -> {
|
||||
return Component.translatable("commands.weather.set.clear");
|
||||
}, true);
|
||||
@@ -46,7 +46,7 @@
|
||||
}
|
||||
|
||||
private static int setRain(CommandSourceStack source, int duration) {
|
||||
- source.getServer().overworld().setWeatherParameters(0, WeatherCommand.getDuration(source, duration, ServerLevel.RAIN_DURATION), true, false);
|
||||
+ source.getLevel().setWeatherParameters(0, WeatherCommand.getDuration(source, duration, ServerLevel.RAIN_DURATION), true, false); // CraftBukkit - SPIGOT-7680: per-world
|
||||
source.sendSuccess(() -> {
|
||||
return Component.translatable("commands.weather.set.rain");
|
||||
}, true);
|
||||
@@ -54,7 +54,7 @@
|
||||
}
|
||||
|
||||
private static int setThunder(CommandSourceStack source, int duration) {
|
||||
- source.getServer().overworld().setWeatherParameters(0, WeatherCommand.getDuration(source, duration, ServerLevel.THUNDER_DURATION), true, true);
|
||||
+ source.getLevel().setWeatherParameters(0, WeatherCommand.getDuration(source, duration, ServerLevel.THUNDER_DURATION), true, true); // CraftBukkit - SPIGOT-7680: per-world
|
||||
source.sendSuccess(() -> {
|
||||
return Component.translatable("commands.weather.set.thunder");
|
||||
}, true);
|
Loading…
Add table
Add a link
Reference in a new issue