It's the first time for me to use capability, maybe the question looks like so unreadable.
In multiplayer game, the value in capability is displayed correctly on each player's own client,but when I try to get other player's value in client side, the value is not correct, is the initial value.
In my client, only my player's value is correct, other player's values are wrong.
In server side, the value from each player is correct.
I don't know how to sync the value from other player,i want to use the value in a render event.
I have already send packet in PlayerLoggedInEvent、PlayerRespawnEvent、PlayerChangedDimensionEvent
event.getPlayer().getCapability(GUI_SELECT).ifPresent(t ->
TackleMessage.CHANNEL.send( PacketDistributor.PLAYER.with(() -> (ServerPlayerEntity) event.getPlayer()),
new GuiSelectMessage(t.getSelectParam()) )
);
please help me