mirror of
https://github.com/darksaid98/Flashback.git
synced 2026-12-01 14:38:50 +00:00
Fix NPE when PlayerInfo doesn't exist for player entity
This commit is contained in:
1 parent
3f65b37a57
commit
57350428e8
1 file changed
+1
-1
@@ -888,7 +888,7 @@ public class Recorder {
|
||||
Set<UUID> addedEntries = new HashSet<>();
|
||||
for (AbstractClientPlayer player : level.players()) {
|
||||
if (addedEntries.add(player.getUUID())) {
|
||||
PlayerInfo info = connection.getPlayerInfo(player.getUUID());
|
||||
PlayerInfo info = player.getPlayerInfo();
|
||||
if (info != null) {
|
||||
infoUpdatePacket.entries.add(new ClientboundPlayerInfoUpdatePacket.Entry(player.getUUID(),
|
||||
player.getGameProfile(), true, info.getLatency(), info.getGameMode(), info.getTabListDisplayName(), null));
|
||||
|
||||
Reference in new issue
Block a user