@serenityjs/protocol 0.2.4-beta-20240529224507 → 0.2.4-beta-20240531034203

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -44,7 +44,8 @@ declare enum Packet {
44
44
  PlayerList = 63,// 63
45
45
  RequestChunkRadius = 69,// 69
46
46
  ChunkRadiusUpdate = 70,// 70
47
- AvailableCommands = 76,
47
+ BossEvent = 74,// 74
48
+ AvailableCommands = 76,// 76
48
49
  CommandRequest = 77,// 77
49
50
  CommandOutput = 79,// 79
50
51
  ResourcePackDataInfo = 82,// 82
@@ -1634,6 +1635,29 @@ declare enum Enchantment {
1634
1635
  Unknown = 39
1635
1636
  }
1636
1637
 
1638
+ declare enum BossEventUpdateType {
1639
+ Add = 0,
1640
+ PlayerAdded = 1,
1641
+ Remove = 2,
1642
+ PlayerRemoved = 3,
1643
+ UpdatePercent = 4,
1644
+ UpdateName = 5,
1645
+ UpdateProperties = 6,
1646
+ UpdateStyle = 7,
1647
+ Query = 8
1648
+ }
1649
+
1650
+ declare enum BossEventColor {
1651
+ Pink = 0,
1652
+ Blue = 1,
1653
+ Red = 2,
1654
+ Green = 3,
1655
+ Yellow = 4,
1656
+ Magenta = 5,
1657
+ Purple = 6,
1658
+ White = 7
1659
+ }
1660
+
1637
1661
  declare class LoginTokens extends DataType {
1638
1662
  client: string;
1639
1663
  identity: string;
@@ -3014,6 +3038,29 @@ declare class HUDElement extends DataType {
3014
3038
  static write(stream: BinaryStream, value: Array<HUDElement>): void;
3015
3039
  }
3016
3040
 
3041
+ declare class BossEventAdd extends DataType {
3042
+ readonly title: string;
3043
+ readonly percent: number;
3044
+ readonly darkenScreen: number;
3045
+ readonly color: BossEventColor;
3046
+ readonly overlay: number;
3047
+ constructor(title: string, percent: number, darkenScreen: number, color: BossEventColor, overlay: number);
3048
+ static read(stream: BinaryStream, _endian: Endianness, type: BossEventUpdateType): BossEventAdd | null;
3049
+ static write(stream: BinaryStream, value: BossEventAdd, _endian: Endianness, type: BossEventUpdateType): void;
3050
+ }
3051
+
3052
+ declare class BossEventUpdate extends DataType {
3053
+ readonly playerUniqueId?: bigint | null;
3054
+ readonly percent?: number | null;
3055
+ readonly title?: string | null;
3056
+ readonly darkenScreen?: number | null;
3057
+ readonly color?: BossEventColor | null;
3058
+ readonly overlay?: number | null;
3059
+ constructor(playerUniqueId?: bigint | null, percent?: number | null, title?: string | null, darkenScreen?: number | null, color?: BossEventColor | null, overlay?: number | null);
3060
+ static read(stream: BinaryStream, _endian: Endianness, type: BossEventUpdateType): BossEventUpdate | null;
3061
+ static write(stream: BinaryStream, value: BossEventUpdate, _endian: Endianness, type: BossEventUpdateType): void;
3062
+ }
3063
+
3017
3064
  /**
3018
3065
  * Represents a Minecraft Bedrock Edition data packet
3019
3066
  */
@@ -3594,6 +3641,13 @@ declare class NetworkStackLatencyPacket extends DataPacket {
3594
3641
  fromServer: boolean;
3595
3642
  }
3596
3643
 
3644
+ declare class BossEventPacket extends DataPacket {
3645
+ targetUniqueId: bigint;
3646
+ type: BossEventUpdateType;
3647
+ add: BossEventAdd;
3648
+ update: BossEventUpdate;
3649
+ }
3650
+
3597
3651
  declare const Packets: {
3598
3652
  1: typeof LoginPacket;
3599
3653
  2: typeof PlayStatusPacket;
@@ -3635,6 +3689,7 @@ declare const Packets: {
3635
3689
  63: typeof PlayerListPacket;
3636
3690
  69: typeof RequestChunkRadiusPacket;
3637
3691
  70: typeof ChunkRadiusUpdatePacket;
3692
+ 74: typeof BossEventPacket;
3638
3693
  76: typeof AvailableCommandsPacket;
3639
3694
  77: typeof CommandRequestPacket;
3640
3695
  79: typeof CommandOutputPacket;
@@ -3688,4 +3743,4 @@ declare const PROTOCOL_VERSION = 671;
3688
3743
  declare const MINECRAFT_VERSION = "1.20.80";
3689
3744
  declare const MINECRAFT_TICK_SPEED = 50;
3690
3745
 
3691
- export { AbilityLayerFlag, AbilityLayerType, AbilityLayers, AbilitySet, ActionIds, AddEntityPacket, AddItemActorPacket, AddPlayerPacket, AnimateAction, AnimateId, AnimatePacket, Attribute, AvailableCommandsPacket, BehaviorPackInfo, BiomeDefinitionListPacket, BlockCoordinates, BlockFace, BlockPickRequestPacket, BlockProperties, ChainedSubcommandValues, ChangeDimensionPacket, ChunkCoords, ChunkRadiusUpdatePacket, CommandOriginData, CommandOutputData, CommandOutputMessage, CommandOutputPacket, CommandParameterType, CommandPermissionLevel, CommandRequestPacket, Commands, ComplexInventoryTransaction, ComponentItem, CompressionMethod, ContainerClosePacket, ContainerId, ContainerName, ContainerOpenPacket, ContainerType, CreativeContentPacket, CreativeItems, DataPacket, DeviceOS, Difficulty, DimensionType, DisconnectPacket, DisconnectReason, DisplaySlotType, DynamicEnums, Enchantment, EntityAttributes, EntityProperties, EnumConstraints, EnumValues, Enums, Experiments, Framer, GameRuleType, GameRules, Gamemode, HUDElement, HUDElementId, HUDVisibility, InteractActions, InteractPacket, InteractPosition, InventoryAction, InventoryContentPacket, InventorySlotPacket, InventorySource, InventorySourceType, InventoryTransaction, InventoryTransactionPacket, ItemComponentPacket, ItemData, ItemInstanceUserData, ItemReleaseInventoryTransaction, ItemReleaseInventoryTransactionType, type ItemStackAction, ItemStackActionType, type ItemStackContainer, ItemStackRequestPacket, ItemStackRequests, ItemStackResponsePacket, ItemStackResponses, ItemStackStatus, ItemStacks, ItemUseInventoryTransaction, ItemUseInventoryTransactionType, ItemUseOnEntityInventoryTransaction, ItemUseOnEntityInventoryTransactionType, LegacyTransaction, LevelChunkPacket, LevelEvent, LevelEventPacket, LevelSoundEvent, LevelSoundEventPacket, Links, LoginPacket, LoginTokens, MINECRAFT_TICK_SPEED, MINECRAFT_VERSION, MetadataDictionary, MetadataFlags, MetadataKey, MetadataType, MobEquipmentPacket, ModalFormCanceled, ModalFormCanceledReason, ModalFormData, ModalFormRequestPacket, ModalFormResponsePacket, ModalFormType, MoveActorAbsolutePacket, MoveMode, MovePlayerPacket, NetworkChunkPublisherUpdatePacket, NetworkItemInstanceDescriptor, NetworkItemStackDescriptor, NetworkSettingsPacket, NetworkStackLatencyPacket, ObjectiveSortOrder, PROTOCOL_VERSION, PackLinks, PackType, Packet, PacketViolationWarningPacket, Packets, PermissionLevel, PlayStatus, PlayStatusPacket, PlayerActionPacket, PlayerAttributes, PlayerAuthInputData, PlayerAuthInputPacket, PlayerHotbarPacket, PlayerListAction, PlayerListPacket, PlayerListRecord, PostFixes, RemoveEntityPacket, RemoveObjectivePacket, RequestChunkRadiusPacket, RequestNetworkSettingsPacket, ResourceIdVersions, ResourcePackChunkDataPacket, ResourcePackChunkRequestPacket, ResourcePackClientResponsePacket, ResourcePackDataInfoPacket, ResourcePackIds, ResourcePackResponse, ResourcePackStackPacket, ResourcePacksInfoPacket, RespawnPacket, RespawnState, Rotation, ScoreActionType, ScoreEntry, ScoreEntryType, ScoreboardIdentity, ScoreboardIdentityAction, ScriptMessagePacket, SerializedSkin, SetActorMotionPacket, SetCommandsEnabledPacket, SetDisplayObjectivePacket, SetEntityDataPacket, SetHudPacket, SetLocalPlayerAsInitializedPacket, SetPlayerGameTypePacket, SetScorePacket, SetScoreboardIdentityPacket, SetTimePacket, SetTitlePacket, SkinAnimation, SkinImage, SkinPersonaPiece, SkinPersonaTintPiece, StackRequestSlotInfo, StartGamePacket, Subcommands, TakeItemActorPacket, TeleportCause, TextPacket, TextPacketType, TextParameters, TextSource, TexturePackInfo, TitleTypes, ToastRequestPacket, TransactionSourceType, TransferPacket, UpdateAbilitiesPacket, UpdateAdventureSettingsPacket, UpdateAttributesPacket, UpdateBlockFlagsType, UpdateBlockLayerType, UpdateBlockPacket, VariableStringArray as VarStringArray, VarintArray, Vector2f, Vector3f, ViolationSeverity, ViolationType, getPacketId };
3746
+ export { AbilityLayerFlag, AbilityLayerType, AbilityLayers, AbilitySet, ActionIds, AddEntityPacket, AddItemActorPacket, AddPlayerPacket, AnimateAction, AnimateId, AnimatePacket, Attribute, AvailableCommandsPacket, BehaviorPackInfo, BiomeDefinitionListPacket, BlockCoordinates, BlockFace, BlockPickRequestPacket, BlockProperties, BossEventAdd, BossEventColor, BossEventPacket, BossEventUpdate, BossEventUpdateType, ChainedSubcommandValues, ChangeDimensionPacket, ChunkCoords, ChunkRadiusUpdatePacket, CommandOriginData, CommandOutputData, CommandOutputMessage, CommandOutputPacket, CommandParameterType, CommandPermissionLevel, CommandRequestPacket, Commands, ComplexInventoryTransaction, ComponentItem, CompressionMethod, ContainerClosePacket, ContainerId, ContainerName, ContainerOpenPacket, ContainerType, CreativeContentPacket, CreativeItems, DataPacket, DeviceOS, Difficulty, DimensionType, DisconnectPacket, DisconnectReason, DisplaySlotType, DynamicEnums, Enchantment, EntityAttributes, EntityProperties, EnumConstraints, EnumValues, Enums, Experiments, Framer, GameRuleType, GameRules, Gamemode, HUDElement, HUDElementId, HUDVisibility, InteractActions, InteractPacket, InteractPosition, InventoryAction, InventoryContentPacket, InventorySlotPacket, InventorySource, InventorySourceType, InventoryTransaction, InventoryTransactionPacket, ItemComponentPacket, ItemData, ItemInstanceUserData, ItemReleaseInventoryTransaction, ItemReleaseInventoryTransactionType, type ItemStackAction, ItemStackActionType, type ItemStackContainer, ItemStackRequestPacket, ItemStackRequests, ItemStackResponsePacket, ItemStackResponses, ItemStackStatus, ItemStacks, ItemUseInventoryTransaction, ItemUseInventoryTransactionType, ItemUseOnEntityInventoryTransaction, ItemUseOnEntityInventoryTransactionType, LegacyTransaction, LevelChunkPacket, LevelEvent, LevelEventPacket, LevelSoundEvent, LevelSoundEventPacket, Links, LoginPacket, LoginTokens, MINECRAFT_TICK_SPEED, MINECRAFT_VERSION, MetadataDictionary, MetadataFlags, MetadataKey, MetadataType, MobEquipmentPacket, ModalFormCanceled, ModalFormCanceledReason, ModalFormData, ModalFormRequestPacket, ModalFormResponsePacket, ModalFormType, MoveActorAbsolutePacket, MoveMode, MovePlayerPacket, NetworkChunkPublisherUpdatePacket, NetworkItemInstanceDescriptor, NetworkItemStackDescriptor, NetworkSettingsPacket, NetworkStackLatencyPacket, ObjectiveSortOrder, PROTOCOL_VERSION, PackLinks, PackType, Packet, PacketViolationWarningPacket, Packets, PermissionLevel, PlayStatus, PlayStatusPacket, PlayerActionPacket, PlayerAttributes, PlayerAuthInputData, PlayerAuthInputPacket, PlayerHotbarPacket, PlayerListAction, PlayerListPacket, PlayerListRecord, PostFixes, RemoveEntityPacket, RemoveObjectivePacket, RequestChunkRadiusPacket, RequestNetworkSettingsPacket, ResourceIdVersions, ResourcePackChunkDataPacket, ResourcePackChunkRequestPacket, ResourcePackClientResponsePacket, ResourcePackDataInfoPacket, ResourcePackIds, ResourcePackResponse, ResourcePackStackPacket, ResourcePacksInfoPacket, RespawnPacket, RespawnState, Rotation, ScoreActionType, ScoreEntry, ScoreEntryType, ScoreboardIdentity, ScoreboardIdentityAction, ScriptMessagePacket, SerializedSkin, SetActorMotionPacket, SetCommandsEnabledPacket, SetDisplayObjectivePacket, SetEntityDataPacket, SetHudPacket, SetLocalPlayerAsInitializedPacket, SetPlayerGameTypePacket, SetScorePacket, SetScoreboardIdentityPacket, SetTimePacket, SetTitlePacket, SkinAnimation, SkinImage, SkinPersonaPiece, SkinPersonaTintPiece, StackRequestSlotInfo, StartGamePacket, Subcommands, TakeItemActorPacket, TeleportCause, TextPacket, TextPacketType, TextParameters, TextSource, TexturePackInfo, TitleTypes, ToastRequestPacket, TransactionSourceType, TransferPacket, UpdateAbilitiesPacket, UpdateAdventureSettingsPacket, UpdateAttributesPacket, UpdateBlockFlagsType, UpdateBlockLayerType, UpdateBlockPacket, VariableStringArray as VarStringArray, VarintArray, Vector2f, Vector3f, ViolationSeverity, ViolationType, getPacketId };