Mirror von
https://github.com/PaperMC/Velocity.git
synchronisiert 2024-11-16 21:10:30 +01:00
Add Player#hasSentPlayerSettings (#980)
Dieser Commit ist enthalten in:
Ursprung
01f1e1a94e
Commit
c7ba5255e3
@ -88,6 +88,13 @@ public interface Player extends
|
||||
*/
|
||||
PlayerSettings getPlayerSettings();
|
||||
|
||||
/**
|
||||
* Returns whether the player has sent its client settings.
|
||||
*
|
||||
* @return true if the player has sent its client settings
|
||||
*/
|
||||
boolean hasSentPlayerSettings();
|
||||
|
||||
/**
|
||||
* Returns the player's mod info if they have a modded client.
|
||||
*
|
||||
|
@ -282,6 +282,11 @@ public class ConnectedPlayer implements MinecraftConnectionAssociation, Player,
|
||||
return settings == null ? ClientSettingsWrapper.DEFAULT : this.settings;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean hasSentPlayerSettings() {
|
||||
return settings != null;
|
||||
}
|
||||
|
||||
void setPlayerSettings(ClientSettings settings) {
|
||||
ClientSettingsWrapper cs = new ClientSettingsWrapper(settings);
|
||||
this.settings = cs;
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren