外观
协议模型:S · 1
选择模型查看构造参数和字段,代码块保留完整模型名称。... 表示可省略的字段,省略时使用该类型的零值。
ScoreboardEntryScoreboardEntry_ScoreboardIdentityEntryScoreboardIdentityEntry_ScriptCustomEventScriptMessageServerBoundDiagnosticsServerBoundLoadingScreenServerBoundPackSettingChangeServerSettingsRequestServerSettingsResponseServerStatsServerToClientHandshakeSetActorDataSetActorLinkSetActorMotionSetCommandsEnabledSetDefaultGameTypeSetDifficultySetDimensionLocalTime
ScoreboardEntry
继承 Struct。
python
class ScoreboardEntry(_Struct):
EntryID: int
ObjectiveName: str | StringBytes
Score: int
IdentityType: int
EntityUniqueID: int
DisplayName: str | StringBytes
def __init__(self, /, *,
EntryID: int = ...,
ObjectiveName: str | StringBytes = ...,
Score: int = ...,
IdentityType: int = ...,
EntityUniqueID: int = ...,
DisplayName: str | StringBytes = ...,
) -> None: ...ScoreboardEntry_
继承 Struct。
python
class ScoreboardEntry_(_Struct):
ActionType: int
Entries: list[ScoreboardEntry] | tuple[ScoreboardEntry, ...] | None
def __init__(self, /, *,
ActionType: int = ...,
Entries: list[ScoreboardEntry] | tuple[ScoreboardEntry, ...] | None = ...,
) -> None: ...相关字段类型:ScoreboardEntry。
ScoreboardIdentityEntry
继承 Struct。
python
class ScoreboardIdentityEntry(_Struct):
EntryID: int
EntityUniqueID: int
def __init__(self, /, *,
EntryID: int = ...,
EntityUniqueID: int = ...,
) -> None: ...ScoreboardIdentityEntry_
继承 Struct。
python
class ScoreboardIdentityEntry_(_Struct):
ActionType: int
Entries: list[ScoreboardIdentityEntry] | tuple[ScoreboardIdentityEntry, ...] | None
def __init__(self, /, *,
ActionType: int = ...,
Entries: list[ScoreboardIdentityEntry] | tuple[ScoreboardIdentityEntry, ...] | None = ...,
) -> None: ...相关字段类型:ScoreboardIdentityEntry。
ScriptCustomEvent
继承 Packet。
python
class ScriptCustomEvent(_Packet):
packet_id: ClassVar[int] = 117
packet_name: ClassVar[str] = 'ScriptCustomEvent'
EventName: str | StringBytes
EventData: bytes | None
def __init__(self, /, *,
EventName: str | StringBytes = ...,
EventData: bytes | None = ...,
) -> None: ...ScriptMessage
继承 Packet。
python
class ScriptMessage(_Packet):
packet_id: ClassVar[int] = 177
packet_name: ClassVar[str] = 'ScriptMessage'
Identifier: str | StringBytes
Data: bytes | None
def __init__(self, /, *,
Identifier: str | StringBytes = ...,
Data: bytes | None = ...,
) -> None: ...ServerBoundDiagnostics
继承 Packet。
python
class ServerBoundDiagnostics(_Packet):
packet_id: ClassVar[int] = 315
packet_name: ClassVar[str] = 'ServerBoundDiagnostics'
AverageFramesPerSecond: float | FloatBits
AverageServerSimTickTime: float | FloatBits
AverageClientSimTickTime: float | FloatBits
AverageBeginFrameTime: float | FloatBits
AverageInputTime: float | FloatBits
AverageRenderTime: float | FloatBits
AverageEndFrameTime: float | FloatBits
AverageRemainderTimePercent: float | FloatBits
AverageUnaccountedTimePercent: float | FloatBits
def __init__(self, /, *,
AverageFramesPerSecond: float | FloatBits = ...,
AverageServerSimTickTime: float | FloatBits = ...,
AverageClientSimTickTime: float | FloatBits = ...,
AverageBeginFrameTime: float | FloatBits = ...,
AverageInputTime: float | FloatBits = ...,
AverageRenderTime: float | FloatBits = ...,
AverageEndFrameTime: float | FloatBits = ...,
AverageRemainderTimePercent: float | FloatBits = ...,
AverageUnaccountedTimePercent: float | FloatBits = ...,
) -> None: ...ServerBoundLoadingScreen
继承 Packet。
python
class ServerBoundLoadingScreen(_Packet):
packet_id: ClassVar[int] = 312
packet_name: ClassVar[str] = 'ServerBoundLoadingScreen'
Type: int
LoadingScreenID: OptionalValue[int]
def __init__(self, /, *,
Type: int = ...,
LoadingScreenID: OptionalValue[int] = ...,
) -> None: ...ServerBoundPackSettingChange
继承 Packet。
python
class ServerBoundPackSettingChange(_Packet):
packet_id: ClassVar[int] = 329
packet_name: ClassVar[str] = 'ServerBoundPackSettingChange'
PackID: bytes
PackSetting: PackSetting
def __init__(self, /, *,
PackID: bytes = ...,
PackSetting: PackSetting = ...,
) -> None: ...相关字段类型:PackSetting。
ServerSettingsRequest
继承 Packet。
python
class ServerSettingsRequest(_Packet):
packet_id: ClassVar[int] = 102
packet_name: ClassVar[str] = 'ServerSettingsRequest'
def __init__(self) -> None: ...ServerSettingsResponse
继承 Packet。
python
class ServerSettingsResponse(_Packet):
packet_id: ClassVar[int] = 103
packet_name: ClassVar[str] = 'ServerSettingsResponse'
FormID: int
FormData: bytes | None
def __init__(self, /, *,
FormID: int = ...,
FormData: bytes | None = ...,
) -> None: ...ServerStats
继承 Packet。
python
class ServerStats(_Packet):
packet_id: ClassVar[int] = 192
packet_name: ClassVar[str] = 'ServerStats'
ServerTime: float | FloatBits
NetworkTime: float | FloatBits
def __init__(self, /, *,
ServerTime: float | FloatBits = ...,
NetworkTime: float | FloatBits = ...,
) -> None: ...ServerToClientHandshake
继承 Packet。
python
class ServerToClientHandshake(_Packet):
packet_id: ClassVar[int] = 3
packet_name: ClassVar[str] = 'ServerToClientHandshake'
JWT: bytes | None
def __init__(self, /, *,
JWT: bytes | None = ...,
) -> None: ...SetActorData
继承 Packet。
python
class SetActorData(_Packet):
packet_id: ClassVar[int] = 39
packet_name: ClassVar[str] = 'SetActorData'
EntityRuntimeID: int
EntityMetadata: dict[int, DynamicValue | UnionValue | _Struct | None] | None
EntityProperties: EntityProperties
Tick: int
def __init__(self, /, *,
EntityRuntimeID: int = ...,
EntityMetadata: dict[int, DynamicValue | UnionValue | _Struct | None] | None = ...,
EntityProperties: EntityProperties = ...,
Tick: int = ...,
) -> None: ...相关字段类型:EntityProperties。
SetActorLink
继承 Packet。
python
class SetActorLink(_Packet):
packet_id: ClassVar[int] = 41
packet_name: ClassVar[str] = 'SetActorLink'
EntityLink: EntityLink
def __init__(self, /, *,
EntityLink: EntityLink = ...,
) -> None: ...相关字段类型:EntityLink。
SetActorMotion
继承 Packet。
python
class SetActorMotion(_Packet):
packet_id: ClassVar[int] = 40
packet_name: ClassVar[str] = 'SetActorMotion'
EntityRuntimeID: int
Velocity: list[float | FloatBits] | tuple[float | FloatBits, ...]
Tick: int
def __init__(self, /, *,
EntityRuntimeID: int = ...,
Velocity: list[float | FloatBits] | tuple[float | FloatBits, ...] = ...,
Tick: int = ...,
) -> None: ...SetCommandsEnabled
继承 Packet。
python
class SetCommandsEnabled(_Packet):
packet_id: ClassVar[int] = 59
packet_name: ClassVar[str] = 'SetCommandsEnabled'
Enabled: bool
def __init__(self, /, *,
Enabled: bool = ...,
) -> None: ...SetDefaultGameType
继承 Packet。
python
class SetDefaultGameType(_Packet):
packet_id: ClassVar[int] = 105
packet_name: ClassVar[str] = 'SetDefaultGameType'
GameType: int
def __init__(self, /, *,
GameType: int = ...,
) -> None: ...SetDifficulty
继承 Packet。
python
class SetDifficulty(_Packet):
packet_id: ClassVar[int] = 60
packet_name: ClassVar[str] = 'SetDifficulty'
Difficulty: int
def __init__(self, /, *,
Difficulty: int = ...,
) -> None: ...SetDimensionLocalTime
继承 Packet。
python
class SetDimensionLocalTime(_Packet):
packet_id: ClassVar[int] = 208
packet_name: ClassVar[str] = 'SetDimensionLocalTime'
HasData: bool
Time: int
DimensionID: int
def __init__(self, /, *,
HasData: bool = ...,
Time: int = ...,
DimensionID: int = ...,
) -> None: ...