public class ScoreboardPlayerUpdateS2CPacket extends Object implements Packet<ClientPlayPacketListener>
Modifier and Type | Field and Description |
---|---|
private ServerScoreboard.UpdateMode |
mode |
private String |
objectiveName |
private String |
playerName |
private int |
score |
Constructor and Description |
---|
ScoreboardPlayerUpdateS2CPacket() |
ScoreboardPlayerUpdateS2CPacket(ServerScoreboard.UpdateMode mode,
String objectiveName,
String playerName,
int score) |
Modifier and Type | Method and Description |
---|---|
void |
apply(ClientPlayPacketListener clientPlayPacketListener) |
String |
getObjectiveName() |
String |
getPlayerName() |
int |
getScore() |
ServerScoreboard.UpdateMode |
getUpdateMode() |
void |
read(PacketByteBuf buf) |
void |
write(PacketByteBuf buf) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
isWritingErrorSkippable
private String playerName
private int score
private ServerScoreboard.UpdateMode mode
public ScoreboardPlayerUpdateS2CPacket()
public ScoreboardPlayerUpdateS2CPacket(ServerScoreboard.UpdateMode mode, @Nullable String objectiveName, String playerName, int score)
public void read(PacketByteBuf buf) throws IOException
read
in interface Packet<ClientPlayPacketListener>
IOException
public void write(PacketByteBuf buf) throws IOException
write
in interface Packet<ClientPlayPacketListener>
IOException
public void apply(ClientPlayPacketListener clientPlayPacketListener)
apply
in interface Packet<ClientPlayPacketListener>
@Environment(value=CLIENT) public String getPlayerName()
@Environment(value=CLIENT) public int getScore()
@Environment(value=CLIENT) public ServerScoreboard.UpdateMode getUpdateMode()