bot can receive chunks now

This commit is contained in:
Tnze
2022-03-13 11:57:02 +08:00
parent d8695636b6
commit 2aace6b51a
17 changed files with 452 additions and 78 deletions

View File

@ -11,7 +11,7 @@ import (
// WorldInfo content player info in server.
type WorldInfo struct {
DimensionCodec nbt.StringifiedMessage
Dimension nbt.StringifiedMessage
Dimension Dimension
WorldNames []string // Identifiers for all worlds on the server.
WorldName string // Name of the world being spawned into.
HashedSeed int64 // First 8 bytes of the SHA-256 hash of the world's seed. Used client side for biome noise
@ -24,6 +24,25 @@ type WorldInfo struct {
IsFlat bool // True if the world is a superflat world; flat worlds have different void fog and a horizon at y=0 instead of y=63.
}
type Dimension struct {
PiglinSafe int8 `nbt:"piglin_safe"`
Natural int8 `nbt:"natural"`
AmbientLight float32 `nbt:"ambient_light"`
FixedTime *int64 `nbt:"fixed_time"`
Infiniburn string `nbt:"infiniburn"`
RespawnAnchorWorks int8 `nbt:"respawn_anchor_works"`
HasSkylight int8 `nbt:"has_skylight"`
BedWorks int8 `nbt:"bed_works"`
Effects string `nbt:"effects"`
HasRaids int8 `nbt:"has_raids"`
LogicalHeight int32 `nbt:"logical_height"`
CoordinateScale float64 `nbt:"coordinate_scale"`
MinY int32 `nbt:"min_y"`
HasCeiling int8 `nbt:"has_ceiling"`
Ultrawarm int8 `nbt:"ultrawarm"`
Height int32 `nbt:"height"`
}
type PlayerInfo struct {
EID int32 // The player's Entity ID (EID).
Hardcore bool // Is hardcore