Documentation ¶
Index ¶
- func AddEntities(world w.World, entityComponentList EntityComponentList) []ecs.Entity
- func AddEntityComponents(entity ecs.Entity, ecsComponentList interface{}, components interface{}) ecs.Entity
- func LoadControls(controlsConfigPath string, axes []string, actions []string) (resources.Controls, resources.InputHandler)
- func LoadEntities(entityMetadataContent []byte, world w.World, gameComponentList []interface{}) []ecs.Entity
- func LoadFonts(fontPath string) map[string]resources.Font
- func LoadSpriteSheets(spriteSheetMetadataPath string) map[string]c.SpriteSheet
- type EngineComponentList
- type EntityComponentList
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddEntities ¶
func AddEntities(world w.World, entityComponentList EntityComponentList) []ecs.Entity
AddEntities adds entities with engine and game components
func AddEntityComponents ¶
func AddEntityComponents(entity ecs.Entity, ecsComponentList interface{}, components interface{}) ecs.Entity
AddEntityComponents adds loaded components to an entity
func LoadControls ¶
func LoadControls(controlsConfigPath string, axes []string, actions []string) (resources.Controls, resources.InputHandler)
LoadControls loads controls from a TOML file
func LoadEntities ¶
func LoadEntities(entityMetadataContent []byte, world w.World, gameComponentList []interface{}) []ecs.Entity
LoadEntities creates entities with components from a TOML file
func LoadSpriteSheets ¶
func LoadSpriteSheets(spriteSheetMetadataPath string) map[string]c.SpriteSheet
LoadSpriteSheets loads sprite sheets from a TOML file
Types ¶
type EngineComponentList ¶
type EngineComponentList struct {
SpriteRender *c.SpriteRender
}
EngineComponentList is the list of engine components
func LoadEngineComponents ¶
func LoadEngineComponents(entityMetadataContent []byte, world w.World) []EngineComponentList
LoadEngineComponents loads engine components from a TOML byte slice
type EntityComponentList ¶
type EntityComponentList struct { Engine []EngineComponentList Game []interface{} }
EntityComponentList is a list of preloaded entities with components
Click to show internal directories.
Click to hide internal directories.