webserver

package
v0.12.0 Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2021 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AbortingMapGeneration added in v0.1.0

func AbortingMapGeneration(ctx echo.Context, rules game.GameRules, requestInfo model.RequestInfo) error

AbortingMapGeneration handles aborting the attempt to generate a map, handle the error and send a response to the affected client

func GetGameRulesFromRequest added in v0.1.0

func GetGameRulesFromRequest(c echo.Context) game.GameRules

func GetMap

func GetMap(c echo.Context) error

GetMap starts the Generation Cycle, which may or may not succeed with a valid map according to the supplied Game Rules

func GetMapByCode added in v0.1.0

func GetMapByCode(ctx echo.Context) error

GetMap starts the Generation Cycle, which may or may not succeed with a valid map according to the supplied Game Rules

func GetMapCode added in v0.1.0

func GetMapCode(c echo.Context) error

GetMapCode starts the Generation Cycle, which may or may not succeed with a valid map according to the supplied Game Rules It is different from GetMap because it only returns the game code

func GetMapLegend

func GetMapLegend(c echo.Context) error

GetMapLegend retrieves the map Legend, helps explain codes used within the data returned by the API

func GetMapViaCodeGeneration added in v0.1.0

func GetMapViaCodeGeneration(c echo.Context) error

GetMapViaCodeGeneration Alternative approach to generating the map instead of generating the map via the structs, we generate a game code and then inflate the game code before validating the board WARNING: currently only supports default normal map

func GetRequestInfoFromRequest added in v0.1.0

func GetRequestInfoFromRequest(c echo.Context) model.RequestInfo

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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