TrPlugins / TrChat

Modern & Advanced chat control for Minecraft servers
https://trchat.trixey.cc/
MIT License
125 stars 43 forks source link

[问题] 与geyser插件不兼容,当玩家通过geyser进入时trchat会报错 #396

Closed qmzqd closed 5 months ago

qmzqd commented 6 months ago

是否已尝试最新的版本

是否已查阅 Wiki

如果使用跨服功能, 是否在代理端上安装了TrChat或使用redis转发?

详细描述

1.在服务器的plugin文件夹内放入geyser插件与trchat插件 2.使用基岩版通过geyser进入服务器

配置文件

Options:
  Check-Update: true
  Proxy: AUTO
  Log-Normal: '[{0}] {1}: {2}'
  Log-Private: '[{0}] {1} -> {2}: {3}'
  Log-Delete-Time: 0
  Depend-Expansions: ['player', 'server']
  Prevent-Tab-Complete: false
  Component-Max-Length: 32700
  Always-Cancel-Chat-Event: false
  Cheat-Client-Secure-Chat: true

Channel:
  Default: 'Normal'

Database:
  Method: SQLite
  SQL:
    host: localhost
    port: 3306
    user: root
    password: root
    database: trixey
    table: trchat_user_data

Redis:
  enabled: false
  host: localhost
  port: 6379
  user: ~
  password: ~
  connect: 32
  timeout: 1000

Chat:
  Anti-Repeat: 0.80
  Cooldown: '1.8s'
  Length-Limit: 100

Color:
  Chat: true
  Sign: true
  Anvil: true
  Book: true

日志

[15:56:27 INFO]: [Geyser-Spigot] /111.181.110.230:38546 尝试连接! [15:56:28 INFO]: [Geyser-Spigot] 玩家以 drKris2017917 的用户名建立了连接 [15:56:28 INFO]: [Geyser-Spigot] drKris2017917 (登录为: drKris2017917) 已连接到 Java 服务器 [15:56:28 INFO]: UUID of player drKris2017917 is 00000000-0000-0000-0009-01f845a2e779 [15:56:28 ERROR]: Could not pass event PlayerLoginEvent to TrChat v2.1.0 java.lang.NullPointerException: null at java.util.Objects.requireNonNull(Objects.java:233) ~[?:?] at java.lang.invoke.DirectMethodHandle.checkBase(DirectMethodHandle.java:547) ~[?:?] at jdk.internal.reflect.MethodHandleObjectFieldAccessorImpl.get(MethodHandleObjectFieldAccessorImpl.java:57) ~[?:?] at java.lang.reflect.Field.get(Field.java:428) ~[?:?] at me.arasple.mc.trchat.taboolib.module.nms.TinyReflection$1.get(TinyReflection.java:153) ~[TrChat-2.1.0.jar:?] at me.arasple.mc.trchat.taboolib.module.nms.TinyProtocol.getChannel(TinyProtocol.java:391) ~[TrChat-2.1.0.jar:?] at me.arasple.mc.trchat.taboolib.module.nms.TinyProtocol$4.onPlayerLogin(TinyProtocol.java:167) ~[TrChat-2.1.0.jar:?] at com.destroystokyo.paper.event.executor.MethodHandleEventExecutor.execute(MethodHandleEventExecutor.java:40) ~[paper-api-1.20.2-R0.1-SNAPSHOT.jar:?] at co.aikar.timings.TimedEventExecutor.execute(TimedEventExecutor.java:81) ~[paper-api-1.20.2-R0.1-SNAPSHOT.jar:git-Paper-318] at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:70) ~[paper-api-1.20.2-R0.1-SNAPSHOT.jar:?] at io.papermc.paper.plugin.manager.PaperEventManager.callEvent(PaperEventManager.java:54) ~[paper-1.20.2.jar:git-Paper-318] at io.papermc.paper.plugin.manager.PaperPluginManagerImpl.callEvent(PaperPluginManagerImpl.java:126) ~[paper-1.20.2.jar:git-Paper-318] at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:615) ~[paper-api-1.20.2-R0.1-SNAPSHOT.jar:?] at net.minecraft.server.players.PlayerList.canPlayerLogin(PlayerList.java:763) ~[paper-1.20.2.jar:git-Paper-318] at net.minecraft.server.network.ServerLoginPacketListenerImpl.verifyLoginAndFinishConnectionSetup(ServerLoginPacketListenerImpl.java:218) ~[?:?] at net.minecraft.server.network.ServerLoginPacketListenerImpl.tick(ServerLoginPacketListenerImpl.java:86) ~[?:?] at net.minecraft.network.Connection.tick(Connection.java:592) ~[?:?] at net.minecraft.server.network.ServerConnectionListener.tick(ServerConnectionListener.java:240) ~[?:?] at net.minecraft.server.MinecraftServer.tickChildren(MinecraftServer.java:1578) ~[paper-1.20.2.jar:git-Paper-318] at net.minecraft.server.dedicated.DedicatedServer.tickChildren(DedicatedServer.java:446) ~[paper-1.20.2.jar:git-Paper-318] at net.minecraft.server.MinecraftServer.tickServer(MinecraftServer.java:1379) ~[paper-1.20.2.jar:git-Paper-318] at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1156) ~[paper-1.20.2.jar:git-Paper-318] at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:315) ~[paper-1.20.2.jar:git-Paper-318] at java.lang.Thread.run(Thread.java:1589) ~[?:?] [15:56:28 INFO]: [floodgate] Floodgate 玩家 drKris2017917 加入了 (UUID: 00000000-0000-0000-0009-01f845a2e779)

服务器环境

服务器版本: git-Paper-318 (MC: 1.20.2) (Implementing API version 1.20.2-R0.1-SNAPSHOT) (Git: 9271ee7) 插件列表: 18:50:20 INFO: Server Plugins (92): 18:50:20 INFO: Paper Plugins: 18:50:20 INFO: - LANBroadcaster 18:50:20 INFO: Bukkit Plugins: 18:50:20 INFO: - ABPPlugin, AdvancedBan, AdvancedReplay, AngelChest, ArmorMechanics, AuthMe, AutoTeamPlugin, AxSmithing, BedrockParity, BetterGUI 18:50:20 INFO: BlockLocker, ChestSort, Citizens, CMILib, CommandAPI, CoreProtect, CoreProtectTNT, CurveBuilding, DeEnchantment, DieMessage 18:50:20 INFO: DynamicLights, eco, Elevator, eShulkerBox, ExploitFixer, FastAsyncWorldEdit, FDCMD, floodgate, FreedomChat, FreezePlugin 18:50:20 INFO: FuckSignPlugin, GenshinImpact, Geyser-Spigot, GeyserHacks, GrimAC, GSit, HamsterAPI, HunterPlugin, ImageryAPI, Images 18:50:20 INFO: InteractionVisualizer, JukeBox, KeepChunks, LaggRemover, LiftReloaded, LiteSignIn, LobbyGames, LuckPerms, Matrix, MechanicsCore 18:50:20 INFO: Multiverse-Core, Multiverse-Inventories, Multiverse-NetherPortals, NBTAPI, NBTRecipes, NekoMaid, NexEngine, NoteBlockAPI, Pl-Hide-Pro, PlaceholderAPI 18:50:20 INFO: PlayerReport, PlayersBackpacksViewer, PlayerTitle, PluginManagerPlus, PriorChat, ProtocolLib, QuickShop, RandomSpawnpoint, Residence, ReviveMe 18:50:20 INFO: SeeMore, *SeniorTransfer, Sentinel, ServerListPlus, ServerMonitor, Shopkeepers, SkinsRestorer, spark, StrikeTeamUtils, superban_reborn 18:50:20 INFO: TabList, Themis, TrChat, Uniporter, Vault, ViaBackwards, ViaVersion, Vulcan, WeaponMechanics, XConomy

ItsFlicker commented 6 months ago

目前可关闭settings.yml中的Use-Packets解决 (2.1.1)

MinecraftEarthVillage commented 6 months ago

可以把Geyser放Watwrfall(群组中转站)服务端里,然后给群组服和本体服加Trchat,这样可以避免在本体同时安装造成的问题(我一开始就是这样的所以一直没遇到你的问题) 群组服是个好东西,推荐去看看

ItsFlicker commented 5 months ago

https://github.com/TrPlugins/TrChat/actions/runs/9451980664