bossbar

package
v0.21.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 7, 2022 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConvertFlags

func ConvertFlags(flags ...Flag) byte

ConvertFlags converts the given flags to the byte representation.

Types

type Action

type Action int
const (
	AddAction Action = iota
	RemoveAction
	UpdatePercentAction
	UpdateNameAction
	UpdateStyleAction
	UpdatePropertiesAction
)

type BossBar

type BossBar struct {
	ID      uuid.UUID
	Action  Action
	Name    component.Component
	Percent float32
	Color   Color
	Overlay Overlay
	Flags   byte
}

func (*BossBar) Decode

func (bb *BossBar) Decode(c *proto.PacketContext, rd io.Reader) (err error)

func (*BossBar) Encode

func (bb *BossBar) Encode(c *proto.PacketContext, wr io.Writer) error

type Color

type Color int
const (
	PinkColor Color = iota
	BlueColor
	RedColor
	GreenColor
	YellowColor
	PurpleColor
	WhiteColor
)

type Flag

type Flag int
const (
	DarkenScreenFlag   Flag = 0x01
	PlayBossMusicFlag  Flag = 0x02
	CreateWorldFogFlag Flag = 0x04
)

type Overlay

type Overlay int
const (
	ProgressOverlay Overlay = iota
	Notched6Overlay
	Notched10Overlay
	Notched12Overlay
	Notched20Overlay
)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL