Class PlayerAbilitiesS2CPacket
java.lang.Object
net.minecraft.network.packet.s2c.play.PlayerAbilitiesS2CPacket
- All Implemented Interfaces:
Packet<ClientPlayPacketListener>
public class PlayerAbilitiesS2CPacket extends Object implements Packet<ClientPlayPacketListener>
-
Field Summary
Fields Modifier and Type Field Description private booleanallowFlyingprivate booleancreativeModeprivate booleanflyingprivate floatflySpeedprivate booleaninvulnerableprivate floatwalkSpeed -
Constructor Summary
Constructors Constructor Description PlayerAbilitiesS2CPacket()PlayerAbilitiesS2CPacket(PlayerAbilities playerAbilities) -
Method Summary
Modifier and Type Method Description booleanallowFlying()voidapply(ClientPlayPacketListener clientPlayPacketListener)floatgetFlySpeed()floatgetWalkSpeed()booleanisCreativeMode()booleanisFlying()booleanisInvulnerable()voidread(PacketByteBuf buf)voidwrite(PacketByteBuf buf)Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.minecraft.network.Packet
isWritingErrorSkippable
-
Field Details
-
invulnerable
private boolean invulnerable -
flying
private boolean flying -
allowFlying
private boolean allowFlying -
creativeMode
private boolean creativeMode -
flySpeed
private float flySpeed -
walkSpeed
private float walkSpeed
-
-
Constructor Details
-
PlayerAbilitiesS2CPacket
public PlayerAbilitiesS2CPacket() -
PlayerAbilitiesS2CPacket
-
-
Method Details
-
read
- Specified by:
readin interfacePacket<ClientPlayPacketListener>- Throws:
IOException
-
write
- Specified by:
writein interfacePacket<ClientPlayPacketListener>- Throws:
IOException
-
apply
- Specified by:
applyin interfacePacket<ClientPlayPacketListener>
-
isInvulnerable
@Environment(CLIENT) public boolean isInvulnerable() -
isFlying
@Environment(CLIENT) public boolean isFlying() -
allowFlying
@Environment(CLIENT) public boolean allowFlying() -
isCreativeMode
@Environment(CLIENT) public boolean isCreativeMode() -
getFlySpeed
@Environment(CLIENT) public float getFlySpeed() -
getWalkSpeed
@Environment(CLIENT) public float getWalkSpeed()
-