mirror of
https://github.com/webbukkit/dynmap.git
synced 2024-11-27 20:58:40 +01:00
fabric-1.19: update to 1.19-pre3
This commit is contained in:
parent
f02a73bb0d
commit
24ecd0f72c
@ -1,4 +1,4 @@
|
|||||||
minecraft_version=1.19-pre1
|
minecraft_version=1.19-pre3
|
||||||
yarn_mappings=1.19-pre1+build.1
|
yarn_mappings=1.19-pre3+build.4
|
||||||
loader_version=0.14.5
|
loader_version=0.14.6
|
||||||
fabric_version=0.52.4+1.19
|
fabric_version=0.53.4+1.19
|
||||||
|
@ -2,7 +2,7 @@ package org.dynmap.fabric_1_19;
|
|||||||
|
|
||||||
import com.mojang.brigadier.CommandDispatcher;
|
import com.mojang.brigadier.CommandDispatcher;
|
||||||
import com.mojang.brigadier.exceptions.CommandSyntaxException;
|
import com.mojang.brigadier.exceptions.CommandSyntaxException;
|
||||||
import net.fabricmc.fabric.api.command.v1.CommandRegistrationCallback;
|
import net.fabricmc.fabric.api.command.v2.CommandRegistrationCallback;
|
||||||
import net.fabricmc.fabric.api.event.lifecycle.v1.ServerChunkEvents;
|
import net.fabricmc.fabric.api.event.lifecycle.v1.ServerChunkEvents;
|
||||||
import net.fabricmc.fabric.api.event.lifecycle.v1.ServerLifecycleEvents;
|
import net.fabricmc.fabric.api.event.lifecycle.v1.ServerLifecycleEvents;
|
||||||
import net.fabricmc.fabric.api.event.lifecycle.v1.ServerTickEvents;
|
import net.fabricmc.fabric.api.event.lifecycle.v1.ServerTickEvents;
|
||||||
@ -96,7 +96,7 @@ public class DynmapPlugin {
|
|||||||
plugin = this;
|
plugin = this;
|
||||||
// Fabric events persist between server instances
|
// Fabric events persist between server instances
|
||||||
ServerLifecycleEvents.SERVER_STARTING.register(this::serverStart);
|
ServerLifecycleEvents.SERVER_STARTING.register(this::serverStart);
|
||||||
CommandRegistrationCallback.EVENT.register((dispatcher, dedicated) -> registerCommands(dispatcher));
|
CommandRegistrationCallback.EVENT.register((dispatcher, registryAccess, environment) -> registerCommands(dispatcher));
|
||||||
CustomServerLifecycleEvents.SERVER_STARTED_PRE_WORLD_LOAD.register(this::serverStarted);
|
CustomServerLifecycleEvents.SERVER_STARTED_PRE_WORLD_LOAD.register(this::serverStarted);
|
||||||
ServerLifecycleEvents.SERVER_STOPPING.register(this::serverStop);
|
ServerLifecycleEvents.SERVER_STOPPING.register(this::serverStop);
|
||||||
}
|
}
|
||||||
|
@ -6,7 +6,7 @@ import net.minecraft.block.entity.SignBlockEntity;
|
|||||||
import net.minecraft.network.MessageType;
|
import net.minecraft.network.MessageType;
|
||||||
import net.minecraft.network.encryption.SignedChatMessage;
|
import net.minecraft.network.encryption.SignedChatMessage;
|
||||||
import net.minecraft.network.packet.c2s.play.UpdateSignC2SPacket;
|
import net.minecraft.network.packet.c2s.play.UpdateSignC2SPacket;
|
||||||
import net.minecraft.server.filter.Message;
|
import net.minecraft.server.filter.FilteredMessage;
|
||||||
import net.minecraft.server.filter.TextStream;
|
import net.minecraft.server.filter.TextStream;
|
||||||
import net.minecraft.server.network.ServerPlayNetworkHandler;
|
import net.minecraft.server.network.ServerPlayNetworkHandler;
|
||||||
import net.minecraft.server.network.ServerPlayerEntity;
|
import net.minecraft.server.network.ServerPlayerEntity;
|
||||||
@ -33,14 +33,14 @@ public abstract class ServerPlayNetworkHandlerMixin {
|
|||||||
public ServerPlayerEntity player;
|
public ServerPlayerEntity player;
|
||||||
|
|
||||||
@Inject(
|
@Inject(
|
||||||
method = "method_44155",
|
method = "handleDecoratedMessage",
|
||||||
at = @At(
|
at = @At(
|
||||||
value = "INVOKE",
|
value = "INVOKE",
|
||||||
target = "Lnet/minecraft/server/PlayerManager;broadcast(Lnet/minecraft/server/filter/Message;Lnet/minecraft/server/network/ServerPlayerEntity;Lnet/minecraft/util/registry/RegistryKey;)V",
|
target = "Lnet/minecraft/server/PlayerManager;broadcast(Lnet/minecraft/server/filter/FilteredMessage;Lnet/minecraft/server/network/ServerPlayerEntity;Lnet/minecraft/util/registry/RegistryKey;)V",
|
||||||
shift = At.Shift.BEFORE
|
shift = At.Shift.BEFORE
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
public void onGameMessage(Message<SignedChatMessage> message, CallbackInfo ci) {
|
public void onGameMessage(FilteredMessage<SignedChatMessage> message, CallbackInfo ci) {
|
||||||
ServerChatEvents.EVENT.invoker().onChatMessage(player, message.raw().getContent().getString());
|
ServerChatEvents.EVENT.invoker().onChatMessage(player, message.raw().getContent().getString());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -53,7 +53,7 @@ public abstract class ServerPlayNetworkHandlerMixin {
|
|||||||
),
|
),
|
||||||
locals = LocalCapture.CAPTURE_FAILHARD
|
locals = LocalCapture.CAPTURE_FAILHARD
|
||||||
)
|
)
|
||||||
public void onSignUpdate(UpdateSignC2SPacket packet, List<Message<String>> signText, CallbackInfo info,
|
public void onSignUpdate(UpdateSignC2SPacket packet, List<FilteredMessage<String>> signText, CallbackInfo info,
|
||||||
ServerWorld serverWorld, BlockPos blockPos, BlockState blockState, BlockEntity blockEntity, SignBlockEntity signBlockEntity)
|
ServerWorld serverWorld, BlockPos blockPos, BlockState blockState, BlockEntity blockEntity, SignBlockEntity signBlockEntity)
|
||||||
{
|
{
|
||||||
// Pull the raw text from the input.
|
// Pull the raw text from the input.
|
||||||
|
@ -26,8 +26,8 @@
|
|||||||
],
|
],
|
||||||
|
|
||||||
"depends": {
|
"depends": {
|
||||||
"fabricloader": ">=0.13.3",
|
"fabricloader": ">=0.14.6",
|
||||||
"fabric": ">=0.47.8",
|
"fabric": ">=0.53.4",
|
||||||
"minecraft": "1.19.x"
|
"minecraft": "1.19.x"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user