Package moe.caramel.daydream.packet
Record Class PlayerInfoUpdatePacket.PlayerData
java.lang.Object
java.lang.Record
moe.caramel.daydream.packet.PlayerInfoUpdatePacket.PlayerData
- Record Components:
profileId
- 플레이어의 게임 프로파일 UUID (필수: 모두)profile
- 플레이어의 게임 프로파일 (필수:PlayerInfoUpdatePacket.Action.ADD_PLAYER
)listed
- 탭 리스트 표시 여부 (필수:PlayerInfoUpdatePacket.Action.UPDATE_LISTED
)latency
- 플레이어의 지연 시간 (필수:PlayerInfoUpdatePacket.Action.UPDATE_LATENCY
)gameMode
- 플레이어의 게임 모드 (필수:PlayerInfoUpdatePacket.Action.UPDATE_GAME_MODE
)playerListName
- 플레이어의 표시 이름 (필수:PlayerInfoUpdatePacket.Action.UPDATE_DISPLAY_NAME
)showHat
- 플레이어 스킨의 모자 레이어 표시 여부 (필수:PlayerInfoUpdatePacket.Action.UPDATE_HAT
)listOrder
- 플레이어 탭 리스트 순서 (필수:PlayerInfoUpdatePacket.Action.UPDATE_LIST_ORDER
)chatSession
- 플레이어의 채팅 세션 (선택:PlayerInfoUpdatePacket.Action.INITIALIZE_CHAT
)
- Enclosing interface:
PlayerInfoUpdatePacket
public static record PlayerInfoUpdatePacket.PlayerData(UUID profileId, @Nullable com.mojang.authlib.GameProfile profile, boolean listed, int latency, @Nullable GameMode gameMode, @Nullable Component playerListName, boolean showHat, int listOrder, @Nullable ChatSession chatSession)
extends Record
플레이어 데이터
-
Constructor Summary
ConstructorDescriptionPlayerData
(UUID profileId, @Nullable com.mojang.authlib.GameProfile profile, boolean listed, int latency, @Nullable GameMode gameMode, @Nullable Component playerListName, boolean showHat, int listOrder, @Nullable ChatSession chatSession) Creates an instance of aPlayerData
record class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thechatSession
record component.final boolean
Indicates whether some other object is "equal to" this one.gameMode()
Returns the value of thegameMode
record component.final int
hashCode()
Returns a hash code value for this object.int
latency()
Returns the value of thelatency
record component.boolean
listed()
Returns the value of thelisted
record component.int
Returns the value of thelistOrder
record component.Returns the value of theplayerListName
record component.@Nullable com.mojang.authlib.GameProfile
profile()
Returns the value of theprofile
record component.Returns the value of theprofileId
record component.boolean
showHat()
Returns the value of theshowHat
record component.final String
toString()
Returns a string representation of this record class.
-
Constructor Details
-
PlayerData
public PlayerData(UUID profileId, @Nullable com.mojang.authlib.GameProfile profile, boolean listed, int latency, @Nullable GameMode gameMode, @Nullable Component playerListName, boolean showHat, int listOrder, @Nullable ChatSession chatSession) Creates an instance of aPlayerData
record class.- Parameters:
profileId
- the value for theprofileId
record componentprofile
- the value for theprofile
record componentlisted
- the value for thelisted
record componentlatency
- the value for thelatency
record componentgameMode
- the value for thegameMode
record componentplayerListName
- the value for theplayerListName
record componentshowHat
- the value for theshowHat
record componentlistOrder
- the value for thelistOrder
record componentchatSession
- the value for thechatSession
record component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object)
; primitive components are compared with '=='. -
profileId
Returns the value of theprofileId
record component.- Returns:
- the value of the
profileId
record component
-
profile
Returns the value of theprofile
record component.- Returns:
- the value of the
profile
record component
-
listed
public boolean listed()Returns the value of thelisted
record component.- Returns:
- the value of the
listed
record component
-
latency
public int latency()Returns the value of thelatency
record component.- Returns:
- the value of the
latency
record component
-
gameMode
Returns the value of thegameMode
record component.- Returns:
- the value of the
gameMode
record component
-
playerListName
Returns the value of theplayerListName
record component.- Returns:
- the value of the
playerListName
record component
-
showHat
public boolean showHat()Returns the value of theshowHat
record component.- Returns:
- the value of the
showHat
record component
-
listOrder
public int listOrder()Returns the value of thelistOrder
record component.- Returns:
- the value of the
listOrder
record component
-
chatSession
Returns the value of thechatSession
record component.- Returns:
- the value of the
chatSession
record component
-