assets

package
v0.0.0-...-c5e16f4 Latest Latest
Warning

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

Go to latest
Published: Nov 14, 2020 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var BlockDict = make(map[string]Block)

BlockDict keeps track of all the blocks that we've loaded

View Source
var TexDict = make(map[string]*material.Standard)

TexDict keeps track of all the Texutures that we've loaded

Functions

func LoadAssets

func LoadAssets()

LoadAssets go through all our assets and loads them

Types

type Asset

type Asset interface {
	AssetFullPath()
}

Asset is used to represent all the things we can load from configs

type Block

type Block struct {
	Name       string
	Pretty     string
	Path       string
	Toughness  int
	Substances []string
	Faces      map[string]string
}

Block as parsed from our json

func (Block) FullPath

func (b Block) FullPath() string

FullPath for it's fully qualified id

func (Block) TexturePath

func (b Block) TexturePath() string

TexturePath is the path of the texture directory for this block

Jump to

Keyboard shortcuts

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