Completed implementation of PaperClientOptions
This commit is contained in:
parent
7d5060d09b
commit
d5a2aa1c30
@ -123,12 +123,14 @@ public interface PaperOnlinePlayer extends PaperOffPlayer, AbstractOnlinePlayer
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
PaperClientOptions getClientOptions();
|
default PaperClientOptions getClientOptions() {
|
||||||
|
return new PaperClientOptions(this);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Provides various configuration values of the Minecraft client.
|
* Provides various configuration values of the Minecraft client.
|
||||||
*/
|
*/
|
||||||
abstract class PaperClientOptions implements AbstractOnlinePlayer.ClientOptions {
|
class PaperClientOptions implements AbstractOnlinePlayer.ClientOptions {
|
||||||
|
|
||||||
private final PaperOnlinePlayer op;
|
private final PaperOnlinePlayer op;
|
||||||
|
|
||||||
@ -198,8 +200,8 @@ public interface PaperOnlinePlayer extends PaperOffPlayer, AbstractOnlinePlayer
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isTextFilteringEnabled() { // needs reflection to get the actual value
|
public boolean isTextFilteringEnabled() {
|
||||||
return false;
|
return op.getBukkitPlayer().getClientOption(ClientOption.TEXT_FILTERING_ENABLED);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
Loading…
Reference in New Issue
Block a user