Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Entity ¶
type Entity interface { Type() *EntityType ID() int32 UUID() uuid.UUID // contains filtered or unexported methods }
type EntityRunner ¶
type EntityRunner struct { TPS int // contains filtered or unexported fields }
func (*EntityRunner) Run ¶
func (t *EntityRunner) Run()
type EntityType ¶
type EntityType struct { ID int `json:"id"` Name string `json:"name"` DisplayName string `json:"displayName"` Width float32 `json:"width"` Height float32 `json:"height"` }
func ByName ¶
func ByName(name string) *EntityType
type LivingEntity ¶
type LivingEntity struct { X float64 Y float64 Z float64 HeadPitch byte HeadYaw byte Pitch byte Yaw byte // contains filtered or unexported fields }
func NewLivingEntity ¶
func NewLivingEntity(entityType *EntityType, uuid uuid.UUID, processor func(e *LivingEntity, time time.Time) error) *LivingEntity
func (*LivingEntity) ID ¶
func (e *LivingEntity) ID() int32
func (*LivingEntity) IsDead ¶
func (e *LivingEntity) IsDead() bool
func (*LivingEntity) Kill ¶
func (e *LivingEntity) Kill()
func (*LivingEntity) Type ¶
func (e *LivingEntity) Type() *EntityType
func (*LivingEntity) UUID ¶
func (e *LivingEntity) UUID() uuid.UUID
type ObjectEntity ¶
type ObjectEntity struct { X float64 Y float64 Z float64 Pitch byte Yaw byte VelocityX int16 VelocityY int16 VelocityZ int16 ObjectData int32 // contains filtered or unexported fields }
func NewObjectEntity ¶
func NewObjectEntity(entityType *EntityType, entityId int32, uuid uuid.UUID, processor func(e *ObjectEntity, time time.Time) error) *ObjectEntity
func (*ObjectEntity) ID ¶
func (e *ObjectEntity) ID() int32
func (*ObjectEntity) Remove ¶
func (e *ObjectEntity) Remove()
func (*ObjectEntity) Type ¶
func (e *ObjectEntity) Type() *EntityType
func (*ObjectEntity) UUID ¶
func (e *ObjectEntity) UUID() uuid.UUID
Click to show internal directories.
Click to hide internal directories.