entity hider: check for players with no names
Not sure why this happens but we have stacktraces of isFriend crashing due to a player not having a name (yet?). It looks like the names are sent separately from the player spawn in the protocol.
This commit is contained in:
@@ -139,6 +139,12 @@ public abstract class EntityHiderMixin implements RSScene
|
||||
}
|
||||
}
|
||||
|
||||
if (player.getName() == null)
|
||||
{
|
||||
// player.isFriend() and player.isClanMember() npe when the player has a null name
|
||||
return false;
|
||||
}
|
||||
|
||||
return (!hideFriends && player.isFriend()) || (!isLocalPlayer && !hideClanMates && player.isClanMember());
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user