worldstore

package
v0.0.0-...-93088af Latest Latest
Warning

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

Go to latest
Published: Apr 5, 2013 License: MIT Imports: 12 Imported by: 0

Documentation

Overview

Responsible for reading the overall world persistent state. Eventually this should also be responsible for writing it as well.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateWorld

func CreateWorld(worldPath string) (err error)

Creates a new world at 'worldPath'

Types

type BadType

type BadType string

func (BadType) Error

func (err BadType) Error() string

type WorldStore

type WorldStore struct {
	WorldPath string

	Seed int64
	Time Ticks

	LevelData     nbt.ITag
	ChunkStore    chunkstore.IChunkStore
	SpawnPosition BlockXyz
}

func LoadWorldStore

func LoadWorldStore(worldPath string) (world *WorldStore, err error)

func (*WorldStore) ChunkStoreForDimension

func (world *WorldStore) ChunkStoreForDimension(dimension DimensionId) (store chunkstore.IChunkStore, err error)

NOTE: ChunkStoreForDimension shouldn't really be used in the server just yet.

func (*WorldStore) PlayerData

func (world *WorldStore) PlayerData(user string) (playerData nbt.Compound, err error)

func (*WorldStore) WritePlayerData

func (world *WorldStore) WritePlayerData(user string, data nbt.Compound) (err error)

Jump to

Keyboard shortcuts

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