commit 924b605f6edf0db60e138a4fc3a066efdc9abc58 Author: Jerry Aldrich Date: Sat Apr 18 23:58:12 2020 -0700 Initial commit diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..a007fea --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +build/* diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..5ea6cfa --- /dev/null +++ b/Dockerfile @@ -0,0 +1,21 @@ +FROM golang:alpine AS builder + +RUN apk add --no-cache make + +WORKDIR $GOPATH/src/ +COPY . . + +RUN make build + +RUN mkdir -p /dist +RUN cp -R build/dist/ /dist + +FROM alpine + +COPY --from=builder /dist/* /mazerats/ + +EXPOSE 8080 + +WORKDIR /mazerats + +CMD ["./mrg", "server"] diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..ee2d0cd --- /dev/null +++ b/Makefile @@ -0,0 +1,16 @@ +ifndef $(GOPATH) + GOPATH=$(shell go env GOPATH) + export GOPATH +endif + +build: install_prerequisites bindata + $(GOPATH)/bin/swag init -o web/swagger + CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o ./build/dist/mrg + $(shell cp -r web ./build/dist/) + +bindata: install_prerequisites + $(GOPATH)/bin/go-bindata -pkg bindata -o assets/bindata/bindata.go -prefix internal/data internal/data web + +install_prerequisites: + go get -u github.com/swaggo/swag/cmd/swag + go get -u github.com/go-bindata/go-bindata/... diff --git a/README.md b/README.md new file mode 100644 index 0000000..5b5c183 --- /dev/null +++ b/README.md @@ -0,0 +1,21 @@ +# Maze Rats Generator + +Use this to generate Maze Rats things (see `mrg -h`). + +You can also run `mrg server` to create a web server with a REST API. + +Docs can be viewed at [http://localhost:8080](http://localhost:8080). + +## Building + +Run `make build` then copy `build/dist/` to where you want to execute. + +## Docker + +``` +docker build . -t yourorigin/mazerats:latest + +docker run --rm -it \ + -p 8080:8080 + - + diff --git a/TODO.md b/TODO.md new file mode 100644 index 0000000..feb132e --- /dev/null +++ b/TODO.md @@ -0,0 +1,10 @@ +Things I'd like to do/fix: + - `go get -u github.com/swaggo/swag/cmd/swag` in Docker + - Search for "existing" in returned table text and replace with generated things + - NOTE: Faction may be easiest + - Replace 1d6 rolls with helper + - Get rid of helpers.go + - Cross-platform shell in Makefile + - Figure out how to distribute web/ in binaryfile + - Add PORT env var/flag (super easy) + - Generate truly unique list of items (handle impossible requests, expensive computation) diff --git a/assets/bindata/bindata.go b/assets/bindata/bindata.go new file mode 100644 index 0000000..720aa13 --- /dev/null +++ b/assets/bindata/bindata.go @@ -0,0 +1,428 @@ +// Code generated for package bindata by go-bindata DO NOT EDIT. (@generated) +// sources: +// internal/data/character.json +// internal/data/city.json +// internal/data/data.go +// internal/data/magic.json +// internal/data/maze.json +// internal/data/monster.json +// internal/data/npc.json +// internal/data/treasure.json +// internal/data/wild.json +package bindata + +import ( + "bytes" + "compress/gzip" + "fmt" + "io" + "io/ioutil" + "os" + "path/filepath" + "strings" + "time" +) + +func bindataRead(data []byte, name string) ([]byte, error) { + gz, err := gzip.NewReader(bytes.NewBuffer(data)) + if err != nil { + return nil, fmt.Errorf("Read %q: %v", name, err) + } + + var buf bytes.Buffer + _, err = io.Copy(&buf, gz) + clErr := gz.Close() + + if err != nil { + return nil, fmt.Errorf("Read %q: %v", name, err) + } + if clErr != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +type asset struct { + bytes []byte + info os.FileInfo +} + +type bindataFileInfo struct { + name string + size int64 + mode os.FileMode + modTime time.Time +} + +// Name return file name +func (fi bindataFileInfo) Name() string { + return fi.name +} + +// Size return file size +func (fi bindataFileInfo) Size() int64 { + return fi.size +} + +// Mode return file mode +func (fi bindataFileInfo) Mode() os.FileMode { + return fi.mode +} + +// Mode return file modify time +func (fi bindataFileInfo) ModTime() time.Time { + return fi.modTime +} + +// IsDir return file whether a directory +func (fi bindataFileInfo) IsDir() bool { + return fi.mode&os.ModeDir != 0 +} + +// Sys return file is sys mode +func (fi bindataFileInfo) Sys() interface{} { + return nil +} + +var _characterJson = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x5c\x57\x51\x93\xdb\xb8\x0d\x7e\xcf\xaf\xe0\xec\x53\x32\x8d\x3b\xbd\xe9\xf4\xa5\x6f\x59\x6f\xbc\x7b\x77\x71\xb2\x5d\x6d\x6e\x1f\x6e\x6e\x3a\x30\x05\x4b\xa8\x28\x42\x01\x49\xfb\x94\x4e\xff\x7b\x87\x04\x65\x6b\xf3\x64\x90\x14\x40\x10\xf8\xf0\x01\xfe\xef\x1b\x63\x6e\x60\x9a\x10\x04\xbc\xc5\x9b\x7f\x9a\xdf\xdf\x18\x63\xcc\xef\x37\x1f\xbe\x25\x72\xe4\xf1\xe6\xbd\xb9\xf9\x10\x7b\x87\x91\x6c\x96\x6f\x41\x04\xdd\x66\xdb\x63\x88\xd8\x96\x1d\xf6\x38\x17\x41\xe0\xec\xab\x94\x22\x85\xfe\xe6\x8f\xf7\xd5\xda\x6d\x72\xce\xa3\x1d\x54\x63\xdb\x53\x40\x57\x65\x76\xe5\xd3\x22\xca\x94\x1c\xfa\x58\x16\x02\x5d\x57\x8c\xdd\xa1\x23\x0b\x11\xaf\xd6\x76\x49\x84\xcf\xaa\x7f\x0f\x49\x15\xee\x59\x3a\xe4\x14\x8a\x2c\xf4\xfd\x7b\xbd\xe0\x01\xba\x0e\xa4\x8a\xbe\x0d\x3c\xae\x2c\x3d\x50\xbb\xe8\x7c\x02\x3f\x94\xfb\x1e\x53\xab\x17\x3f\xd1\x34\xa9\x8d\x27\x0e\x65\xa7\xb1\xfa\xc4\x8b\x7e\x43\x1e\xcf\x7a\xe4\xd0\xb7\x28\x2a\xa6\xb1\x2a\x36\xec\x48\x85\x6f\x09\x04\x37\xbf\x40\x75\xbb\x89\x10\x13\x86\x6f\x69\xe5\xcc\x33\x9f\x51\xc8\x77\xf9\xfc\x59\x68\xcc\xbf\x2f\x08\xb1\x47\x51\xa5\x17\x72\x8e\xf5\xba\x17\x12\xfd\x15\xf2\x43\x7e\xe9\x1f\x6f\x8c\x29\x96\x6e\xac\xe3\xd8\x67\x33\xab\x64\xfa\x48\xf9\xaa\x92\xbf\x18\x1d\x6e\x22\x8b\x2f\x4b\x6c\x73\xa0\x6b\xac\x6e\x1d\x73\xbb\x09\x11\xc8\xd7\xec\xa0\xe0\xc8\x9e\xc0\x95\x4c\x40\x4e\xf9\xc5\xdf\x3b\xb4\x30\x57\x7f\x3f\x5a\x8b\x3e\x8a\x62\xe4\xa3\xc3\x0e\x34\x2b\x1f\xc7\x83\x30\xb5\xcb\x0b\x3e\xfe\xc9\x15\x47\x3b\x08\x3d\xb1\x87\x83\x5b\x27\xd6\xc1\x78\xe0\xb9\xea\xee\x7e\x70\x66\xc7\x32\xaa\x23\x3b\x81\xb9\xee\x49\x1a\xa7\x59\x81\x20\xaf\x20\x77\x2f\x34\xce\x9a\xf5\x14\xd1\x58\x4e\x31\x09\x6a\xa6\xad\x02\xf6\x13\x9d\x50\xc3\xb8\x4f\xaf\x6e\xfa\x12\x22\xfa\x08\x91\x32\x36\x2e\x16\xbf\x9c\x50\x02\x7d\xd7\x4f\x1e\x21\xda\xfe\x22\x46\x94\xaa\xfa\x88\x72\x4c\x63\x95\x05\x6c\x24\xab\x3e\x3f\xa5\x71\x72\xeb\xf0\x35\xd4\x91\x2b\xd0\x6b\xc8\x77\xaa\xf1\x0c\x21\xa2\xc3\x50\xb6\xbf\x66\x40\x5d\x2e\x7c\x21\x8f\x6b\x1f\x5f\x58\xbc\xe1\x14\x57\x99\x3f\x80\x1d\x3a\xe1\xe4\xdb\x75\xee\x9d\xed\x71\xa4\x10\x35\xdd\x5d\x87\xb2\x99\x84\x72\xb5\x97\x8c\x83\x1d\x46\x20\xa7\xd0\xbd\xe5\xe4\xe3\xbc\xe9\x93\x8f\xba\xb1\xed\x69\xf4\x38\x9b\x70\x46\x9c\xb4\x48\xc9\x6f\xac\xcb\xa5\x21\xd7\xb7\x6c\xd9\x47\x96\x48\xec\xeb\x45\x5b\x2e\x26\x8e\x48\x8b\xa1\x94\xeb\x5c\xcf\x52\x9c\x92\x04\xd4\xe2\x3e\xc4\x8d\x65\xe7\xd0\x46\x16\xdd\x09\x28\x71\x6d\x7c\x87\xd5\xd9\x1d\x4b\x4c\x1e\x23\xba\xea\xee\x3d\x38\x97\x9d\x73\x70\x42\x5d\x8f\x87\xe5\x48\xe0\x84\x2d\xe5\xe7\x16\x10\x20\xb4\x61\x04\xbf\x2a\x7d\x6c\x3b\x34\x83\xa7\xae\x2f\x5e\x3d\x50\xd7\x9f\x61\xce\xdf\xe4\x15\xa7\x80\x07\x41\x18\x54\xff\x57\x6a\x3d\x94\x37\x67\xb4\x40\x6b\x26\xe1\xa9\xc7\xa2\xb9\x2f\x6f\x3d\x80\x1f\xae\xd6\x1f\xb1\x6d\xab\x27\x8f\x14\x37\xc7\x7c\x4b\x5d\x32\x05\xf6\x2a\x3f\x41\xdc\xd8\x02\x24\xa9\xf4\x42\x27\xac\x67\x0d\x3a\x17\xce\x2c\x6b\xc4\x2c\xef\x6c\xc6\x94\x6b\x56\xbf\x8b\x82\x18\xcd\x84\x72\x64\x19\x75\xef\x19\x22\x73\x8d\xf6\x57\xb1\x3d\x95\x37\x7d\x0d\x49\x72\x5c\x2f\x78\xa1\x88\x63\x78\x45\x13\x34\x82\x33\x8d\xad\x1c\x7c\x8b\x20\xe6\x59\x60\x5a\x98\x82\x5d\x81\xf2\x16\x5c\x14\x9e\x82\x02\x04\xc8\x9b\xb7\x3f\xfd\xcd\x1c\xe3\x5f\xdf\xd5\x1d\xb7\x8a\x84\x92\xbd\x52\x3a\x9f\x0f\x50\x1c\xdc\x51\xc8\x14\x65\x3e\x6b\x04\xef\x1d\x84\x60\xf6\x20\x07\x87\x4a\xe0\x4e\xd9\xea\x5e\x60\x9a\x5c\xfe\xf2\x81\x79\x58\x17\x37\x82\x02\xe8\x01\xec\x10\xe0\xac\xe2\x58\xdf\x9f\x89\xde\xb4\x42\xea\xee\x43\xe5\xba\x9f\x85\xbd\x09\x13\x0d\xb8\x2a\xea\xb2\x19\xd9\x77\x4b\x13\xc8\xa5\x6c\xb2\xfe\x17\x72\xba\x25\x1d\x9a\x06\xec\x50\x56\x6c\x87\x89\xec\x10\xcc\xdb\xbf\xbf\x53\x2c\x78\xb0\xd5\xeb\x3d\xb6\x64\xc9\x63\x39\xbb\xdc\xb0\xc7\x08\xce\x1c\xc9\x61\x4d\x39\xb1\xbf\xa8\x3f\xf1\x84\xe6\xed\x3f\xae\xd1\x6b\x22\xa2\x33\x67\x52\xaa\x6a\x7a\x3e\x69\xf0\x74\x7f\x24\x11\x5e\x95\xc6\x33\x7a\xb3\x63\x8e\xe6\x91\xd5\xfc\x33\x65\xd2\x38\xf0\x9f\x65\xc1\x62\x4b\x67\xfd\x8d\xc0\x19\x3e\x9a\x0f\x56\xbb\xd1\xb2\x56\x2c\x16\x36\x81\x88\x12\x06\xf2\x2b\x78\x8c\xe0\x3d\x0a\x85\xf1\x15\x44\xd0\xb6\x1c\xf5\xbd\xb7\x92\xbb\xd3\xac\x49\x4f\x76\xa8\x61\xd8\xba\x4b\xe3\xdc\xca\x3c\x55\xc2\xbf\x43\x9c\xcc\x89\xc9\xae\xf8\xfe\x4e\xe0\x5c\x5e\xf7\xd1\x27\x6f\x09\xaa\xdd\x9d\xcb\x9d\x70\x36\x61\x42\xd4\x07\x94\x6a\x76\x6e\xae\x06\x6a\xb9\x9a\xe3\xa5\x23\x3c\xcc\x93\x2f\xad\xe5\x9a\xd8\x9c\x49\x49\x53\xac\x89\xb5\xec\xd5\x91\x4f\x90\xba\x5e\x37\xd9\x77\x66\x82\x14\x96\xf4\x39\x6e\xa9\x8e\x03\x7b\xf6\x1c\xd9\xaf\x9c\xdd\xa7\x71\x81\xe7\x67\x10\x59\x9c\xcd\x5d\xc1\xcd\xc6\x42\x48\xea\xca\xbf\x12\x90\x8f\x26\x94\xde\x18\x34\xe7\x17\xcd\x27\xf0\x2d\x8f\xe6\x08\x36\xae\x40\xf8\x04\x13\xb5\x9b\x63\x4d\xfa\x53\x3f\x8f\xb5\xad\x3e\xf1\x61\x69\x98\x8d\xe3\xf3\x2a\x22\x4d\x91\xe8\x48\x6a\xb7\xf9\x96\x70\x58\x0f\x26\xca\x0a\xc1\x81\x1a\x6a\x62\xca\x4d\x2a\x28\x3b\xb8\x21\x98\xc8\x26\xa0\x3b\xea\xb0\x01\xe4\x82\xe1\x63\x59\xfd\x96\x43\xef\x38\x69\x97\xe9\x29\x4c\x59\xef\x0a\x8b\xbc\x64\x0f\x8e\xe2\xbc\x02\xc6\x2d\xc5\x4a\x70\xb7\x52\x59\x6a\x0b\x29\x2e\xe1\xdc\xf6\xb4\xb0\x67\xee\x15\x02\xda\x77\xb7\x7c\x06\x69\xdd\xca\xf1\x6d\xf2\xbe\x3e\xfe\xae\xb0\xa1\xc2\x23\x52\xac\x33\xca\xbd\x60\x07\x42\x97\x49\x6f\xe9\xff\x0f\x08\x12\x4b\xeb\xbc\x52\x3c\x7b\x96\xcd\xa1\x34\xc4\xc2\x03\xb1\x47\x68\xd5\xcc\xcf\xfe\x5b\xa2\x40\x91\xd4\xd7\x9f\x05\x82\xa5\x83\x16\xd1\x2f\xec\x5c\xb1\xf9\xab\xe7\xf3\x86\xe2\x06\x9c\xbb\x5a\xfd\x04\xdf\x75\x7a\xe0\x59\x13\xbe\x47\x0f\xb6\xfa\xbc\xe7\x49\x67\x8b\xcf\x28\xa7\xea\xe3\xa3\x70\x44\x5b\x6e\xba\x66\xbc\x34\x84\xfa\xc1\x53\x6a\xb5\xda\x41\x2c\x84\x25\xdf\x70\x82\x4e\xb7\x4b\x03\xaf\x79\x44\xc1\x35\x28\x9b\x69\x19\x66\x9a\xc8\x55\x31\xa6\xc3\xa1\x52\x5e\x13\x93\x1d\x36\xa9\x10\x78\x93\xc2\x44\x76\x09\xdc\x0b\x05\xb4\x02\x76\xc8\x86\x57\xc9\xed\xe7\x90\x27\x96\x7f\xb7\x18\x81\xdc\xba\xf2\x2d\xb5\x26\x58\x50\x0c\xe9\x18\xb9\x5a\x93\xc4\x7e\x04\x19\x2a\x02\xa8\xc5\xd6\xf4\x40\x0b\x22\x7c\x6b\xae\xa7\x3c\xa0\x37\x9e\xc3\xea\x1d\xb7\xc2\xfe\x3b\x9a\xcc\x40\x75\xbe\xb9\x4d\xe2\x57\xf6\x53\xe8\x67\x83\x33\x1e\x84\xcf\x8a\xa8\x94\xcb\x6e\xb9\xe2\x0e\x64\x58\x6b\xdf\x09\x42\xeb\xd8\x0e\x2b\x38\xe8\xf0\x69\xc0\x2e\xfd\x6d\xe7\xb8\xeb\x72\x73\xb9\x5c\xb3\x13\xbc\xd0\xd8\x3d\xbb\xd6\x44\xe6\xd8\x2b\x78\x40\x02\xae\xf8\x27\x75\x68\x0e\x08\xeb\xfe\x5c\xf8\x64\xf1\x68\x9f\xa7\xc2\x6b\x0c\xf6\x14\x42\xbe\x0a\xe1\xd5\x32\x22\xaa\xfd\x7d\x0a\x11\x6c\x8f\x2a\xc7\xc8\xde\xf6\xb9\xc5\x5e\x8c\x7f\xce\x8d\xe5\x98\x27\x45\x75\xf5\x0b\xb9\x95\xf9\x2f\x1e\x37\x38\x2f\xf3\xa8\x7b\x15\xc9\x47\x42\xb1\x17\x2e\xa2\x98\xc0\xd5\x17\x5f\x61\x04\xae\xd0\xcb\xa0\x93\x42\xd3\xe7\xe1\xc9\xe4\x6a\x51\xe4\xf8\x43\x5a\x06\xdc\x67\xf0\xdd\xfa\xe6\x32\x6b\x28\xaf\x70\xe6\xe0\x15\x98\x8e\x08\xf1\x82\xa0\x9b\x0f\xe6\x2f\x3f\x65\xd6\x01\xe7\x0c\xc4\x08\x76\x30\x79\xa0\x08\x37\xef\x97\xf3\x1c\x91\xec\xfa\x84\xce\x99\xe0\x38\x2e\x47\xb7\x42\x20\x19\xd3\xe6\xed\x87\xf6\x04\x3e\x42\x87\x26\xf7\xed\x0a\xe0\xf7\xb9\x13\x40\x57\xa4\x90\xe4\x44\x27\x70\xef\x16\xe5\x9d\xc6\x6c\xa4\xd8\xff\xa8\x4e\x7e\x28\xff\xb8\x4a\xbf\xcf\x6d\x3d\xcb\x05\x35\x86\xc5\x4c\x6c\x07\x8c\xe1\x62\xe8\x89\xf9\x28\x29\xf7\xc4\x1f\xec\x58\x47\xe3\xa1\x5c\xee\x10\xa6\x22\xb0\x98\x03\x38\xf0\x39\xee\x17\x03\x4d\x0f\x2d\x9f\xff\x93\x5f\xfe\xda\xc0\xc8\xa7\x02\x43\xca\xff\x7e\xdd\x9c\xb5\x7b\x6a\xf3\x16\x79\x13\x8a\x56\x78\x77\x93\xe3\xfa\xe6\x7f\x6f\xfe\x1f\x00\x00\xff\xff\xd5\x28\x66\xc5\xb4\x0f\x00\x00") + +func characterJsonBytes() ([]byte, error) { + return bindataRead( + _characterJson, + "character.json", + ) +} + +func characterJson() (*asset, error) { + bytes, err := characterJsonBytes() + if err != nil { + return nil, err + } + + info := bindataFileInfo{name: "character.json", size: 4020, mode: os.FileMode(420), modTime: time.Unix(1594526741, 0)} + a := &asset{bytes: bytes, info: info} + return a, nil +} + +var _cityJson = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x84\x58\xdd\x72\xe3\xb8\x8e\xbe\xef\xa7\x60\xf9\x66\x6f\x32\x2f\xb0\x77\x89\xf3\xd7\xbd\x49\x77\x2a\xce\x9c\x9c\xda\x53\x53\x5d\x30\x05\x4b\x28\x53\x84\x06\x24\xed\xf6\x6c\xed\xbb\x6f\x01\x94\x2c\x39\xdd\xb3\xe7\xca\x24\x4d\x42\x24\x3f\xe0\xc3\x07\xfe\xcf\x27\xe7\x56\x9e\xf2\xe9\x7b\xee\xb0\xc7\xb4\xfa\x4f\xf7\xaf\x4f\xce\x39\xf7\xaf\xd5\xdd\x3f\xdf\xee\x5e\xbf\x5e\x3f\xad\xae\x56\xd7\x42\x29\xb3\x17\xf0\x27\xeb\xe5\xd5\xd5\xea\xa6\x08\x42\x99\xc6\xd6\x90\x32\x26\x6b\x64\xf0\xdc\x6f\xd3\xea\x8f\xab\x9f\x0d\x2d\x9a\x6b\xa1\x1e\xdd\x0e\x7a\x0a\x54\x57\x4a\xc1\x90\x4f\x97\xb3\xce\xcd\x5f\x59\xbb\xc7\x94\xe9\x00\x21\x59\xbb\x34\xfa\xfb\x39\x66\xa1\xb6\xe0\xea\x6a\xf5\xa6\x27\x5a\x5d\xad\x9e\x41\x32\x41\x70\x01\x8e\xb3\x99\x67\x14\x9a\x8f\xb4\x30\xfa\x6d\x28\x01\xa3\xc7\xcb\xd1\x17\x0a\xad\x50\x0f\xad\x6d\xf5\x85\x6c\xdd\xd9\xd8\x4b\x28\xb3\xad\x17\x3e\xa0\xd8\x39\x5e\x29\x97\xba\xbb\x4d\x80\x03\x8a\x8e\x6d\x06\xf2\x66\xe3\xad\xc3\x71\xc9\xd9\xcc\x5b\x47\x38\x4e\x7b\x13\x68\xec\x0c\x27\x81\x18\x3f\x6c\xf1\x9d\xfe\x02\x69\x6c\xde\x3f\x31\xf2\xd0\xf1\x96\x60\xf5\xc7\x27\x67\x96\x2a\x9c\x78\xc0\x98\x97\x70\x5e\xa7\x04\x29\x51\x84\x4c\x1c\x0d\x28\x89\x7a\x79\xda\xe4\x98\xbc\xd0\x30\xfd\xc3\xc2\xf3\x34\x2e\x83\xfe\x94\x90\x1d\xf8\x4c\x07\xca\x8b\x1d\xaf\x8b\xec\xf0\xb8\xba\x5a\xdd\x52\xf2\x3c\xee\xfd\x0e\x24\x77\x7f\x16\xd8\x7f\xb8\xc3\x7b\x48\x1d\x71\x74\x59\x30\x36\xda\x27\xc1\xd9\xd4\x7d\x60\xd6\xd1\x47\x84\xc3\xc9\xed\xb8\x3d\xb7\x33\xfc\xb0\x1b\x7b\xe4\x70\x72\x0d\xe8\x27\x1e\x4f\x29\xa3\x10\x18\xe0\x7f\x16\x4a\x64\xdb\x3d\x1b\xfb\x1c\x53\x11\x41\x3f\x1e\xe2\x73\x3c\x40\xaa\xcd\x2f\x40\x61\x2b\x08\x7b\x73\x8c\x94\x1c\x1e\x68\x9a\x66\xfd\x01\xa4\xb1\xde\x57\x6c\x39\x93\xdd\x43\x5a\x42\x0d\xd5\xbb\x5e\x84\x7d\x80\x7e\xba\xa7\x17\xe1\x8e\xb6\x34\xf5\xca\x36\x90\x77\x2d\xf4\xb6\xf3\x57\xdc\x95\x16\x6b\x93\x38\x53\x6c\x67\x83\xaf\x5c\x62\x63\x77\xbc\xf1\x10\x1b\x03\x64\xa3\x67\x0b\x6e\x4f\x21\xa0\x68\xbf\x63\xc9\xd0\x9a\x43\x70\x91\x08\x3d\xc6\x6c\x5e\x42\x10\x66\xe0\x1b\x4a\x59\xc8\xe7\x9f\x63\x79\x8e\xca\xcb\x18\xe4\x98\xb2\x94\xe9\xfc\x6b\x81\x5d\x4e\x63\x6c\x52\x84\x40\xe6\xc6\x8a\x7d\x59\x42\x75\x4b\x51\x8f\x70\xb5\xba\x6b\x8a\x9f\x2e\xe0\x2e\x66\x94\x0c\x14\xc7\xbd\xdd\x53\x84\x1a\x46\xf7\x2c\x48\x6d\x44\x51\xd3\x0f\x1d\xe6\xcc\xb8\xb8\xd1\x07\xf5\x9b\x69\xd5\x83\xc0\x01\x4f\x20\x16\xcb\x0f\x82\x18\x5d\x1a\xc0\xcc\x7c\x8e\x4d\xd1\xf3\x41\xa0\xbf\xa6\x8f\x7e\x29\x4d\x8b\xe3\xd2\x27\x3a\xa0\xb2\xd4\xfe\x97\x5c\xf1\x0c\xb2\xc7\x3c\x84\x6a\xeb\x19\x7b\x56\x4b\xfa\x95\x67\x0a\x94\xc1\x3c\x77\x11\xfb\x2f\x1c\x42\xb9\x74\xaa\x39\xb0\x5f\x4a\xa4\xd4\x8d\xdf\x7d\xc5\x40\x6d\xdd\xce\xc6\xd3\xb8\xfc\x1c\xbf\x02\xa9\xfb\x77\x54\xf8\x8f\x91\x12\x7e\x1d\xe2\xef\x1c\x1b\xbd\xbb\x33\xcc\x65\x18\x50\xbe\xfb\x00\x29\x7d\xdf\x16\x0a\x0d\xc5\xf6\x22\xd2\x3d\x34\xd8\x1b\x53\x07\xdf\x61\x4f\x29\x1b\x6b\xfb\x8e\x0e\x58\xf9\xdb\x35\x08\xd5\xb5\x6e\x40\xb6\xb5\xc1\xbc\xdf\x92\x7e\x6a\xde\xae\x8e\x25\x1c\x9d\x50\x29\x3e\xe8\xfa\x75\x60\xbf\xef\x61\x5f\x47\x03\xe7\x8e\x6a\x93\x8b\xe4\x8e\x4b\x32\xd0\x8b\x08\x2d\x6d\x3d\x80\xda\xd1\x5d\x3d\x80\x34\xa8\xd7\xf5\x08\x5b\x94\x06\x52\x57\xc7\xbf\xe0\x11\xeb\xa7\x9e\xe0\xe8\x78\xb7\x23\xbb\xca\x27\xf6\xfb\xd4\x53\x5e\x5c\xe3\x13\x97\xd8\x56\x6a\x8f\xac\x0b\x9e\x4b\xc2\xd2\x2b\x82\xdb\x84\x72\x80\xcc\x23\x9e\x28\xe0\xa6\x2d\xbd\x80\x2c\x7c\xe3\xa5\x3b\x25\xf2\x04\x35\x78\x49\xbd\x77\x0e\xdc\x2d\xe4\xae\x06\x6e\xca\x50\x04\x0c\xe8\x0d\x84\x8a\x72\x86\x6d\x58\x7a\xf0\x1b\xfc\xa0\x06\x65\xbc\xe8\x37\xec\x87\x50\x43\x75\x0b\xde\x73\x1c\x87\xf9\x18\xa7\x9d\xbc\x53\xac\x47\xfe\x6f\xe6\x19\xd7\xc0\xc7\xff\x1f\xd7\x81\x73\x87\xbe\xba\xea\x75\x3a\x05\x3b\xf1\xcd\x08\xc4\x8d\xe0\xb1\x1a\xbd\x29\xd9\x77\x23\x64\xb1\x09\x58\xa1\x9a\x39\x7b\xc1\x05\xeb\x0e\x31\xe1\x19\xcb\x31\xec\x5d\x85\x67\x5d\x84\x38\x51\x3e\xb9\xd4\xb1\x12\xd4\xad\x06\x97\x46\x76\xdb\x29\x87\xb9\x81\xf2\x82\xbf\x59\xda\x31\xda\x73\x89\x98\x27\xb7\x79\x80\x7e\x1b\x74\x76\x07\x41\xb9\xed\x09\x21\x77\x28\x47\x96\x7d\xfa\x39\x2e\x21\x2d\x23\xee\x99\x6c\xc9\x33\x47\x3c\x05\x34\xdf\xbc\x5a\x7d\x93\xa1\x83\x58\xd9\xf0\x5b\xc9\x3b\xca\x23\x74\x42\xa9\xe2\xa3\x17\xb1\x80\x67\xd3\xd1\x30\x51\xca\xa6\x13\x8a\x68\x20\xb2\xdf\xeb\x68\x6d\x47\xbd\xd7\x83\xd9\x79\x83\x9c\x99\x47\xd0\x34\x6d\xc7\x65\x86\x46\xa8\x5f\xfb\x07\x6a\x02\x8a\x20\xd5\x83\xde\x41\xf0\x8c\x2e\x64\xdf\x65\x05\x53\x3b\x08\xd5\xec\xbb\x1e\x58\xef\xf1\x32\x4f\x8f\x39\x95\x2e\xe8\xfa\x7a\xdb\x14\x6f\x22\x0b\x5b\x83\x16\x8e\xa1\x4a\xae\xb6\x46\x20\x06\xdc\x0a\x64\x6b\x77\x90\x16\xdc\x7c\xa6\x74\x0b\x48\x56\xbc\x6e\x47\x1e\xbe\x2d\x18\x3e\xa8\xab\x1f\xe8\x4b\x5e\xac\xbe\xfb\xa1\xc0\x16\x4a\x9d\xfd\x9b\xd9\xa4\xde\x3d\x87\xc0\xc7\x09\x4b\xb4\xc8\x2d\xa1\x8a\x2d\x14\xe1\x16\x96\x36\x9e\x41\xe4\x83\x60\x79\xd6\xa4\x55\x23\xb0\xf2\x27\x64\x61\x35\xf0\x82\xb2\x63\xe9\x2f\xd2\xab\x4d\x10\x04\xdf\x8d\x59\x16\x53\x3a\xe7\x5b\xea\x6b\x33\x63\x1a\xb9\x17\x2f\x8e\xff\x8a\x03\x90\x8c\x79\x56\x7f\x78\x6b\x1e\x01\x62\xe6\x36\x18\x2e\xae\xe0\x8c\xc5\x14\x6f\xdf\x85\xb9\xbf\x80\x42\xb6\x2c\x98\x2d\xd4\xae\xb3\xd0\xd8\xc8\xe4\xf5\xf7\x40\x35\x1a\x6f\x20\x04\x5d\x69\x4d\xa5\x8e\x99\x42\xb1\x71\xbe\x83\x7e\x3b\x06\xe4\x96\x22\xe6\x0a\xdb\x60\x70\xac\x03\xc3\x7e\x5c\x5b\x13\xab\x9b\x7a\x82\x2a\xd8\xc6\xfe\xaf\x72\xc8\x99\x49\x1f\x40\x04\xf3\x94\x32\x27\x47\xfc\x52\xe2\x7e\x32\xf6\x5f\xa4\xa4\xb0\x70\xe5\x27\x5d\x6b\x64\x4b\x5b\xa9\xa7\x78\x86\x61\x9a\xfe\x8c\x1a\x61\x42\x35\x59\x1e\x15\x80\xaf\x45\x92\x12\xcc\x8c\x15\xc4\x2c\x15\x4e\x09\x3c\x86\xe0\xc1\x84\x2f\x73\x76\x1e\x43\x00\x53\x2f\x50\xfc\x28\x7e\x7d\xa9\x49\x60\x8e\xcd\x9e\xf7\x8b\x23\x9b\x3a\xae\x53\x33\x85\x70\x1e\xce\xa5\xa9\xaa\x98\x87\xee\x34\x8d\xbe\x6b\x86\xe4\x2d\xce\x28\x66\x8d\x26\x0f\xe1\x7b\xca\x82\x98\xbf\xef\x10\x54\xb9\x5c\xe2\xe9\x6b\x66\xbe\x3e\x46\xe3\x57\x03\x4f\x59\x1a\x6b\x5b\x84\x74\x86\x75\x84\x1a\xa3\x99\x35\x44\xd5\x59\x33\x83\x8a\xd0\x58\x0a\xac\x21\x1f\x21\xec\x3f\x0a\xab\x40\xfd\x56\xb3\x84\x3b\x42\x30\x95\x61\x79\x12\x53\xa0\x38\x16\x3b\x7c\x6c\x16\x8a\x0a\xa1\x71\x55\x15\xdf\x62\x4c\x38\xea\xdf\x5b\x3e\xc6\x81\x8b\x7c\xd0\xd1\xaa\x94\xab\x00\xbb\x67\x6e\x5c\xca\xf6\x8d\x05\x13\x97\xa8\x42\xcc\xfc\xa2\x56\x65\x4f\xd0\x34\x55\x7f\xcd\x2a\x49\xb3\x66\x63\xd7\xfa\xed\x80\xd2\x0a\x1f\xe3\x52\x95\xf2\xce\x81\x1f\x63\xcf\x7a\xad\x39\x5b\x9a\x08\x76\xfe\x77\x43\x71\xdf\xb1\xf1\xc2\x26\x90\x59\xde\x64\x44\xf3\xa5\xdd\x92\x87\x6d\xb0\x42\x93\xea\xa4\xc1\x2a\x21\x96\xe8\xca\xf4\x8f\x71\xab\xf4\x14\x5d\x3a\x82\xf4\xc9\x38\xf4\x6f\xa2\xf6\x8c\xf7\x39\x7c\x7f\x81\xf8\xe2\xe6\x2e\x91\x4e\xa6\x1c\xe7\x73\xdc\x88\x26\xb6\x70\x72\x81\x8c\x7b\x85\xf7\x18\xdd\xae\x48\x24\xd3\xbf\xe7\xa1\x56\x53\xf4\xd2\x1d\x2c\xa8\xab\x37\xc8\x80\x19\x1b\xb7\x0b\xcc\x52\x33\x2c\xc4\x06\x03\xd5\xdb\x5f\x2b\x93\x9b\xa0\x4d\x16\xe0\x40\xd1\x0d\x34\xd4\x5e\xe9\xb7\x47\xa0\x7c\x91\xbb\xee\x7c\xc7\x1a\x1f\x3d\xc8\xc4\xbc\xb1\xd5\x01\xdf\x01\x19\x18\x8f\xa5\x45\xb7\x23\xc1\x29\x87\x7e\x05\x11\x3e\xba\x80\x4d\xf5\xd0\x6f\x03\x46\x77\xa4\xd8\xb0\x85\xf1\x37\x89\x90\xd1\x1d\x11\x86\x8b\xc2\x66\x76\x82\x89\x9f\x6b\xa5\x1b\x30\x39\xde\xb9\x6c\x42\xd6\x06\x02\x48\x75\x8a\x6c\x2a\xc0\x23\x85\xea\x8d\xd3\xc8\x78\xf8\x85\x33\xd5\xf1\x29\x16\x36\x5e\x59\xaa\x7a\x92\x1c\x20\x66\x37\x40\x4a\x63\x40\x7d\x74\xae\x0e\x1a\x3e\x9e\x9c\x22\x77\xa8\x13\xf6\xa7\xa0\x40\x2d\x3d\x6b\x38\xa9\x03\x56\xa7\x02\x12\x0f\xa9\xd6\xd8\x10\x82\xdb\xaa\x88\xed\x30\xd4\xd5\xbf\xc7\x8a\xae\x25\xe9\x86\x8d\x00\xde\xed\x72\x5c\x23\xa0\x48\x9c\xbd\x6b\x07\xbe\x16\x7f\x4b\xf6\xc8\xae\xe7\xc3\x54\x72\xdc\x60\xdb\x82\xfc\x47\x72\xad\xfa\x9f\x0e\x04\xf0\x7b\x05\x6b\x8f\xa3\x0b\xa9\xd6\xe9\x6a\x65\xbb\x56\x29\xd5\x96\xaa\x39\x34\x4f\x0f\x1f\x9e\x11\xac\xfe\x3a\xdb\x5a\x3c\x90\x9c\xce\x5d\xa9\x37\x7d\x0b\xb2\x77\xbe\x84\x6c\x69\x7a\x08\x2c\xa8\xdb\xf0\xa1\x68\xba\xbb\x17\x44\xe7\xb9\x1f\x20\x9e\x96\x75\x56\x91\x1e\x62\x33\xcd\x7a\x44\x4a\xd9\x79\xb1\xfa\xfd\x11\x05\x2d\x94\x5c\x42\xd3\x0e\x8f\xd4\x76\xce\x73\x89\x9e\x82\x75\x05\x9b\xb1\x20\x4d\x55\x94\x43\x70\xbd\x96\x4e\x04\xf3\x37\xbe\x5a\x61\x06\xc1\xf9\xae\xd4\x8c\xfb\x95\x95\x05\xa7\x8c\xf4\xad\xe4\xa0\xf1\x20\xce\x07\xd3\x4d\x36\x70\x74\x2d\xd8\xb1\x5e\x58\xed\xa9\xe5\x61\x54\x0a\x63\x71\x55\x92\x63\xb9\x28\x4d\xe6\x3f\xc6\x0d\xbf\x62\xa2\x94\x47\xa9\xf3\xca\x27\x08\x0e\xa4\x3f\x9d\x3b\xd3\x16\x36\xbe\xe3\x60\xa0\x79\x12\x5f\x59\x0b\xbd\x60\x76\x89\x3d\xe1\xf2\x75\x63\x33\x9c\x5c\xc4\xac\x52\xd5\x3c\x4b\xe9\xc9\x81\x64\x4a\x23\x7f\xd9\xc0\xb8\xf7\xb1\xd7\x97\x5a\x55\x8c\x4f\x3c\xaa\x16\x5d\x16\x2e\xc3\xb9\x2a\x9c\x91\xf9\xe0\x68\xdf\xb3\x00\x5d\xbc\xd9\xdc\x40\xdc\x4b\x19\x2e\x9e\xdb\xaa\xf2\x58\x77\x20\x64\x75\x48\xf5\xa5\x5d\x49\x38\xba\x55\x44\x9f\xc7\xb6\xd8\xe2\x45\x96\xd1\xcc\x66\x9e\xab\xcd\xd3\xe8\x4b\x18\x4a\x32\xd4\x4c\x81\x1c\xa8\xb1\xd5\xb7\x4a\x19\x63\x60\xdf\x69\x2d\x46\xba\x72\x26\xa6\xc4\x2a\x80\x7d\x75\x40\x88\x63\x42\x7a\x2c\xb1\x7e\xfc\x73\xd4\x63\x62\xae\x9f\xd3\x9e\x6d\x86\xea\x8e\x3f\xc7\x04\x11\x2f\xdf\x6b\xaa\x58\x78\x86\x48\x43\x09\x90\x6b\xad\x3a\xbe\xdd\x7d\x7c\x8c\xe3\x62\xe4\xc4\x83\xad\x9a\x9d\x42\x79\x01\xeb\x9f\xaf\x25\x77\x61\xe4\x10\xc3\x57\x1b\x65\x7b\x40\x49\xd5\xf4\xa6\x0c\x83\x2a\x2c\xdb\xee\x5b\x27\x8a\x55\xc4\x66\x29\xf6\x85\x0e\xf5\x58\xbf\xc7\x61\xfc\xd6\xd5\xea\xf7\xe1\x37\x88\xcd\x6f\x9e\xfb\xfa\xdf\x3b\x42\xc8\xdd\x69\xcc\x53\xbf\x0d\x82\x03\x88\x19\x3d\x3f\xce\xf9\x9f\xb1\x6e\x19\xc2\x05\xb3\x34\x07\x4a\xe8\x02\x42\x55\x65\xd7\x07\xa6\xc6\x35\x98\xcf\x8f\x58\xd7\x47\xd0\xe4\xb3\xc5\xfa\xd9\x35\x87\x80\xbe\xfa\xa3\x1a\x4d\xcb\xf7\x1c\xb7\x85\x84\xbf\x7c\x3e\x5d\x73\x54\x6e\x77\x43\x0d\xb5\x9a\x94\xf4\xe8\x67\x43\x7f\xf3\x00\xab\x8e\xb2\xc3\xd8\xb8\xad\x45\x62\x9a\x07\xc6\x3d\x2f\xdc\x2c\x65\xe1\xd3\xc5\xce\xa6\xb1\x69\xf7\x53\xff\xa0\xe9\x84\xea\xfb\xd1\x8e\xc5\xa3\xbd\xd2\x6a\x4f\xc8\x77\xae\x47\x15\xce\x69\xf9\xbc\xb4\x2c\x56\x7c\x07\xb1\x45\xd7\x32\x5b\x71\xf7\x88\x20\x4e\x4a\x5f\x33\xef\xe7\xd8\x94\xd0\xa2\xcb\xd3\xd3\xf4\xc5\x6b\xd0\xe0\x72\x87\xee\x58\xa9\x56\x73\x5f\xee\x34\x6b\x7e\x60\x99\x17\xc1\x84\x72\x40\xa7\xba\xad\x96\x9c\xf3\x10\xcb\xf8\x0e\xd8\x14\x3f\x6f\xe2\x45\xb8\xe7\x7a\x9d\xcb\xae\x57\x6e\xb7\x07\x06\xd1\x3d\x69\xa4\x5f\xe4\x48\xad\x4c\x9c\x1a\x1e\xdf\x82\x36\x1d\x08\xba\x7d\xe4\xa3\x25\x72\xd3\xc6\xa2\x2a\x71\xab\x62\x62\x67\x53\x4a\xdf\x73\x74\x78\x30\x86\xde\x14\x39\x54\xc7\x7e\x13\x88\x69\x60\xc9\xe3\x9e\xd4\xf7\x3e\xfd\xef\xa7\xff\x0b\x00\x00\xff\xff\x82\xc4\x90\x81\xeb\x17\x00\x00") + +func cityJsonBytes() ([]byte, error) { + return bindataRead( + _cityJson, + "city.json", + ) +} + +func cityJson() (*asset, error) { + bytes, err := cityJsonBytes() + if err != nil { + return nil, err + } + + info := bindataFileInfo{name: "city.json", size: 6123, mode: os.FileMode(420), modTime: time.Unix(1594526741, 0)} + a := &asset{bytes: bytes, info: info} + return a, nil +} + +var _dataGo = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x8c\x59\x4b\x6f\xdb\xba\x12\x5e\x5b\xbf\x42\x37\x8b\x8b\x06\x28\xda\x7d\x80\x2e\x52\x27\xb9\xa7\x40\x1d\xf8\x36\xe9\xcd\xe2\xe0\x40\x1d\x4b\x63\x9b\xc7\x14\xa9\x43\x52\x0e\x9c\x22\xff\xfd\x82\x4f\x8d\x6c\x49\x76\x37\x71\x39\xdf\x37\xc3\xe1\x6b\x1e\x6a\xa0\xdc\xc1\x06\xf3\x0a\x0c\x64\x19\xab\x1b\xa9\x4c\xfe\x21\x9b\x5d\xa1\x28\x65\xc5\xc4\xe6\xf3\xdf\x5a\x8a\xab\x6c\x76\xc5\xe5\xc6\xfe\xa9\xe1\x0d\x15\x18\xbd\x41\xf1\x19\xb4\x46\xa3\x3f\xaf\x98\xb0\xf4\xab\xec\x3a\xcb\xcc\xa1\xc1\xdc\xc0\x8a\xe3\x93\x51\x6d\x69\x72\xed\xff\xfc\xce\x66\xf3\x2d\x28\x28\x0d\xaa\xbc\x8c\xbf\x9e\x2d\x30\x9b\xcd\x99\x39\xe4\xee\x5f\xc9\xcc\x21\x0c\x2e\x60\xc3\x4a\x37\x58\xdb\x5f\x69\xf4\x0d\xf3\x30\xfa\x86\x71\x50\x0a\x6d\xf5\xe6\x79\xed\x7f\x85\xf1\xc7\xe5\xdc\x63\x73\xd1\x44\x05\xcf\x0a\x41\xb7\x0a\xf3\xdc\x84\x5f\x41\xf0\xc2\x78\xe5\xc1\xaf\x8c\x57\x7e\xf0\x3d\xcb\xf6\xa0\x72\xf7\x1f\x9d\x7f\xa1\x8e\x51\x87\x6e\xf2\x79\xcf\xa3\x0f\xd7\x1f\xbd\x53\x37\x5e\xe1\x3c\x7a\xe5\x04\xce\x31\x2f\x59\x24\xcf\x82\xe4\x0d\x03\x65\x11\xbd\xf3\x02\xef\x96\x95\x2d\x88\x87\x4e\xf6\xb8\x9c\x07\x4e\xfe\xb8\x9c\x77\xe3\xd1\xd1\x9b\x3c\x7f\xa6\x9e\x3a\xa1\x75\x36\xb0\x5e\xa2\xb7\x56\xf0\x1e\x76\xb0\xbf\x43\x64\x13\x6f\x9b\x06\x41\x81\x28\xfd\x2e\xfc\xf9\xd7\x9f\x7f\x69\xa3\x98\xd8\xe4\xbf\xec\x41\xb9\xb9\x82\x04\xb8\xfa\x95\xcd\xe6\x5c\x9a\xad\x95\xe6\x23\xf0\x32\x00\x2c\xf8\x2b\x94\xbb\x8d\x92\xad\xa8\x46\xc0\xab\x04\xb0\xf0\x6f\x06\x6b\x9d\xa7\x7f\xa7\x70\x66\x01\x16\xb9\x00\x21\x50\x31\x5d\x8f\x21\xeb\x08\xb0\xe8\x25\x2a\x2d\x05\xf0\x70\x28\x4f\xd1\x4d\x07\x70\xf8\xed\x41\xb3\x12\xf8\x1d\x1a\x60\x7c\x08\x1f\x00\x45\xe5\x10\x96\xf3\x80\x60\x72\x3a\xf7\xc0\xc8\x23\x67\x8d\x60\xae\x7e\x75\xfb\x11\x4f\x10\xbd\x4f\x76\x6c\x8b\x35\x92\x45\x18\x5b\x65\x66\x0e\x85\x71\x58\xb7\x2b\xcc\x1c\xee\xf7\x28\xcc\x85\x4c\x74\x58\xcb\xbc\x63\x56\x5c\x9a\x13\xbb\xa7\xcc\x2a\x40\x89\xdd\x9f\x4d\x83\x6a\xce\x41\xeb\xaf\x2d\xe3\xf6\x75\xd1\x63\xec\xd6\x42\x8b\xd2\x62\x8b\x55\x04\x5b\x1d\xdf\xe5\xeb\xa5\x3a\xb8\x85\x0e\xe9\xb0\xfe\xdf\x96\x86\xed\x99\x61\x67\xbc\x70\xfe\x43\xc2\xba\x63\x1a\x54\xfd\x90\xb2\xd6\xd3\xab\x17\xad\x16\xca\x62\x2d\xf9\xd9\xea\x2a\x81\x3f\x19\x85\x68\xec\x31\x68\x95\x9b\xc2\x29\xd9\x04\x68\xa1\x1d\xb6\x58\x07\x30\x55\x13\xe7\x92\x14\x4d\xa8\x49\x93\xa1\x8a\x1e\xac\x54\x8a\xe3\x83\x30\x34\x9f\x75\x80\x12\xda\xb3\x02\x66\xce\xac\x41\xa0\x15\xc6\x61\x09\xf9\x3f\x12\xb8\xbe\xcc\x66\xb1\xb1\x58\x72\x1f\xba\x90\x40\x2e\x44\xbc\x88\xf7\xeb\x35\x96\x76\x5a\x13\x57\x11\x3d\x86\xde\xdf\x7b\x8e\xb5\xbb\x13\x53\xb4\x80\xa1\xbc\x07\xa9\xfc\x39\x98\xe0\xad\x2d\xc6\x92\xee\xcd\x16\x15\x4e\xce\x11\x03\x84\xce\x31\xd1\xc6\xe7\xd8\xd1\xc8\x1c\x23\x6f\x62\x8e\x89\x97\xe6\xb8\x68\x0d\xf4\x0e\xc5\xc0\x83\x19\x21\xee\x21\x16\x1a\x04\xbd\x4a\x03\x4f\x71\x82\xb8\xfb\x07\x06\xb4\x51\xb2\xd9\x06\xca\xc0\xbd\x23\x90\xde\xbe\x87\xb0\x48\xb6\xfd\xae\x15\x1b\x94\xe2\x5e\x18\x17\x76\x86\x2f\x53\xe5\x41\x05\x46\x94\x7b\xcd\xfc\x60\x5a\x9c\x49\x66\x5a\x9e\xc0\xfa\x0e\x07\xd9\x9a\x73\x2c\xee\x50\x84\xf6\xa3\x65\x22\xae\xee\x38\x4d\x25\x14\xa5\xe2\x2b\xa8\x6a\x6c\xc5\x12\xd5\xa3\x08\x8f\x3e\x75\xe3\xbc\xfe\x23\x17\x4d\x92\x37\x6e\xc2\x64\x7c\xdd\x08\xcb\x47\xc3\xa1\x83\x4a\x59\x21\x24\x52\xf2\xb3\x62\xe5\x6e\xf4\x4d\x8f\x64\xe3\x50\x84\xf6\x07\xbc\x5d\xb0\x38\x5b\x8f\x72\x4f\xa8\x82\x26\xdd\xc2\x31\x73\x46\x41\x43\xef\xa1\x25\x3d\x2b\xb6\xd9\xa0\x1a\x5f\x16\x47\x32\x01\x45\x0f\x2f\x49\xdd\x68\x4a\x85\x8a\x01\x1f\x53\x06\x4e\xea\x6c\xa3\x52\x68\x85\x30\x94\x64\x98\x4e\x6a\xc1\xb7\xff\xb4\x60\x42\xfe\x3c\xa0\xd4\x4b\x63\x26\x12\x42\xd0\xd0\xfb\x4b\x63\x0e\x79\xec\x07\x9d\x0e\xcf\xfb\xed\x8a\xf1\xf8\x1a\x0c\x98\x8e\xd2\x2e\x8c\x8d\x6d\x9a\x8f\x5c\xfa\x38\x27\x3b\x9b\x90\xbd\x20\xec\x04\xea\x11\x97\x5e\x83\x94\x6c\x4c\xac\x0e\x7a\xc9\xd5\x9e\x71\xf6\x86\xd5\xe3\x72\x3e\xea\x73\x19\x41\x85\x68\xfc\x3c\x7f\x8a\x0a\xd5\xab\x54\xbc\xe3\x0d\xe4\x36\x09\x94\x78\x36\x09\x47\x65\xa7\x35\xc1\x7b\x4d\xa0\xc4\x7b\xc0\x1a\x38\x3e\x02\x49\xc6\x86\x36\xd1\x82\x0a\x01\x21\x0d\x5b\x1c\x53\x86\x53\x62\x4a\xe9\x32\xb7\xa7\x56\xb9\xd1\x33\x39\x9b\x0e\xb0\x7e\xca\x36\x41\xa6\xc9\x1a\x25\xdf\xba\x1a\xf3\x4c\x9a\xe0\x0b\x51\x67\x8b\x01\x39\x7e\x23\x70\xce\x7a\xa7\xf0\x71\x39\x3f\xce\x45\x4e\x39\xa2\x29\x53\x16\x32\x5b\x30\xbd\x96\xca\xb4\x62\xca\x4a\xdd\x81\x02\x47\x1f\x65\x5a\x83\x1c\x1d\x5f\xfd\x05\x9a\xad\xac\xce\x64\x57\xb5\x07\xb9\x95\x4a\x95\xd7\xc4\xa4\xba\xf2\x4c\x9f\xd6\x2e\xe7\xb2\x18\xf2\x58\x1f\x15\x76\x23\xf7\x83\x14\x77\xdd\x0d\x4e\x5b\x33\x75\x91\x19\xf6\x2b\x37\x3d\x79\x54\x23\xc8\x52\x9e\xb0\x54\x78\x2e\x29\xd5\x1e\x64\xf1\x3f\xb0\x39\x9f\xef\xa8\x0e\x64\x39\x7f\xc8\xd5\xaa\x5f\x39\x0c\x70\xb6\x1e\xe4\x6d\x70\x4f\xde\xb2\x66\xd4\x79\x45\x41\xbe\xd8\xda\x33\x81\x77\xb2\x06\x26\xc6\x03\xa2\x03\x15\x95\x47\xb9\x73\xb0\xb6\x41\x66\x8b\x4b\x50\xb1\xad\x32\x70\x0e\x2c\xc8\x96\x66\x45\x63\x61\xe4\x31\xec\xb5\x45\xc8\x8b\xb8\x60\xba\x3c\x5b\x72\xd7\x4c\x97\x45\xaa\xbb\x5f\xa4\x12\x67\x29\xaf\x52\x09\x42\x41\x68\x64\x9f\x34\xf8\x84\x37\x92\x90\xbe\x4a\xb9\x7b\x6a\x57\x7f\x93\x58\x3e\x50\x8b\x49\xb9\x2b\x74\x40\xb9\xe0\x23\x25\x3f\x3b\x3b\x23\x25\xef\x0c\x2d\xe5\x49\xb1\x34\x70\x88\x65\x3a\x27\xae\xbf\x03\xfc\x9b\xd8\x28\xac\xd8\x48\xe2\x5e\x7b\x50\xc1\x3a\x94\x0f\xb7\x7e\x1f\xc8\x14\x87\xa2\xae\x07\x75\x53\x4c\xbd\x9e\x2e\x5a\x4f\xd0\xba\xa8\xfd\x3f\xe0\xad\xdd\xf1\x05\x18\x97\x71\x0c\xe6\x8a\xfb\x00\x2a\xea\x88\x22\x07\x27\xb5\xcd\xc8\xa1\xe9\xe2\xda\x0f\xdc\x74\x4b\x37\x19\xdb\x94\x47\xf6\xc3\xa2\xa7\x07\xa7\x2e\xa0\x13\xcf\x3a\x25\xdf\x41\x54\x35\xa8\xdd\x58\x66\xd0\x29\xe1\x11\xd9\x57\xe0\x5b\x7f\xa3\x15\x3b\x51\xa0\x13\xb2\xaf\xe1\x8e\xe9\x52\xee\x51\x8d\x24\xe3\x44\x43\xd5\x21\xfb\x2a\x7a\x9d\x8b\x49\x15\xfd\x94\xbe\xd3\x40\x73\xe5\x69\x0d\x24\x5f\xbe\xaf\xd8\x8a\xe3\x92\x43\xbf\x6d\x34\x50\x50\x3a\x60\xd1\x38\xa4\xbf\x35\x4c\x4b\x21\x5b\xdd\x27\x0f\xdd\x9c\x00\x24\xe4\x6f\x42\xdc\x56\xf6\xce\xb2\xfd\x74\xc2\xc2\x84\x28\x20\x21\x03\xf5\x51\xb6\x27\xbd\x8d\x61\xaa\xb0\xc8\xc0\xfa\x6f\xcb\xd4\x4e\x5f\xc2\xfa\xc7\x21\xfd\x25\x58\xb7\xa2\x3c\x69\x04\x1f\x77\x52\x7f\x67\xb3\x3d\x28\xdf\x48\x3e\xe9\x83\xb7\xa2\x06\xa5\xb7\xc0\x3d\xf9\x2a\xc9\x3f\xb9\x26\xfc\xc7\xfc\xdf\x8e\x77\x9d\xcd\x14\x9a\x56\x09\xaf\xa6\xb3\xdd\xb5\x99\x49\xc3\xb0\x6f\xb1\xeb\xaf\x9f\x18\x63\xe6\x70\x99\x1d\xda\xb5\xa6\x9d\x98\x9e\x25\xda\xb4\x3f\x36\xe5\x64\x97\xda\x4a\x7d\x70\x52\xfc\x1f\x59\x4a\x1f\x02\x4e\x0d\xbd\xe1\x85\x76\x7a\x6d\xf5\x7e\xa9\xd6\xb7\xd6\xfb\xc2\x70\x62\xd0\x4b\x2f\xb3\xd9\xb5\xeb\xbb\x0a\xa4\x67\xab\xfb\x6a\x71\x6c\x47\x34\x17\xae\xdf\x51\xeb\xff\x28\xba\xf7\xac\x1d\x7d\x0f\x39\x36\x19\xc5\x97\xd9\x25\x5f\x15\x48\x60\xe8\xd9\xeb\x3e\xb3\x9c\xd8\xb2\xa2\xcb\xec\x1c\x31\x1b\x30\xdb\xdc\x5f\xd3\x8f\xc1\x0c\x13\x06\xd5\x1a\x4a\xfc\xfd\x7e\x6d\x27\xe0\x6a\x85\x8f\x39\x2a\x95\xdf\x7c\xc9\xc3\xb7\xab\x4f\xae\xcc\x70\xf4\xeb\x6c\xc6\xd6\x4e\xfc\xaf\x2f\xb9\x60\xdc\x72\x66\x5c\x6e\x3e\x3d\x80\x01\xfe\x01\x95\xba\xce\x66\xef\x59\x36\xb3\x90\x2f\xb9\x9d\xe5\xa7\x9f\x71\x16\x1f\x82\xf6\x34\xe9\x4b\x54\xbd\x67\xff\x0f\x00\x00\xff\xff\x07\xe3\x1f\x1b\x86\x1b\x00\x00") + +func dataGoBytes() ([]byte, error) { + return bindataRead( + _dataGo, + "data.go", + ) +} + +func dataGo() (*asset, error) { + bytes, err := dataGoBytes() + if err != nil { + return nil, err + } + + info := bindataFileInfo{name: "data.go", size: 7046, mode: os.FileMode(420), modTime: time.Unix(1594534162, 0)} + a := &asset{bytes: bytes, info: info} + return a, nil +} + +var _magicJson = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x9c\x57\xcf\x6e\xe3\x3e\x0e\xbe\xf7\x29\x84\x5e\x7a\x99\x7d\x81\xbd\x4d\xd3\x3f\x53\x6c\xd3\x09\x9a\x62\xba\xc0\x0f\x83\x05\x63\x33\x31\x11\x59\x34\x28\x29\x69\x66\xb1\xef\xbe\x20\x25\xc7\xce\x4c\xb1\x87\xbd\x24\xa4\x2d\x91\xd2\x47\xf2\x23\xfd\xef\x2b\xe7\xae\x87\xee\x14\xa9\x01\xff\x2f\xdc\x6e\xb1\x49\xf1\xfa\xef\xee\xaf\x2b\xe7\x9c\xfb\xeb\xfa\x6b\xa0\x1e\x12\x85\xdd\xf5\x97\xeb\xaf\x29\x09\x34\x55\xb9\xa5\xd0\x56\xc9\x73\x8c\xdc\x17\x65\xc1\x21\xe6\x51\x16\xc4\x41\xc5\x9f\x5f\xaa\xb5\x85\xe4\xd8\x95\x97\x77\xd4\x53\xa0\x49\x3b\x50\x35\x77\x97\x07\x4f\xcd\xe8\xf3\x3e\x1c\xd0\xf3\x50\x95\x8f\x01\x8a\xd7\xb3\xc5\x87\x1c\xcb\xbb\x47\x81\x58\x97\x7d\x83\x98\x30\x54\x99\x42\x8b\x52\xe4\x27\xef\xf5\x68\xa3\xe9\xa7\x7e\x10\x8a\x1c\x2e\xec\x3d\xe3\x81\xd2\xb8\xe2\xfb\x30\x9a\x59\x61\x12\xda\x9e\xaa\xd2\x41\x75\xba\x22\x94\xa6\x8a\x59\x62\xbe\x30\xf5\x8a\x5b\x8f\x23\x5c\xaf\xb8\xc3\x80\x02\x67\x75\x44\xef\x15\x07\xf4\x7e\x94\x63\x16\x39\xef\x59\x37\x82\xd0\x5f\xd8\x5c\x23\xd4\xb5\xeb\x0e\x06\x8c\x1d\x6d\xc7\xc5\x1d\xa1\xaf\x36\xd7\x03\x1c\xeb\xc1\xdf\x04\x42\xec\x73\x9a\x69\x03\x8b\xa9\x3f\xaf\x9c\x33\xc3\xb3\xf8\x7b\xec\x31\x5c\x26\x40\x43\xad\xc6\xbe\xdf\xa0\x68\xb0\x41\xf6\x25\xe6\xac\x8f\x6f\x39\xa0\xfe\x09\x05\x9c\x85\xd9\xc3\xc9\xe2\xcf\x47\xfb\x3b\xc5\x04\x5e\xe3\x57\x8d\x3c\x78\x88\x9d\xfe\xe7\xb0\xcb\x71\xda\xf7\xe8\x21\x46\x0d\x1a\x07\x54\x03\x4f\x8d\x1a\x7f\x0a\x11\x9b\x74\xfd\xe5\xfa\xbd\xf8\x7c\x86\x03\x4c\x7b\x96\x6c\x5b\xbe\x6f\x22\xb5\x04\x41\x45\x52\x5f\x2b\xd6\xd8\x2a\xa8\xa0\x7b\xd7\xe0\xd3\x0c\x46\x08\xad\x3d\x1c\xf4\x17\x65\xc0\x60\x8b\x3c\xf5\xea\x71\x9d\xca\xb5\xde\x40\xa6\x3d\x6f\x1d\x8b\xda\xfb\x41\xf6\xee\x1d\x92\xdd\xe5\xbd\xaa\xe5\x6c\xef\x2c\xfd\x67\xc0\x6e\x59\xfa\x0b\x54\x7d\x02\xdd\xfd\x55\x7a\x2e\xff\x05\xab\x5b\x84\x98\x0c\x5f\x68\xd5\xec\x02\xb2\x6f\x85\xc3\x0c\xdb\x0e\x48\x8f\xb1\xe8\x40\x88\x75\xed\xc2\x83\xc1\xec\x19\xf6\x56\x81\x5a\x8f\x39\xd6\x00\xcc\xb6\xde\x97\xe8\x96\x50\x9c\xd4\xfc\x03\xe7\x90\x8a\xbd\x47\x48\xfa\xe4\x91\x3d\xf6\x56\x43\x7d\x8f\xb3\xdb\x7f\x2b\x97\xff\x87\xc5\x65\x09\x51\x3d\x2d\x39\xb0\xa7\xd4\x59\x21\xe8\x49\x56\x56\x4f\xf3\x6c\x0d\x89\x02\xfa\x02\xf2\x01\x0a\xc8\x96\xa8\x96\xa5\x68\x18\xac\x13\xa2\xe9\x47\x50\xf0\xce\x78\xeb\x51\x1b\x6f\x71\xe8\xa4\x06\x84\xa5\xe9\x4a\x1e\x0f\x16\x03\xaf\xb6\xdf\x71\x33\xc3\x1c\x53\x87\x82\x9f\x93\xd9\x01\xc3\xae\x92\x16\x4c\xe4\x73\x8b\x47\xf2\x67\x96\xb8\xf5\x67\x66\x53\x8c\xcf\xbc\xd6\xf7\x39\x8c\xbc\x34\x45\x83\xfb\xa9\x7c\x17\x1c\x9a\x73\x7d\xde\x21\x6c\x47\xf6\xb8\xc3\x06\xe9\x70\x96\x69\xe8\x46\x67\x77\x14\x77\x99\xe2\x85\xcd\x3b\x8a\x93\xcd\xfb\x7e\xc3\xbe\x1d\x0d\xdd\x87\x86\xdb\x51\x44\xd9\xd1\xaf\x51\xf1\xb4\xeb\xd2\xb4\x4c\x60\x77\x61\xf3\xfe\xa3\x91\xdc\xd0\x48\x3f\x0f\x2c\x18\x11\x2b\x0f\x86\xc4\x1f\x13\xe3\x2e\xa1\x3d\xfb\x5b\x62\xec\x51\x46\x2f\x4b\x0a\xad\x20\x5c\x12\xf0\x4b\xf6\x7e\x62\x46\x10\xf0\xa7\x5f\x23\x9b\x1d\xce\x68\xbc\xe2\x81\xfd\x44\x6b\x75\xf9\x9a\x3c\x86\xe6\x92\xe0\x98\x53\x0d\xcb\x3a\xf7\x3d\x8f\x34\x86\x32\xf1\xef\x3b\x48\x05\xe1\x1d\x61\xb4\xf5\x4e\xa9\xa2\xfa\x59\x2a\x7c\xc2\x6b\xc6\x40\x8b\x0e\x38\x96\x38\x24\xa5\x45\x63\x8c\x3b\xa5\x5d\xeb\x44\x56\x8b\xf7\x4d\xc7\x33\x24\x9b\xc4\x83\x87\xa8\x0b\x1e\x48\x4a\x15\x59\x03\xea\xd8\x96\x7f\x03\xe9\x39\x68\x99\x7c\x43\x98\x71\xce\xb3\x46\x48\xe9\x6b\x1e\xa9\x25\xf6\x2c\xa7\x8a\xad\xfe\x65\x6d\x3e\x76\x8a\x17\xdc\x15\xf1\x6c\x61\xe5\x61\x97\xd5\xe1\x4a\xfd\x83\x15\x1c\x6f\x60\x43\x9e\xd2\xc9\x98\xce\x2a\xf9\x95\x4b\x99\x41\xcb\xc7\x19\xb0\x3d\xef\x8d\xdb\x82\x11\xcd\x9a\xb3\x95\x65\xaa\x25\x08\x91\x62\xa9\x45\x98\xd7\x60\x97\xb5\x7d\x6a\x00\x0a\x33\xfe\x60\xeb\x06\xef\x20\x56\x7f\x9d\xa6\x6a\x65\xc1\xf6\x33\xe0\xff\xe0\xbd\x2c\x50\x68\xae\xb1\x4b\xde\x16\xa4\x6f\xfd\x48\x7b\xbc\xb1\xae\x32\x27\xeb\xdb\xbc\xd9\xf8\x42\x86\x56\xee\x0b\x88\x4d\x65\x47\x92\x42\x10\x0b\xcf\xb9\xb5\x0a\x24\x3f\x2f\x4e\x23\x8d\x45\xde\xe8\xdf\x1d\x04\x6b\x27\x77\x64\xe4\xf5\x50\x59\xe8\x81\xe7\xa4\xf3\x08\xbf\x74\xcd\x33\xf3\x60\x04\xd7\x97\xc6\xf0\x82\x1f\x46\xa8\x2b\x96\x42\x9f\xab\xec\xe3\xac\xe1\xad\x4e\x02\xbd\x21\xf3\x6a\x9d\x6f\xdd\x81\x14\x8a\x53\x1c\x4c\x90\xf2\x22\x5d\xb8\x2b\x94\x67\xbc\x26\xc5\xd3\x1b\x67\x63\xb8\x1f\x2c\x09\x3f\x0c\xea\x43\xe9\x2f\x32\x07\xb8\xaf\x79\x72\x81\xed\x0e\xe3\x34\xa5\x45\xb7\x21\x69\xad\x0b\x74\xe4\xdb\xbf\x69\x24\x0c\x21\x19\xb2\x56\x9d\x21\xc3\x07\x14\x6c\x1d\x05\xd7\x01\x69\x1c\xef\xff\xf9\x76\xff\xfa\xf2\xf5\x79\x96\xef\xe3\x93\x2f\xff\x9f\x38\x45\xe3\xd4\x78\x1e\xa2\x8d\x71\x49\xc0\x81\x66\xc6\xa8\xe0\x09\x27\xc5\xe3\x2e\x96\xc8\xec\xb1\x75\x89\x43\xc9\xfa\x47\xd4\x5c\x74\xf1\x08\xc3\xac\x2f\xe5\xd0\x74\x1b\x68\xf6\x97\xee\x9f\x39\xec\x46\x0f\xcf\x1c\xd1\x81\xf7\xe3\x1d\x55\x8f\x2e\x21\x5a\xe7\xfa\x9f\x37\x7e\xe1\xf1\x64\x2f\xec\x7a\xce\x97\x3b\xb4\xab\x35\x1c\x5a\xb7\x05\x83\x73\xdd\x61\x1b\x5d\xdc\xd3\xbc\x05\x76\x42\x61\x6f\xa5\xd5\x09\x1d\xd0\x9b\xb8\xa7\xe0\x36\x4c\x45\xd1\xa1\xc3\x25\x01\x1b\x5b\x6c\x42\xf3\xb9\xc1\x90\x8a\x25\x25\x39\x1c\xa2\xdb\xd8\xc4\x35\x65\x00\x85\x08\x81\x12\xe1\xe5\x58\x71\x84\x53\x74\x9e\x4a\x26\x14\x6d\xd0\x26\x8d\x97\x07\x5f\x40\x08\x9c\x5c\xa3\xfd\x7f\x52\x3d\x19\x9d\x41\x83\x1b\x6f\x05\x7d\x9e\xb2\x11\x64\x4a\xa8\xaa\xd5\x11\xb0\x6a\xcc\xfb\xe9\x5d\x0b\xb2\x0f\x18\xa7\x07\xdb\xca\x94\xa6\xec\xd8\xff\x61\xbb\x63\x89\x38\xad\x27\x31\x7a\x28\x4a\x9f\x23\x35\x67\x8d\x8f\x9a\xad\x61\x72\xbd\x5a\x9c\x45\x81\x39\xf6\xf5\x19\x1d\x50\x26\xcb\x91\xc6\xec\xaf\xba\x47\x1c\x26\x2d\x97\x4e\x7a\x7e\x90\x3a\x74\x3d\xcf\x0e\x93\x04\x31\x7e\x9a\x2c\x37\x8f\x2c\x3b\xe4\x1c\x6f\xac\x0b\x24\x8c\xee\x40\x3c\x7a\xbb\x79\x0a\x07\x8a\xb4\xf1\x78\x53\xb5\xec\xf5\x83\xa0\x3e\xf8\x33\x0d\x6f\xc6\x47\xb6\x7e\xae\x2c\x73\x4c\xae\x7e\x81\xcc\x93\x51\x83\x9d\x3a\xce\xbb\x2e\x59\x62\x21\xba\x16\xa1\x75\x03\xf2\xe0\x71\x96\x3b\x0d\x24\x88\x49\x78\xe8\x7e\xcb\x1e\x6f\xc0\x3b\xc9\xd1\x2c\xd8\xc7\x9f\x8f\xae\xa5\xdf\xd2\xe7\x56\x33\xc1\x41\x4a\xa5\xf0\x16\x94\x4e\x0e\x06\x9d\xe7\x62\x19\x7d\x5a\x7f\x72\x5b\x9e\x0f\x35\xda\x53\xdd\x30\x76\xb0\xfb\xd0\x7a\x8c\xd1\x85\x0a\xf6\xa8\x4b\x69\x61\xa3\x1a\x53\x61\xad\x51\x4f\x47\xf2\xbf\xed\x38\x52\x48\xf3\x41\xf5\x01\xd0\x09\xa6\x6c\xe3\xaa\xcd\x39\x69\x76\xb4\x07\x0d\x51\xda\x2a\xf4\x96\x9d\x8f\x02\x07\x8c\x8e\x07\x0c\xf6\x65\x61\xf3\x71\x21\x56\x9d\x84\x76\x3b\x4e\x9f\x07\x7b\x26\x2e\x41\x4f\xea\x73\xfd\xb8\x59\x62\x42\x16\x17\x93\x90\x35\xdc\x25\x89\xb0\xa6\xd6\x80\x36\x9f\xbf\xb0\x8b\x49\x4f\x73\x36\xfb\x3d\xa7\x48\x4a\x6d\xa8\x57\xb1\x3e\x63\x11\x73\xd1\xc8\x63\xd2\x0f\x36\xb4\x96\x01\x20\x24\xbd\xbb\xf6\xd9\x73\x5f\xb2\x6b\xe8\xf6\x57\xda\xa6\x7a\xa9\x19\x11\xe9\x3c\x30\x1d\x63\x3d\x40\x83\xae\x2d\x73\x4f\x1c\x3f\x7a\xa6\xf7\x6f\xac\x16\xa7\x6a\x79\xe3\x23\xca\x0c\x49\xfb\xfe\x71\x89\xe7\xc4\x74\xf5\x9f\xab\xff\x06\x00\x00\xff\xff\xe5\x3e\xa1\x23\x50\x10\x00\x00") + +func magicJsonBytes() ([]byte, error) { + return bindataRead( + _magicJson, + "magic.json", + ) +} + +func magicJson() (*asset, error) { + bytes, err := magicJsonBytes() + if err != nil { + return nil, err + } + + info := bindataFileInfo{name: "magic.json", size: 4176, mode: os.FileMode(420), modTime: time.Unix(1594526741, 0)} + a := &asset{bytes: bytes, info: info} + return a, nil +} + +var _mazeJson = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x84\x58\x51\x73\xdb\xb8\xae\x7e\xef\xaf\xe0\xf8\x39\xfd\x03\xf7\x2d\x71\x93\xb6\xb7\x49\x9b\x1b\xa7\xcd\x9d\xdd\xd9\xd9\x81\x45\x58\xc2\x9a\x22\xb4\x20\x69\xd7\x39\x73\xfe\xfb\x19\x80\x74\x2c\x27\xdd\x39\x4f\x16\x25\x8b\x22\x81\x0f\xdf\xf7\x81\xff\x7a\xe7\xdc\xc2\x97\xd8\x23\xc7\x3f\x31\x66\x81\xd8\x61\x5a\xfc\x8f\xfb\xfd\x9d\x73\xce\xfd\xbe\xb8\x0c\xc1\x05\x5a\x0b\x08\x61\x5a\x5c\x2c\xae\x10\x76\x28\xce\xc3\x68\x83\x81\xa2\x77\x7b\xc8\x28\x1b\x08\x61\x71\xb1\x58\x0e\x10\xb6\x4e\xb0\xcb\x10\xfb\x80\x76\x07\x53\x76\x6b\xce\x99\x47\x67\x63\x1a\x23\x1e\x16\x7f\x5c\xb4\x4f\x2c\xcb\xb4\x66\x10\xbf\xb8\x58\x7c\xe0\x30\x62\x74\x69\x00\xcf\x7b\x1b\xef\xa3\x03\xb7\x47\x9b\xfb\x86\x50\x0e\x6e\xa2\xac\xd7\xdc\x3b\x61\xf0\x76\x29\xfa\x85\x34\x09\xc5\xde\x9d\xe6\xfd\x48\x10\xf5\xc3\xbc\x5d\x5c\x2c\x3e\x1e\xa6\x74\x70\x7b\xe8\x39\x2e\x2e\x16\x9f\x38\x04\xde\xbb\x2c\xa8\x2b\xfc\x54\x7a\x74\x5b\x3c\x0c\x6c\x0b\xfe\x2c\x1c\xdd\x08\xe4\x51\xff\x7a\x4b\x3b\x9d\x36\x43\xce\xcc\xa7\xc9\xef\xa0\xa7\xce\x4d\x40\x31\x53\xec\x17\x17\x8b\x3b\x88\xef\xd3\x00\x13\xba\x36\xcd\x1d\x3c\xa3\x9b\x38\x93\x7d\xf1\x8e\x44\x58\xf4\x82\x63\xca\x28\x6e\xe4\x92\x87\xd9\x78\xcf\x25\xfa\xd3\xfc\x5f\x41\x84\xf7\x0e\x42\xc0\xc3\xe2\x62\xf1\x00\x14\x9d\x67\x9b\x61\x85\x7b\x14\xd7\x0b\x64\xfd\xcc\xaa\x78\x8f\xd1\x09\x6d\x34\x2c\x8f\xe4\x21\xb8\x0e\x76\xfa\xe8\x91\xf7\x28\x99\xa7\xd3\xac\x8f\x82\xe8\x84\x39\x6b\x2a\xbf\x47\x8f\xe2\xf2\x80\x6e\x8d\xde\xc6\x1b\x0e\x1e\xbd\x1b\x61\xd2\xe1\xe4\xe0\x18\xa1\xa7\x81\x24\x4c\xcc\x9a\x85\x27\x8a\xe8\xd6\x20\x82\x61\xf1\xc7\x3b\xe7\x6c\xf2\x17\x0c\x6d\x58\xc6\x33\xfc\x08\x46\x58\x5c\x2c\x2e\xd3\x21\x14\xc5\xcc\xe5\x8e\x40\x74\x4b\x57\x10\xb7\xf6\x93\x07\x03\x16\xfb\x19\x26\xae\xff\xff\xf1\xfa\xe1\xeb\xe5\xad\xe2\x05\x12\x45\xb6\x8b\x0c\x1d\x8f\xeb\x64\xd7\xb6\xc3\x25\x17\xd1\x6d\xbf\xfc\xfd\x65\x82\x07\x66\xfd\xda\x47\x90\x9a\xc6\x4f\xe4\x91\x4b\xb6\xdc\x67\x0c\xf3\x77\x2e\x16\xb7\xb0\x66\x81\xcc\x32\x5b\xc1\xad\x81\xfe\x60\x89\x94\x2d\x66\xcb\x61\xc4\x9a\x31\xd0\x94\xd9\xb3\x92\xd0\xb6\xf5\xb5\x48\xc2\xf9\xfb\xdf\x64\x1a\x20\x42\xaf\x6f\xdc\x43\x80\xce\x2e\x84\x92\xc1\xc1\x72\xa8\xbf\x03\x69\xac\x57\x01\x76\x68\xc8\x3e\xa5\x0a\xc7\xc9\x70\xf4\x38\xa0\xd6\xd7\xf9\x8a\xbf\x47\xda\xa1\x24\xca\xba\x88\x1f\x50\x82\xae\xef\x37\x05\xe8\x9b\x8c\x04\x38\xe8\xc6\x67\x29\x89\xd9\x75\x1c\x38\xea\xbb\x4b\x2b\xfa\xe0\x86\xb2\xd6\x51\x80\x92\xb2\xf0\x34\xf0\x9a\x3a\xbd\x21\x94\x52\x27\x9c\x52\x45\xf9\xb2\xc8\xce\xc0\xf2\x81\x12\x0b\x61\x45\xff\xa9\xe4\x14\xaf\x42\x9a\xf0\x8f\xc8\x23\x66\xb1\x59\x3e\x72\x7c\xd6\x0c\x7e\x82\x69\x80\xe7\x5a\xea\x9f\xa8\x1f\xc2\xc1\x09\xf6\x25\x80\x58\x5e\x22\x1e\x34\xbf\xa7\xe9\x3e\xc7\x8c\x92\xf7\x14\xed\x93\x9f\x13\x07\xc8\xe8\xdd\x9e\x62\x9f\x2c\x6d\x07\x14\x7b\x74\x4b\x11\x6d\x92\x5b\xe6\x29\xd5\x6a\x3c\xb8\x8e\x45\xc8\xb3\xa4\x79\xd9\x3e\x1b\x8d\xdd\xd1\x4f\xc7\x1b\x57\x63\x63\x37\x4a\xc8\x34\x05\xd4\x40\xe8\xf8\x2b\xcf\x5e\xbf\x58\x7c\x9b\x30\xba\x29\x40\x3c\x5e\xef\x98\x7c\x9a\x67\xbb\x87\x68\x7b\xfd\x66\x79\x79\xb6\x65\x3d\x60\x57\x24\x91\x41\xf5\x01\x27\xcc\x94\xeb\x60\x35\x09\xec\x43\x0d\xe9\xaa\xa4\x09\xa3\xc7\x59\xf1\xaf\x0e\xe3\x9a\x83\x33\x3a\x51\x04\x40\x08\x0e\xa2\x77\xd1\x48\xa1\x62\x62\x44\xef\x9e\x39\xda\x6e\x7e\xa0\x64\xea\xa0\x55\xa7\xaf\xf3\xfe\x46\x7d\x5f\x04\xf2\x2f\x20\x21\x85\x22\x28\x31\x9d\x57\x6a\x07\x11\x9d\xa7\x64\xe8\xd6\x52\x95\xf1\xe0\x28\xee\x20\x55\x0e\x5b\x42\x8c\xb4\x86\x40\x49\x11\xbf\xa4\x1d\x05\xb7\xb7\xb0\x2f\x39\x04\x98\x92\x95\xa4\x1c\x52\x86\xe0\x7a\xe1\x7d\x1e\xe6\x2c\x2f\xf6\xfc\x03\xf6\x18\x51\xa0\xf1\xe2\x35\x48\x1e\xfe\x2e\xb0\xd5\x67\xd7\x52\xa6\xe3\x7d\x9d\xbc\x68\x56\xf3\x60\xb1\xbc\xfe\x39\xa1\xd0\x88\x31\xcf\xc2\x7e\xfd\x73\x0a\xdc\x56\x77\x03\x63\xad\xcf\x1b\x12\xfb\x09\xcc\x2d\x14\x37\x25\xf6\x25\x19\x00\xcb\x2b\xc4\x7e\xb6\xba\x3c\xe3\x82\x1d\xb8\x4d\xb0\x30\x1b\xc9\x43\x70\x29\x20\x4e\xaa\x5d\x77\x18\xb2\xad\xe6\xc8\xda\x90\x33\x74\xdb\x5f\xf2\xd6\xb7\x92\x13\xf9\xd3\x7f\x2a\x34\x5a\x58\x2e\x16\xf7\x5a\x1c\x1b\xea\x2c\x10\x3a\xf7\x7d\x80\xbe\x60\xbd\x88\x20\x8e\x77\x28\x01\x66\x8c\x72\xcf\x4a\x1e\xae\x87\x64\x70\x4a\x5c\xa4\xc3\xe4\x7a\x8e\x15\x5f\x3b\x36\x16\x78\xa0\x84\xd1\x79\x34\x6d\x7c\x64\x76\xa3\xd6\x42\x16\xb0\xc2\x78\x02\xf9\x15\x20\x70\x0f\xe2\xcf\xd0\x10\x3b\xad\x6e\x17\xd8\x82\x79\x19\x69\x84\xa0\x72\x74\x68\xc0\x50\xca\x0e\x78\xe4\x85\xab\x50\x50\xf5\xd7\x6a\x69\x59\x42\x2e\x4a\x2a\x20\x99\x36\xd0\xcd\x58\xed\x3a\xe2\x78\x70\x7b\x84\x6d\xc4\x94\x2c\x6b\x9d\x05\xa0\xcd\xac\x5a\xbe\x07\x89\x75\xd6\x8f\x85\x3c\x56\xb9\x56\xa6\x08\x56\x60\x9f\xe3\x26\x14\x25\x9e\xe3\x7a\x66\x74\x91\xb2\x94\xae\x02\xfb\x62\xf1\xbf\xb8\xc7\xa0\x17\x5f\x4c\x42\x6f\x39\x65\xa7\xf2\x54\x02\x58\x6e\xbb\xa1\xe2\xe5\xad\x78\x1c\xf3\xde\x16\x75\x67\x7a\x78\x07\x42\x79\x7e\x53\x01\x30\x11\xbe\x06\xd0\x37\x81\x2e\xe0\x2c\x6d\x14\x30\x19\xd9\x30\xe7\x53\x7a\x27\x96\x6c\x15\x7b\xaf\x74\x8b\x9d\xa9\x3c\x46\xde\x9b\x3c\x4c\xd5\xf1\x3c\x0a\xc4\xa4\x6b\xae\xe5\x32\xd3\x71\x88\x49\x67\x78\xad\x0a\x9d\xa2\x06\xbd\x9b\x02\xbf\x7a\xf6\x83\x5a\x9d\x3c\x21\x4c\x3a\xd7\x1b\x10\x68\x26\x76\x94\xe9\xcc\xff\x5d\x61\x22\x34\x11\x5b\xc2\x94\x8b\xbc\xda\xac\x16\x3e\x76\xd9\xae\x5a\xf4\xeb\x75\x16\x0e\xa7\xf5\x7e\xc0\xa0\x7a\x65\xe5\x3f\x72\xa0\xa4\x15\x70\x9d\xba\xca\x6f\x37\x88\xcd\xc7\x65\xda\x1c\x2c\xef\x20\xde\x8d\xb5\xc6\x4e\xb3\x7c\x6a\x68\x28\x31\x57\xaa\xcf\xa7\xe4\xfc\x53\x2a\xbf\x62\xcf\x99\xaa\x55\xba\x07\x5b\x95\xd6\x9e\x68\x50\x9d\x50\x2e\x35\x07\x45\x6c\x8f\xff\x57\x30\x35\x02\x7a\x00\x9a\x31\xf2\x03\x4e\x40\x52\xeb\xae\x2b\xb5\xde\x12\x82\x74\x43\x2d\xbd\xc6\xf1\xe4\xbd\x69\xf6\x4a\x1d\x58\xec\x67\x28\x58\x21\x3d\x1b\x97\x97\x18\xcd\x7e\x7c\xaf\xdc\x66\xf2\x1d\x3d\x84\xfa\x78\x16\xda\x27\x96\xa4\xee\xe0\x17\xd5\xca\xfc\xca\x63\x8d\x7c\xb4\x54\x7f\x17\xcc\x6e\xa8\x5e\xfc\x0a\x44\xa0\xdb\xa6\x57\x29\x7b\x65\xa3\x64\x86\xab\xe5\x00\x95\xdb\xd5\x57\x1d\xaa\x50\x2f\xe5\x30\x65\xf3\xe2\x32\x52\xae\x1f\xba\xa1\x7e\x50\x1e\x7d\x31\xe3\x32\xdf\xeb\x0d\x97\x98\x81\xa2\xf9\xaf\xac\x86\xb8\x18\xf5\xd7\xb4\x4a\x75\x66\x5f\xb0\x05\xe2\xbf\xf8\xb0\x3b\x4c\xe9\xb8\x21\xcd\xb2\xaa\xa2\x59\xdd\x17\xeb\xf5\xad\xac\x03\x61\xae\x29\xae\x1e\xb5\xf9\xac\x59\xfa\x3a\x3e\x7d\x7a\x35\x48\x85\xcb\x2a\x40\xe9\x87\x8c\x72\x5c\xe1\x2a\xc3\x3a\x98\xa4\xae\x32\x0b\xb6\xff\x3f\x0e\xc2\xb1\x0e\x4e\x15\xc8\xa2\xd5\x70\x9c\xf2\x51\x10\x52\xb1\xd8\xcc\x6b\xae\x19\xb3\xa7\x5a\xcd\x4f\x2c\xdb\x34\xf0\x3f\xa5\xf4\x4f\x8f\x19\x28\x9c\x55\x1f\xa4\xf7\xca\x7b\xb8\x31\x8e\x65\xf6\x4a\xe4\x64\xc9\x6d\xda\xbf\x1c\x80\x62\x7a\xe9\xbc\x46\x10\x4b\xf8\x32\xc0\xbe\x0d\x4e\xd9\x65\x99\x52\x7d\x49\x71\x81\xde\xad\x11\xc6\x3a\x2e\xe3\x5a\xfd\x88\xdb\x43\x30\xce\xfc\x80\x1d\x1c\xf4\xc6\x46\x3f\x3a\xbf\x11\xb5\xd9\xd2\x1b\x42\xd3\x54\x5f\x39\xab\xd2\x1b\x50\xd5\x75\xa3\x2a\x40\x65\x78\xd2\x36\x4c\x10\x0d\xe1\x75\xb8\xd1\x1e\x24\xe3\x54\xff\x10\x82\xba\x2b\x0a\x01\xcc\x6c\xbd\xc8\xf5\x4d\x91\x48\x46\x3a\x27\x87\x29\xb0\xd9\x50\x26\xd3\xe0\x04\xd4\x55\x31\xec\x54\xab\xc4\x8a\xd4\x6e\x70\x36\x78\x6a\xf3\x67\xe3\xb2\x5e\xd7\xc2\x1c\xd0\xbb\xb4\xa5\x19\x36\x56\x81\x46\xac\x61\xb5\xc4\x4f\x26\xda\x7b\x5c\x57\x18\xa8\x75\xcf\x94\x1b\x28\x30\x5a\xc5\xaf\x46\xde\xa2\x4b\xb9\x85\xfe\x71\xa0\x6e\xeb\x7c\x49\xf9\x0c\x20\xd1\x75\x81\xf3\x60\xaf\xbe\xea\xbc\x4a\x2a\xea\x2b\xc6\x0a\x8c\x1f\xda\x6b\x1c\x65\xeb\x07\xd5\xc4\x3e\x0d\x94\x26\x54\xf3\xfa\x06\x2d\x6a\xab\xb7\x67\x0c\xb0\x4e\x2c\x47\xeb\x74\xa9\x3c\x7e\xf4\x57\x26\xdc\xed\xfa\xa8\xd7\x96\x71\x1e\xc7\x12\x9b\xfd\xa8\x94\xbd\x29\xe9\x4c\x64\x94\xd1\xcb\x78\x9c\x75\x29\xf8\xf2\x5f\xb5\x72\x0d\x24\x78\x7c\xfe\xa1\x4c\xe1\x34\xdd\x5b\x22\xbe\xfe\xd9\x0d\x10\x8d\x65\x3f\x8f\x93\xd5\xa7\x9a\x39\x13\xf4\x33\xd9\x36\xd3\x2f\xdc\xc3\x4b\xe7\x1c\xfd\xfb\xae\x29\xca\x2f\xd5\x9a\xd9\xbf\x87\x90\x4f\xa6\xf2\x6b\x09\xe1\xc5\x5b\x9d\x97\xa4\xaa\x2f\xa6\xa1\x76\xcb\xf7\xc2\x19\xbb\x23\xe1\xe3\x5f\x65\x87\xf1\x95\xd2\x3e\x60\x40\x48\xcd\x60\xa1\x24\x93\x8b\x07\xce\xc7\xa9\x57\x9d\x1c\x9a\x8f\xa7\x67\x3c\x5f\xc6\xaa\x8c\x23\xc7\x33\xbb\xf9\x38\x60\xeb\xd3\xc7\x57\x7f\x7e\x25\xf5\xed\xc6\x58\xf2\xd9\xd8\x5c\x43\xbb\xf1\xc4\xda\xc0\xff\x02\x1e\xb5\xc7\x3a\xc3\x47\x47\xde\x79\xb1\x5e\xd3\x68\x24\x95\x6e\x8b\x72\x94\x80\xf7\xc6\xd5\xcb\x81\xb7\x5a\x34\x86\x63\xe3\x04\x8f\x8e\x8d\x6c\x8e\xa6\x3e\x0d\x36\xf1\x4c\xd7\x61\x83\xd1\x58\x81\xa9\xd9\xfb\x98\xd0\x6d\x58\x23\x72\x1d\x53\x04\x3b\x94\xd9\x35\x4c\xb7\x52\xdf\x84\x7a\x92\x31\xb7\xe8\xca\x0f\xe7\xbd\x24\x1e\x52\x5d\xe2\x1d\xf4\x63\xb5\x6c\x7d\xc4\x4c\x9d\xdb\x10\x06\x73\xe1\xc5\x1f\xad\x7a\x3b\x2f\x09\xe8\x0d\x62\x6d\x38\x41\x4a\x30\x97\xa6\xa3\x87\x66\x36\xb1\xb0\x81\xb6\x75\x56\x96\xf7\x82\x1d\x4d\xd4\x55\x27\xa0\x25\x06\xd1\xda\x38\xf0\x74\x0c\xfa\x03\x77\xdb\x14\xd4\x88\xcc\x8e\x1a\x72\xc6\xe8\x3a\xa4\xd6\xd1\xb5\x1b\xc7\x5d\xae\x28\x6e\xdb\x99\xd0\x2a\xd0\x34\xa1\x1c\x5c\x0a\x3c\xe1\x5b\xb6\x99\x58\x70\x16\xde\x55\x46\x18\xdd\x0e\xeb\xf2\x56\x59\x58\xe9\x96\xa2\x37\x46\x51\x13\x49\x15\x4c\xfd\x90\x5f\xf6\xaa\xa6\x7f\x9a\x8c\xcc\x79\xfd\x57\x35\x67\x8f\xfc\x53\xc3\x56\x46\x9c\xd3\x89\xf6\x04\x7f\xe2\x66\x83\x5d\x7e\x03\x96\x76\xd8\x73\xe9\x07\x6c\x0d\xec\x65\x00\x19\xab\xf9\x67\x71\x23\x86\xdc\xce\x03\xc5\x9a\x0b\x43\x56\x6d\x3e\x5d\x9a\x64\xde\xb8\x5c\x85\x12\xb3\xd3\x26\xb7\xd4\x33\xa0\x2b\xb6\x50\xb9\x3c\x6f\x1e\x4d\x6c\x5a\xc8\x96\xc2\x1d\x7b\x0a\xd8\x76\xb8\x94\x92\x86\x73\x79\xc2\xe9\xfc\xbc\x44\xa1\xa5\xff\xe8\x6a\x0c\x5e\x86\x2f\x59\xb9\xa1\x10\x92\xdb\x53\x1e\x5c\xcb\xeb\x0c\x7e\xf5\xac\x70\x34\x80\x59\x9f\x28\xde\xed\xa0\x2b\x65\x26\xf9\xf3\xce\xf0\x56\x43\xde\xba\x94\x76\x42\x98\x32\xe4\xd2\x0e\x17\x52\xd2\xb5\x6f\x6a\x23\x7a\xec\x15\x37\x52\x7d\xee\x57\xcc\x35\x62\x27\x54\xb6\xd0\xb8\x75\x00\x8f\x27\x64\xd6\x56\xaf\x0d\x22\x62\x35\x97\xe7\xd0\xec\xf1\xd8\x11\x72\xdd\xf1\x9a\x4b\xf0\x73\x41\x7e\x60\x1e\xed\xe3\xf5\xe8\xc3\x86\x1c\x8f\xab\x5b\x69\x6f\xab\xef\xd5\x59\x56\x13\xa9\x31\x68\xc0\x52\x9b\xe8\x78\xb2\x13\xb4\x27\x08\xc1\x25\x7d\xfc\x06\x43\x59\xa8\xef\xb5\x56\x67\xce\xa5\xc6\xe9\x4a\x10\xec\x94\xaf\x48\xa3\x98\x5a\x5e\x4b\xb5\x88\xbe\x36\x3b\x1f\x40\x6a\x37\x78\xa2\x15\xa9\xee\xf1\x1a\x9a\x3e\xa0\x75\x3a\x5f\xc8\xd4\xf2\x4b\x64\x6b\xa7\x2d\x07\xaf\x9a\xb6\xda\xa3\xb3\x3f\xd8\x11\x4e\xa5\xa4\x6f\x75\xfd\xf7\x83\x54\x22\xbf\xe7\x32\x8b\xce\xbd\xd4\x46\xf4\x5e\xf8\x27\x8d\xf5\x40\xed\xbe\xd8\x87\x1e\x6a\x0f\xfd\x80\x9b\xd6\xe3\x1c\xc5\x60\xa6\x0e\x23\xb7\xd3\x9d\x2c\x84\xf5\xb2\x78\x6c\xcd\xed\x6a\xb0\x13\xc7\x95\x05\xd3\x02\x7d\x66\x3b\x7c\x2d\xd6\x62\x96\xe2\xb1\x46\xe8\x7b\x5c\x43\x80\x68\x41\x3a\xb5\x08\x4f\x42\x19\x6b\xd4\xdf\xfd\xfb\xdd\x7f\x02\x00\x00\xff\xff\x1b\x2f\x29\x87\xb5\x17\x00\x00") + +func mazeJsonBytes() ([]byte, error) { + return bindataRead( + _mazeJson, + "maze.json", + ) +} + +func mazeJson() (*asset, error) { + bytes, err := mazeJsonBytes() + if err != nil { + return nil, err + } + + info := bindataFileInfo{name: "maze.json", size: 6069, mode: os.FileMode(420), modTime: time.Unix(1594526741, 0)} + a := &asset{bytes: bytes, info: info} + return a, nil +} + +var _monsterJson = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x6c\x57\xcb\x72\xe3\xb8\xce\xde\xf7\x53\xa8\xb2\x9e\xbc\xc0\xbf\x4b\x1c\x27\x4e\xff\x71\xc7\x15\xbb\x3b\x53\x35\x35\x0b\x48\x82\x25\x94\x21\x42\x0d\x92\xf6\xb8\x4f\x9d\x77\x3f\x45\x82\xb2\xe5\xa9\x5e\xf1\x8e\xdb\x87\x1b\xff\xf3\xa5\xaa\xee\x00\x95\x80\xef\xfe\xaf\xfa\xeb\x4b\x55\x55\xd5\x5f\x77\x0f\x5c\x43\x50\xf1\xfe\xee\x8f\xea\xee\x11\x42\x1e\x10\x03\x63\x9e\x91\xb6\x95\xec\xab\x0d\x28\xb4\xe4\x6d\x2f\x86\x80\xba\xe7\x73\x5a\x2c\xc4\xb5\xa2\x77\x7f\xff\x51\xc8\x2d\x14\x5c\xbe\xb5\x50\x39\xa5\xf1\x49\xa1\x13\x57\x6e\x2f\xa1\x33\xba\xcf\xc0\x8d\xb8\x3c\x23\xc5\x74\x7a\xa1\xf0\xcc\x30\x90\xeb\x24\x1f\xda\xb3\x67\x3e\x93\xeb\xaa\xed\xcf\x48\xaa\xc8\x69\xeb\x45\xc4\xa4\x79\x89\x9c\x37\x56\x71\x48\xcf\x6a\xd2\xf6\x4a\xeb\xff\xc9\x75\x7b\xf2\x3d\x6a\xba\xf2\x26\x4d\xf4\x59\xc1\x35\x74\x23\xa1\xcd\x5c\xa0\xac\xfb\x5a\x9a\xc3\x44\x20\x2f\xfd\xcf\x48\x41\xae\xc4\xd6\x12\xfa\x74\xf2\x7e\xca\x0c\x37\xa0\x2a\x99\xda\x06\xa1\x91\xe6\x60\x53\xa6\x06\xb2\x62\x9b\x80\x0a\x4e\x5a\x71\x57\x12\x1f\x22\x3e\x98\x30\xdb\x31\xbd\xcf\x26\xda\x9e\xec\xc5\x8f\xc8\x21\x6a\x16\xeb\x13\xfc\x98\x47\x91\x76\xc4\xe6\x80\x7a\xf7\xf7\x97\xaa\xca\x84\xee\x02\xaa\xa2\x0f\xff\x06\xd2\x65\x61\x1e\xc6\x4c\xe0\x41\x07\x68\x89\x59\x0c\xd6\xb6\x33\xae\x8f\x08\x36\x0a\xcc\x41\x83\x80\x3a\x12\xb3\x1d\x2e\xd0\x05\x1a\xb1\x35\x1c\x7b\x18\x90\xd1\xc0\x5a\x48\x73\x50\x81\x26\xdb\xe1\x09\x8d\xe6\x92\x71\xec\xc1\x85\x19\x84\x49\xc0\x2c\xcd\xb3\xfc\x93\x41\x22\x85\xfd\xde\xf0\x12\xf3\xb1\x95\xa8\x01\xb8\x8a\x03\xb8\xb9\x95\xcd\x43\xde\x93\x82\xc6\xe8\x3d\xd3\xd8\x88\x36\x71\x24\xf3\xae\x0f\xa8\x6b\x0a\x36\x6b\x1a\xb9\xb1\xb1\xd1\xff\xe8\xc9\x49\x83\x2a\x19\xdc\x6d\x23\x3a\x92\x29\xb1\xed\x11\xb3\x71\xb7\x1c\xbb\x3c\x3a\x20\xbe\x12\xd8\x3a\x38\xa0\x41\x44\x6d\x01\x6b\xe6\x79\x3b\x2a\xb6\xfc\x14\xde\x97\xf1\x88\x9a\x04\xbb\x42\x04\x3f\x23\x04\x6a\x6e\xe2\x8c\xa9\x83\x20\xf9\xe9\xc3\x20\x58\x43\x9e\xb9\x8e\x51\x93\x8f\x16\x78\x8e\x46\x7c\xc1\x30\x58\x18\x41\x7d\x15\xed\x49\x78\xec\x29\x6b\xb1\x34\x69\x9e\x55\xb2\x0e\x2b\x1a\x47\x19\x25\xc0\x10\xb3\xc2\x5f\x91\xf9\x3c\x91\x7d\x43\x6c\xfa\x2b\x95\x37\xa9\x27\x2f\x5c\x83\x83\x80\x97\x48\x80\xea\x03\x72\xc4\xad\xa3\x3f\xa8\x19\xf2\x1b\xe8\xa9\x87\xcc\xec\x1b\x9e\x66\x28\xbf\x37\x41\x46\xe3\xf6\x1e\x0a\xbd\x0d\xba\x2e\x9a\x80\x1b\x86\x70\x2e\xe7\x9b\xb8\xdf\x5f\xb5\xdc\x02\xc3\x00\x2e\xd9\xf6\x6a\x74\x84\xea\xc1\xe1\x20\x86\x6f\x5a\x7e\xd7\xa6\xe8\xba\x45\xe8\x27\x77\xd9\xa2\xc9\xb2\xed\x41\x0f\x36\x51\x1a\xc6\x19\xa5\x9f\x91\x5a\x0b\x2b\xd1\x76\xe2\xb9\x83\x76\x2c\x9e\xb5\x8b\x5a\xb2\xdb\x27\xb0\x9a\x80\x9f\x3d\xf0\x1c\xbf\x3d\x42\x0a\x45\x7f\x1b\x5f\x8c\xea\x0b\x4c\x99\xf5\x02\x14\x46\x68\xb0\x00\x76\xf2\x16\x23\xc3\x28\xd1\xb5\x15\x9e\x31\x6f\x2c\xcf\x58\x6d\x03\xf0\xc1\xcf\x22\x04\x5c\xe7\x2d\xfd\x39\x1b\xa3\x5a\xa0\x30\x7b\x0b\x0f\x39\x62\x99\xa9\x9b\xbd\x7c\xc3\x8e\xd1\xb2\xf5\x9b\xb8\xae\x0a\xe2\xba\x38\x01\x78\xbe\xc7\x33\xb6\x97\x05\xd3\x50\x97\x65\x6c\x0a\x12\xe4\x9a\xa4\xc5\x85\x5e\x82\xc9\x18\x6d\x38\x0e\xd0\x65\x52\x1b\x95\x5a\x7c\x43\x25\x76\x80\xed\xc6\x16\xbb\x01\x5d\xf0\xc5\xfe\x5d\x77\xae\x7a\xa0\x39\x8a\x3d\x5a\x36\xde\x8e\x74\x28\x6f\x46\x72\x0e\x15\xc3\x65\x55\xf6\x03\xb9\x12\x48\xdb\xd8\x04\x12\x57\x35\x71\x9c\x09\xb6\x4b\x41\x99\x91\x63\x31\x1b\xed\xd0\x05\x68\x8a\x2c\x3b\x8d\xee\x60\x70\xfa\x83\x61\x48\xc9\xa6\xb3\x34\xa9\x40\xe1\x06\xc1\x61\xec\xa9\x26\x31\x4b\x3c\xb2\x40\x30\xeb\x3c\x2a\x85\xe2\x12\x0b\x70\x8e\x6a\x73\xb1\x05\x43\xb2\xa1\x25\x83\x85\xb0\x78\x0f\x3c\x2f\x75\x67\x1f\x80\xb9\xa4\xa4\x27\x6c\x20\x95\xa9\x0c\xf9\x9f\xbb\xe5\xc7\xb7\x87\xb7\x3c\x0f\x3d\x6a\x71\xda\xe5\x11\xf5\xfe\x2c\xb1\xdc\x3a\x63\x86\x72\x96\x37\x41\x27\x70\x9f\x39\xee\xf7\x56\xfd\xa2\xeb\xec\xf9\x0b\x32\x04\x72\x45\x81\x17\x94\x01\x53\x92\xcc\x5e\x02\xda\xa2\xc3\x59\xed\x7b\x65\x8e\x5e\x34\x93\x78\x75\x01\x53\xfe\x41\xab\x11\xaf\x4a\x2d\xfa\xa6\xac\xde\xe2\x70\xa1\x99\xdd\xa6\x47\x68\x8b\xdb\x60\xd3\x83\xa3\x66\xae\xf6\x5c\xb7\x0d\x83\xb3\x9a\xf1\x81\x7b\xc6\x26\xd0\xd1\xd2\x73\xac\x6b\x34\xd6\xdb\x1e\x5a\x39\x4d\x53\x9d\x07\xea\x01\x19\x43\x89\x66\xa6\xe1\x5c\xdc\xa2\x39\x4c\x33\x77\x28\xf6\xdc\x91\x3b\x1b\xe8\xe0\x3c\xc7\x2c\xf9\x2c\xd9\xd6\xc4\x14\xe8\x36\x5a\x6b\x2f\x5a\x97\xe7\x0f\x0d\xb5\x55\xcd\x22\xad\xa5\xdc\x40\xf7\x03\x74\x66\xb8\x47\x26\xd7\x96\x7b\x8f\x8a\x10\xfa\xea\x84\x30\x96\x7a\x07\x83\xc4\x3d\x43\x97\x2e\x5c\xb3\x70\x1c\x53\x95\x0f\x13\xd8\x49\xf1\x02\xc3\xd2\x05\x70\x1d\xff\xce\x0d\xfe\x19\x59\x26\x46\xd6\xd0\x5c\x29\xbe\xc0\x2f\x9c\xb1\x5d\x9d\x47\x27\x81\x7e\x95\xdb\xaf\xc3\x88\x7a\x9c\xfc\xf6\xd5\x1d\xc9\x53\x6d\xee\xfa\x46\x7b\xbc\x6f\x15\xc8\x95\xbb\x6b\xe8\x1c\xa6\xca\x73\x2d\xa8\x34\x50\x33\x19\x72\x4d\xae\xbd\xff\x40\x98\x04\x49\x7d\x1d\x9f\x27\x46\x9b\x1e\xfc\x6f\x44\xdf\x08\x79\xc9\x1e\x32\x2b\xb2\x2d\x09\x5c\xf1\xbe\x45\x1f\x3b\x74\xa8\x17\x03\x6d\x7b\x18\xd1\xf7\xb4\xbf\x6c\x8c\xc8\x7c\xdf\x80\xbf\x6c\x04\x04\x0e\xfd\xac\x0b\xdc\x06\x9d\x19\x72\x1b\x47\xd4\x7b\x1f\x14\x5d\x67\x4d\xd8\x0e\x19\x0f\x64\xaa\x96\xe5\x28\x3a\xd1\xfb\x01\xc3\x48\x05\x92\x4f\x60\xbe\x5f\x28\x9c\x32\xb1\x59\x7a\x48\xe2\x37\xb7\xf9\xa1\x8e\x56\x2d\x16\xc0\x5c\xed\x45\x2b\x1f\xc7\x44\xd6\xf6\xc6\xa9\x3b\x5b\xf4\xa0\x5d\xc9\xfa\x34\xd4\xd5\x5e\xf0\x92\xfa\x91\xab\x93\xa8\xef\x69\x9c\x67\x0a\x84\x80\x55\x0d\xaa\x64\x29\xef\x09\x1b\x2c\xd6\x7a\xc2\x54\x0b\xab\x36\x5a\x41\x7f\x22\x2f\x4a\x25\x34\x97\xae\x21\x6d\x0c\xea\xe5\x11\x5a\x9c\xbb\x8c\xeb\xaa\x98\xfb\x98\x17\x48\x29\xa6\x9a\x9b\xe7\x45\xaa\x1a\xd5\xa3\x95\xc8\x15\xa8\x05\xe3\x2a\x2a\x5f\xa4\x7d\x1d\x06\x49\x91\xf3\x6b\x46\x75\x0d\x8e\xc6\x98\x4a\xc2\x5d\x69\x89\x6d\x74\xc2\x52\xca\xcc\xbb\xb6\xa8\xd5\x40\xae\xb4\x53\x1b\x95\x80\x4d\xa8\x38\x65\x0d\x9d\xef\x78\xe4\xfd\x0c\xd1\x06\x52\x97\x70\x61\x9f\x4b\xe2\x05\xfc\x6a\xaf\x32\x58\xd5\x06\x1d\x2c\xef\x6b\x87\xa1\x22\xe7\x85\x8b\x39\xca\x56\xe1\x34\xab\x14\x79\xdb\x21\xa4\xb6\x78\x76\x31\x35\x90\xb7\x3b\x3e\xa8\xb8\xee\x76\xef\x84\x70\x98\x76\xe4\x5c\x9d\xc8\x4c\xf8\xdd\x63\x95\x3a\x6d\x20\x37\xf3\x9a\x11\xd5\x8b\x03\xa6\x70\xbe\x69\xee\x08\xb3\x31\x1e\x58\x24\x37\x85\x8f\xa2\x96\x42\x17\x10\xc3\x14\xba\x0b\x39\x81\xb6\xe5\xe3\x14\x95\x6e\x42\xea\x09\x2f\x21\xfe\x44\x3e\x68\x72\xcf\x12\xe5\xcb\x36\x36\x53\xad\x5a\x0e\x35\x25\x3b\x96\x95\xbb\x3c\x5a\x6a\x6c\x29\xe0\x4d\x8f\x91\x7a\x50\x4b\xb0\xcf\x92\x74\xdd\xc7\x52\x47\x1c\x6a\x79\xb6\x82\x80\x65\x7b\x25\x4e\x14\x0a\xcf\x55\x1c\xd2\xec\x42\xed\xeb\x54\x13\xbe\xca\x91\x8c\xe6\x1b\x76\xc0\xe4\x4b\x08\x5e\x5c\xa7\xf8\xf5\x3a\x9d\xca\x00\x8e\xc0\xce\x91\xc1\x35\xbd\xcc\xff\x7a\xeb\x14\xbf\x91\xa7\xe2\x73\xf6\x17\x79\xdf\x6b\x8f\xde\x17\x52\xef\x31\xa4\x4f\xe8\x4e\xa2\x7d\x08\x52\xd6\x72\x62\x5d\xde\x46\xf8\x46\xeb\x8d\x3f\x37\xbd\x8c\x10\x7a\x13\x6b\x2b\x63\x9f\x65\x9c\x0c\x98\xa9\x64\x08\xbe\x3b\x1a\x46\x45\xef\xed\xe0\x07\x58\xb7\xf9\x27\x3a\x19\x7b\xa9\x53\x12\xbd\xe0\x9e\x9c\xc4\xa5\xd2\x7c\x05\xfd\x11\x4b\xaf\x96\x3e\xc9\x5e\x2c\xf3\x2c\x7a\xe2\x56\xb1\xfc\x96\xb8\x9d\xc6\xea\x55\xa7\x2f\xd4\x30\x62\xa0\xd4\xf0\xcc\x12\x84\xb8\x23\xaa\x87\x50\x62\xea\x09\xf7\xa2\x43\xf2\xb1\x5c\x2c\x72\xe0\x94\xb9\x9c\x4a\x13\xfa\x42\x7b\xeb\xa9\x5e\x12\x9b\x0b\xa9\x15\x4e\xff\x2b\x3e\x57\xaf\xe5\x93\x9d\x17\x9f\x50\x9a\xf4\x95\x0c\x58\x2d\x44\x0e\xbf\xc9\xf5\x6b\x52\x95\x79\x7f\xb8\x26\x1f\x18\x83\x94\x84\x20\x8e\xa9\xeb\xed\x13\x1d\x7d\x29\x7a\xf3\x5a\xd1\x9f\x19\x9a\x49\xdc\xcb\xc9\x15\x9e\xf8\xeb\x57\xe9\xe0\x3e\xa8\x6d\x2f\xd3\x10\xc1\x8c\xb9\x25\x3e\x4e\x6d\xe1\x95\xd7\x0e\x61\x2e\xd4\x4e\x23\x56\xdf\x60\xc0\x7f\xb3\xff\x44\x38\x54\xdb\xd1\xfe\xe5\x37\x07\xa5\x4b\xfb\x14\x1d\x4e\xa9\x11\xc8\xd0\x7e\xf9\xef\x97\xff\x05\x00\x00\xff\xff\xea\x9d\xca\xac\x16\x11\x00\x00") + +func monsterJsonBytes() ([]byte, error) { + return bindataRead( + _monsterJson, + "monster.json", + ) +} + +func monsterJson() (*asset, error) { + bytes, err := monsterJsonBytes() + if err != nil { + return nil, err + } + + info := bindataFileInfo{name: "monster.json", size: 4374, mode: os.FileMode(420), modTime: time.Unix(1594526741, 0)} + a := &asset{bytes: bytes, info: info} + return a, nil +} + +var _npcJson = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x7a\x5b\x8e\xe4\x3a\xce\xe6\xfb\x59\x85\x90\xcf\x95\x1b\x98\xb7\xca\x5b\x65\xd5\xc9\x5b\x67\xe4\x39\x39\x98\x46\xa3\x40\xdb\x0c\x9b\x1d\xb2\xe8\xa2\xa4\x88\x72\x0d\x66\x41\xbd\x8e\xde\xd8\x40\xa4\x1c\xe1\xa8\x3a\x7f\x2f\xe0\xc7\x0f\x24\x90\x92\xc3\xd6\x8d\xe4\xc7\x8f\xa4\xfe\xef\x6f\xce\x5d\xb4\xb4\x27\x4f\x3f\xb0\xfb\x1a\xa6\x36\x5e\xfc\x2f\xf7\xf7\xdf\x9c\x73\xee\xef\x17\x1f\x5b\xf6\x73\xc2\x8b\x0f\x17\x1f\xdb\xc4\x52\xfe\x4f\x9c\x06\x6c\x41\xe6\x8b\x0f\x17\x57\xb0\x43\xd1\xff\xd2\x58\xc3\x43\xbb\x8b\x23\xa5\xe1\xe2\x1f\x1f\xea\x18\x57\x82\x07\xfb\x31\x0b\x42\x6e\x05\x92\x76\x52\x3b\xe8\xe3\x6b\x90\x09\x43\xb2\xb6\xe7\x76\x37\xd6\x51\xaf\x39\x0b\xa1\x9c\x46\x2a\x0f\x12\xe9\x6f\x37\x34\x79\x1e\x75\xa4\x3b\x8a\xc3\xc8\xa1\xd7\xe7\x9f\x32\x48\x77\xf1\xe1\xe2\x1e\x1a\x94\x0e\xa2\x4d\xf1\x39\x84\x1d\xe2\xb4\x1e\xeb\x73\xc2\xf1\x32\xa2\xf7\xfa\xc2\x17\x3c\xa0\xb5\x7e\x0f\xd4\x0f\x65\xd8\x07\x5e\x76\xf2\xe1\xe2\x11\x22\x87\xf2\x9f\xf4\xfd\xe3\x20\x8f\x39\x52\x4b\x50\x7e\x7a\xe2\xc6\x97\x73\x7a\x01\xaa\x7b\x79\x11\xc2\x58\x46\xda\xb4\x03\x7b\x10\x6d\x09\x35\x78\xfa\x7e\xd3\x66\x3f\xd9\xb9\x6e\x06\x9a\x0e\x52\xe7\xde\xb0\xef\x6c\x9f\x6f\x40\x9e\xad\xf1\x9d\x3a\x94\x91\x74\xc8\x77\xea\xed\x94\xfe\xf1\x9b\x73\x3a\xdc\x45\x0e\x1d\xca\x81\xc5\xff\x2a\x44\xdf\x0e\x58\x3f\xbc\xc2\xbe\x07\xb9\x9c\x84\x42\x8b\x8b\xc0\x46\x20\xdb\xfc\x15\xe7\x90\xe6\xcb\x21\x2f\xe2\x18\x68\x0c\x38\xbb\x78\x40\x9c\x54\x22\x14\x2e\x5b\x4f\xd3\x74\x2e\x96\x90\x58\x12\x71\xb0\x39\xae\x59\xbf\xdf\x22\xd5\x51\xb2\x4f\xf5\x97\x9c\xa6\x2c\xb1\x4c\x7c\x83\x4d\xba\x6c\xd9\x7b\xac\x8a\x75\x83\x11\x25\xad\xc7\xbd\x43\x5b\xe3\x1d\x4b\xca\x01\xd3\x22\xac\x4f\xe0\x7d\x59\x94\x87\x3d\x6a\x77\x6c\xea\x0f\x02\x7b\xec\xa8\x37\x55\xb8\x47\xe8\xe2\x08\xe1\x34\xe0\x3d\x76\x3d\xba\xdd\x22\xe1\x7b\xea\x87\x03\xcc\xa3\xca\xef\x9e\x73\xc4\x46\xb0\xea\xde\xef\xd4\x05\xd0\x6d\x16\xe9\x77\x6e\x12\x9e\x06\x2c\x5f\x3d\xea\xee\x1a\x08\xbb\xd3\xc0\x2f\xd8\x75\xb6\x84\x17\x4a\x97\xdb\x32\xbe\xf5\x98\x22\x07\x6d\xbe\x42\xba\x6c\x61\xd1\xf9\xa2\x08\x7b\xb4\x5f\x36\xe8\x7d\x3c\xb0\x74\x2b\xbd\xa8\x5b\xdb\x8c\xb9\xef\x6d\xe0\x4d\x12\xc4\xe4\x26\x94\x2d\xcb\x58\x75\x23\x25\x66\x3b\xd9\x3f\xa4\x1d\xa8\xec\xe3\x8f\x98\xe5\x4c\x2f\x0e\xe4\x3b\x94\x80\x31\xfe\xa2\x17\x13\x81\x54\xb5\x80\xd0\x51\x32\x63\x84\x3d\x04\xb7\xd8\x51\xed\xa3\x19\x9d\x64\x2a\x0f\x6f\xbf\x93\x5f\x69\xf1\xed\xf7\xc9\xb3\xe8\x1b\x77\x50\xd7\x56\x8c\x12\xc5\x8e\xf6\x8e\x05\x4c\x24\x77\xb9\xa7\x44\xba\x35\x93\xc5\x81\x7e\xc0\x7a\xe3\xf7\x45\xc3\x55\x36\x8b\x0a\x3e\x62\x8c\x58\x8d\xfb\x91\x42\x4c\x82\x5e\xa5\x10\x76\xf6\x2f\x26\x14\x57\x35\xf6\x38\xce\x73\x4e\x1e\x8a\x41\x94\x63\xa2\xb0\xab\xb2\xf1\xbd\xd0\xa8\x72\x81\x2a\x88\x57\xa0\xae\x36\x74\x92\x93\x08\xa0\x57\x09\xb4\xb0\x5f\xa6\xdf\xb4\x9c\xd5\x3a\x07\x9c\x06\xd4\xe3\xd9\xd8\xc1\x6c\xb2\xec\x71\xe6\xd5\xe7\xc7\x49\xdf\x78\x6c\x9c\x2c\xb3\xbc\x09\x1c\x1b\x55\xbb\xde\x29\xb5\x05\x63\xde\x99\xbb\x36\xa7\x74\x26\xbc\x2d\x8e\xe0\xf1\x6b\x80\x11\xcf\x24\xd7\xa1\x2f\x43\x16\x3c\xf6\x23\x18\x02\x47\x68\xb4\x85\x90\x84\xbe\x97\x16\x41\x68\x41\x51\x15\x79\x1a\x60\x65\xb1\x9e\xf7\x15\x62\x43\x4c\x60\x66\x76\x03\x63\x51\x07\x6d\x4d\x43\x30\x23\x1d\x39\x94\x11\x6e\x7d\x6c\x70\x0d\xea\xb7\x71\x54\xd3\x44\x51\xe3\xc1\x68\xd2\xba\xa7\x69\x2a\x1e\x03\x14\x53\x63\x84\x91\x74\xa0\x2f\xe4\xfd\xbc\xc2\x4d\x96\x9e\x93\x49\x14\x65\x5f\xde\x7e\x42\xa1\x18\x4b\xeb\xb9\xc3\xa4\x2e\xe7\xd9\xf7\xda\x2f\xaa\xdd\xad\x8d\xad\x9e\xdc\xcb\xc0\xd8\x28\xe6\x12\xa6\x59\xc5\x3a\x4d\xe5\xff\x86\x7c\x85\x8e\xcd\xdc\x90\x5f\x49\x45\xc8\xfb\xa6\xbc\xf2\x96\x31\x76\x30\xab\xe5\xc4\xec\xcb\x3c\x7f\xd2\xde\xa0\xfc\x1d\x43\x57\x7e\xf9\x3f\x2c\xb0\x92\xc5\x5f\x4a\xe2\x0a\x7c\x1a\xe0\x07\x98\x17\x8c\xe4\x55\x02\x92\x04\x46\x43\xd7\xef\x49\x3d\xc7\xf5\x00\xdd\x81\xda\x9d\xf9\xb8\x3d\xc5\xd3\xa2\x6e\x30\x26\xb1\x99\x6f\xbd\x57\x01\xdc\x0a\xc4\x31\x47\x35\xa8\x1c\x93\xb5\x28\xa8\x31\x51\xfa\x31\xe4\x7e\x25\x8a\x3b\xcf\xf5\xf3\x3b\x2e\x62\xff\xc4\xdd\x41\xa1\xe0\x1e\x42\xa0\x06\xca\x92\xbe\x40\xb4\x33\xfb\x42\x1e\x57\x73\x7f\xc9\xa5\xfb\xe1\xe2\x01\x79\x62\xdf\xa9\xbd\x89\xd8\x3a\x1f\x0b\xa6\x9b\x35\x3f\xf7\x1d\x06\x15\x05\xf1\x0a\x4f\x9f\xe3\x01\xf4\xa3\x17\x94\x96\xf6\x3a\xd3\x0b\x0a\xf6\x62\x52\xff\x5b\xc6\x90\x74\x29\xaf\xd8\x8d\x60\x0f\x5f\x91\xc2\x50\xe6\x3a\x99\x1a\x79\x88\x0a\x71\xe4\xed\xb4\x36\x49\x20\x6d\x59\x4d\xec\x0d\xc3\x44\xa8\xd2\x7c\x87\x3d\x8a\x9f\x55\x44\x4d\x3c\xb7\x94\x5c\x94\xe2\x6b\xeb\x21\xc6\xaf\x31\xcb\x2f\x72\x42\xbf\xc7\x0e\x45\x7d\x1e\xa5\x01\x23\xaa\x65\x40\x41\xda\xca\x42\xf6\xec\x59\x95\xde\xbd\x16\x0f\xa7\x80\xc7\x7e\xa5\x3e\x37\x39\x78\x3e\x14\xf9\x74\x58\x40\x51\x25\x85\x9e\x43\xaf\xa6\xd0\x14\xc8\xa9\x46\x11\x55\xcb\xee\x28\xae\xbc\xc4\x27\x50\xf4\x2a\xa7\xf4\x89\xa4\x3b\x30\x77\x2a\x2e\xe9\x75\xd3\x9f\x84\x46\x8c\xb5\x99\xab\x0f\x2b\x4b\x95\x79\x7d\xe8\x0f\xe0\x1e\x41\xbe\x65\x54\xcf\xe4\xc7\xa2\xa4\xc5\x90\xcc\x00\x9f\x1b\x4f\xa1\xb7\x53\x7c\x0e\xf3\xc8\xaa\x3b\x2f\x03\x79\x4f\x5b\x0c\x69\x65\x46\xc2\x09\x43\xc7\xb2\x35\xfc\x2b\x6c\x4a\x1d\xdc\x2b\xeb\x9c\x0a\x74\x2c\x0d\xaa\x32\x6c\xbc\xcd\xb3\xe1\x9c\x06\x90\xd5\xae\x2e\x3e\x9c\xff\x9d\x44\xe2\xf9\xf0\x1f\x45\x02\x22\x7a\x9a\x57\x88\xc9\xa3\xf9\x8a\x2b\x14\x99\x5b\xcf\x4a\xbb\xae\xca\x29\x0d\x14\x93\x32\xab\x2b\x6e\x48\x91\xf2\x7a\xa0\x29\xae\xe9\xc7\x76\xab\x4a\x76\x2d\x79\x9c\xca\xf6\x8d\x73\x4c\x0b\x4e\xdc\x40\xd8\x1d\x58\x76\x4a\x1b\xfb\x03\x4b\x1a\x66\x15\x2e\xf6\xfd\x6a\x9c\x4f\x34\x1a\x85\x53\x1a\x71\x60\x19\xb5\x8d\xe8\x29\x0e\x6a\x4e\xb2\x98\xf0\x3d\xa4\x85\x35\xec\x71\xa5\x20\xbf\x07\x6a\x9a\xa8\xe2\xe8\xc2\x91\x05\x3c\x21\x76\x3a\xf0\x13\x96\x93\x6d\x59\x69\xeb\x0b\xd6\x7d\xbd\xda\x04\xc7\x41\x5e\xf3\xd8\x98\x2d\xbe\xe6\x71\xac\x6e\x08\xbc\x69\xde\x06\x7c\x1a\x41\x74\x41\x1b\xf2\xc5\x1e\x30\xaa\xf1\xec\x28\x9d\xb9\xc0\x8d\x47\xfd\xd2\xab\x0a\xa9\xd5\x6c\x12\x57\xa7\x04\x72\x00\x5b\xdc\x5b\x5e\xd8\xd3\x9f\x45\x47\xc2\x4a\x7e\x10\x23\xa6\x33\xb7\x93\xd3\xc0\x42\x8a\xb5\x1f\xf7\x4c\x5d\x74\x1d\x26\x6c\x0b\xf5\x33\x63\xf2\xd1\x51\x70\x5b\xd8\xb3\x44\x43\x3d\x19\xab\x40\x98\x77\xd1\xa5\x01\x5d\x53\x5a\x15\xe4\x30\x3a\xdc\x53\xa7\x68\xbd\xe2\x13\x6d\xa1\x7a\x21\x39\x4f\x0a\xac\xb7\xdf\x93\xe0\x88\x7e\x76\x62\x1a\x70\xfb\xbf\xdf\x6e\x5f\x9f\x3e\x3e\x9c\x37\xef\x10\x04\xbb\x4a\x18\x69\x4b\xd8\xb9\x06\xe2\x6a\xe0\x62\x6a\x68\x16\x71\x8f\x20\xd1\x49\x1e\x6d\xa1\xf7\xb9\x47\xb7\x85\x91\xf4\x9c\xb4\xe7\xa9\x11\x8b\x72\x3e\x8f\x13\x4a\xe4\x00\x46\x54\x3f\x17\xaa\x21\xdc\x6b\x77\x25\x7a\x3e\x44\x07\xae\xcf\xb3\x46\x11\xd6\x3b\xc0\xec\x54\x37\x1f\x40\xf9\xb9\x1b\x39\xe0\xac\x80\x0b\x12\x74\xb1\x0f\xdc\x82\x77\x2d\x7a\x6c\xec\x68\x5d\x7d\xb4\x0b\x7c\xf0\x85\x25\xad\x6c\x9f\x67\xf0\x6e\xc0\xd0\x0e\xa6\x7f\x8f\xd4\x75\x45\xe3\x1d\x0b\xb4\xa6\x63\x9c\x86\xf2\x20\xb1\xf3\xac\x4c\xfb\xf9\x10\xec\xe0\xfb\xc2\xe9\x14\x0e\x8a\x61\x6e\xb3\x77\x71\x2a\xac\x57\x63\x15\x6e\xb3\x60\x74\x3d\xc2\x6a\x53\x2f\xb9\x48\xb4\x7c\x5b\x5c\x94\xca\x71\x83\xad\x60\x72\x1e\x9a\x85\xba\xba\x96\x43\x12\x68\x0c\xfc\x2a\x65\x8d\xae\x67\xd6\xc9\x36\xd3\xec\x02\xa6\x6a\x80\xef\x20\x6e\x40\xe1\x35\x4c\x10\x34\xe4\x29\xd1\x4f\x14\xa7\xa3\x45\xb1\x3e\xfa\x96\x07\xf6\xd4\xaa\x1e\x89\xe4\x29\x39\xf0\x2a\xaa\x6b\x3e\x18\x51\xbd\xc1\x16\xba\x02\x70\x2a\xfe\x86\xba\x0e\x83\x2b\x34\x67\x8d\xbf\xc7\x40\xc1\xe7\x94\x2a\xd2\x22\xaa\xb3\xbf\x47\xc1\xa4\x33\xa8\xf4\x3b\x6c\x52\x34\xd9\x73\x3c\xb3\xab\x95\xc2\x7d\x41\xf0\xa6\x4e\x0f\x08\x7b\x3c\xa9\x72\x41\xe6\x30\x3b\x0c\x38\x12\x1a\x1e\x44\x0a\x4a\xdc\x3b\x63\xad\x38\xbb\x24\xb0\xe6\x26\x4f\x20\x2d\xc5\x68\x7c\xbc\x40\x46\x74\x23\x76\xd4\x9a\xd7\x7c\xbe\xbe\xd1\xe0\x52\x20\xb0\x72\xf0\x17\xa8\xa1\xb0\xbb\x78\x61\x16\x87\xdf\x32\x4d\xe3\xaf\x08\xdf\x56\xbe\xbd\x69\x21\x74\xcb\x72\x37\xbc\x4d\x03\x82\x24\x5d\xce\x26\x09\xb5\xc9\x09\xe7\x44\x41\x97\xbb\xc9\x45\xe3\x13\x25\xaa\xef\xe7\x38\x51\xab\x9d\x13\x97\xc2\x71\xaa\x54\x36\xc7\x64\xca\xf1\x67\xf6\x01\x05\x1a\x8f\x66\x79\x45\xde\xc1\x26\x79\x47\xd8\x5d\x1e\x4a\xfc\xac\x3d\xf2\x9d\x9f\x5d\x87\x71\xa2\x88\xdd\x4a\x1b\xc2\xd4\x7e\xed\x19\xfc\x99\x2e\xb8\xa6\x50\x42\x71\xc5\x87\x69\x2e\xa2\xc5\x69\xa1\xad\x7f\x8d\x05\x7f\xd5\x3c\x89\x30\x78\x05\xe7\x30\x56\x85\x81\xf1\xa7\x91\xee\x8a\x5a\xb0\x3a\x00\xcf\x0a\x02\xbf\x8e\xf2\x39\x6c\x61\x54\x7c\x08\x5b\xf2\x85\xb1\xa0\xbb\xfb\x78\xfd\xf6\xf9\xf9\xa9\xe8\x46\x39\x94\xff\xb0\x40\x05\x80\x72\x6a\x7f\xa5\x58\x0f\xbc\x37\x25\x2a\xaa\x37\x2f\x16\xab\xbe\x02\x3a\xe7\xb9\x05\xb3\x0c\xf7\x17\xcb\x7a\xc5\xc8\x7e\x8f\xae\xa3\x38\xe5\xf4\xd3\x02\x5e\x71\x8f\xe0\x1d\xb8\xa8\x66\x5c\x9f\x84\xfe\xa7\xd7\x36\x28\x7b\x74\xe0\x3a\x2c\x88\x74\x72\x29\xfa\x18\xf7\xca\x72\x7f\x79\x9d\x3a\x64\xcf\xfd\x7c\x7c\xe0\xb1\x06\x3b\xd6\x2d\x30\x12\xaa\xb5\xbd\x63\xe1\xcd\x6b\x72\x4d\x71\x6b\x61\xfe\x99\xe0\x0b\xa8\xb0\xe1\xa4\x01\x82\x35\x45\x4a\xc0\xd1\x9d\xe5\x2f\x3a\xcb\x30\xf5\xd6\xba\x1e\xa0\xb8\x90\x1e\xbb\xb3\x3c\x45\x87\xa3\x8d\x76\x2d\x34\x4d\xf5\xd5\x2c\x11\x0d\x42\xb6\x02\xb9\xab\xed\x91\x53\x6d\x4d\x52\x62\xd0\xd5\x40\x37\x14\x5b\xc1\x8e\xea\x0b\x14\x47\x8a\x71\x69\xf3\xc1\x66\xd0\x20\xb9\x33\xed\x2a\xc1\x70\x75\x4c\x3d\xa7\x84\x2b\x3a\x77\x27\x60\xa0\x70\x0f\xb9\x9a\xca\x7d\x1e\xc9\x13\x58\xa7\x00\xd0\xbe\xc4\x46\x36\xc2\x92\x97\xe8\xcc\x4f\xc4\xb4\x0e\xaa\x9a\xc6\xe0\x25\x27\xf2\xf5\xf3\xe7\xbd\x26\x85\x76\xda\xa9\xe9\x08\x6d\x66\x89\x59\x5b\xaf\xf8\x4f\xd4\x73\x5d\x69\xd0\xe4\xa1\xb5\x1f\x97\x31\x37\x46\x7c\x36\xf6\x4d\xc1\x03\xac\xc2\x78\x13\x08\xb1\x42\xdb\x99\x3c\x23\x71\x38\x4f\x37\x4c\x82\x03\xaa\x97\xf8\x18\x23\xc4\x48\x01\xd2\x59\x12\xea\x28\xc2\xca\x1d\x2c\x9b\x14\xf6\x74\xc6\x0f\x6e\x70\x0b\x16\xb1\x9a\xc0\xb4\xe5\xc9\x78\xbc\x46\x53\x3c\x9b\x2c\x4c\x4a\x45\x18\xb1\x65\x49\x6b\x8a\xb1\x98\xac\xd1\x0b\x16\x73\x1c\x95\x65\xa9\x50\xce\x3c\x7f\xed\x15\x4d\x38\x43\x80\xd3\x28\x27\x5a\x60\xbd\x3d\xc6\x44\xb5\x67\x52\xab\xce\xbe\x3c\x71\x17\x2f\x1e\xfe\x02\xab\x6b\x46\x42\xc5\xa2\x42\xd0\x56\x12\x42\x05\x84\x57\x6e\x94\x16\x52\x58\x27\x2a\x1a\x4e\x95\x25\x9a\xef\x5d\x12\x12\x7a\x9e\x6f\xb0\x43\xf7\x6c\x67\xf3\x56\x16\x28\xf4\xa3\xbc\xf1\x36\x08\x82\x6a\xe2\x49\x66\x98\x86\xe2\xb3\x7f\xce\x1c\xce\x3f\x8b\xc8\xe7\x1a\xee\x5f\x09\x35\x06\x50\x57\xd9\xfb\xd9\x9c\xc0\x31\xcd\xdb\xae\xa0\x43\x99\xa0\x4a\x73\x1c\x51\x74\x5f\xd7\xc2\xc1\xbc\xe3\x0d\x36\x76\x4e\x37\xd8\xa2\xca\xeb\x06\xbb\x6c\xde\xff\x24\x32\xcf\xdf\x72\xf5\xae\xb7\x71\x22\x0e\xb6\xe9\x3b\x88\xe9\x32\x81\xdf\xd9\xec\x77\x0b\xf7\x2c\x74\xdd\xbd\x1b\xeb\xb8\xcf\x23\xe7\x75\xf2\xf7\x28\x1d\x23\x18\x0f\xd8\x83\x77\x23\x04\xcc\x7b\xd4\xaf\x1f\x21\xd0\x94\xfd\xf2\xc2\x23\xc5\x8e\xe4\xc8\x74\x1f\x2b\x8b\x7b\x82\xbe\x3f\xc3\xf0\x27\xec\x39\xd1\xf2\xd5\x0b\x4a\xf1\xe7\x75\xd1\xc7\x2c\x85\xe0\x04\xb2\xbc\xf3\xb7\x4c\xed\xce\xbd\x93\x61\x71\x44\x90\xf6\x3c\x16\xb0\xdd\xac\xa4\xfc\x86\x30\x56\x36\xf5\x36\xe0\x36\x1d\x85\x19\x95\xc4\xb3\xe5\x3e\x56\x34\x7e\x9a\xb0\xf0\x86\xf6\x1c\x5a\xbf\x65\xf2\xc6\x2d\x3e\xa6\xc1\x57\xee\x53\x62\x32\xf4\x97\xd7\xc3\x11\x5f\xeb\x4e\xaf\x04\x0e\xc1\x1a\x39\x9d\x85\x2b\x45\xf2\x01\xdb\x5d\x85\x5d\x8a\x58\x61\x95\x7d\xb2\xc0\xe9\x9a\x65\xca\xde\x5c\xed\xb5\x40\xaf\x2e\xa2\x58\xac\xda\xc2\x09\x09\x73\x89\x07\xf5\xdb\x4f\x05\x0b\x6b\x6c\x5c\x09\xfb\x27\xa1\x1f\x3f\x7c\x45\xca\xbe\x5f\xb2\xfc\xa1\x8b\x3c\xae\x06\xb9\x2f\x5e\xc8\x28\x19\x84\x9d\x1e\x77\xee\x74\x42\x8d\xe9\x0d\xd3\xe2\x6c\x29\x58\xdd\xd2\x2a\x0d\x11\xf0\xa0\xbf\x78\xac\xa9\xc3\x8d\xcf\xa3\x7d\xb4\x61\xaf\x66\xb9\xf9\x96\x41\xf0\xf2\x0b\x1c\x2a\x75\x82\x94\x31\x96\x68\xfc\x44\x8c\x8a\xaf\x36\x65\x7c\xb3\x74\xe3\x3b\x42\x89\xc1\x16\xe6\xe3\x59\xa7\x79\x27\xb5\x9c\x77\xa1\xb0\xf3\x67\xe0\x39\x0d\x73\xa4\x16\xfc\xd7\x0e\x13\xd0\x39\x15\x6a\xa9\x73\xb1\x05\x55\x8a\x2b\x48\xc9\xe3\xb1\x47\x92\x86\x11\x54\x31\xae\x34\xe3\xd8\xb9\x01\xc8\xec\x14\x42\xe7\x8e\xbf\xf1\x0e\x83\x0b\xbc\x0e\x8d\xae\x84\xc3\x0f\x74\x71\x47\x21\x2c\xae\x34\xb8\x65\xe4\x1c\x87\xd9\xe1\x8c\x8d\xf0\x21\x9a\xcb\xf4\xf3\x32\xf8\x0d\xc8\x6e\xf5\xe1\x8d\x20\x74\x9e\xdb\x5d\x5c\xc3\x2d\x27\x6a\x1d\xb4\x6d\x25\x5c\x9e\xd5\x70\x8e\x3b\xb9\x13\x6c\x77\x96\x8a\xfa\xc4\xbe\x73\x89\x2d\x03\x70\xcf\x20\x11\xdd\x9e\x8d\x4a\x29\x35\x6f\xf0\x2c\x65\xfc\xc0\xa1\x5f\x96\xf2\x08\x29\x9d\x76\xfd\x58\x7c\x50\xe8\x1d\xc2\xba\x97\x10\xad\xa6\x93\x63\x82\x76\x40\x73\x98\x89\x43\x3b\xf0\x3a\xad\xf0\x44\x01\xdd\x96\x42\x6f\x80\xf0\x5c\xbc\xf9\x32\xf2\x73\xc0\x4b\x9c\xcd\x91\x82\x5f\x1f\xdb\x0b\xa1\xb4\x14\xfa\xa8\x1a\x97\x32\xf8\xba\xc7\x15\x5e\x17\x05\xd0\x4f\x34\xc5\x02\xfb\x32\x2e\x82\xf9\xd5\xd0\xe4\x1a\x17\xbe\x41\xe8\x57\x53\x5a\xb2\x3f\x6a\x46\x79\xda\x05\x4e\x2b\x7d\xd1\x7c\x49\xd1\xb8\x95\x9e\x84\x44\x96\x23\x32\x25\xb9\x4c\x2c\x96\x5f\xe9\x8a\x05\x56\xba\xe4\x99\xbb\xcb\x98\x80\x2a\x29\x42\xc1\x91\x03\x69\x22\xef\x06\xce\x48\x41\x89\xaf\x2a\xc0\xdf\xaa\x18\x45\x01\xe3\xd6\x63\x0f\x2a\xd3\xdb\xb1\x11\xa6\xae\xaa\xb9\x49\xdc\xe0\x79\x28\x58\xdd\xac\x2b\x06\x77\x1e\xc6\x86\x67\xa8\xe1\xda\xd9\x22\xee\x58\x46\x5d\xc0\x9d\x80\x1d\xf1\x9d\xe4\x51\xf3\xba\x9f\x40\xce\xa0\xe7\x93\x90\x3a\xa7\x7b\xc8\x09\x5d\xcb\x39\x65\x4d\xf0\x3d\x40\x6b\x41\x76\xe1\x04\xb3\x0a\x78\x3d\xc3\x73\x81\xe4\x04\xe9\x3c\x9e\x29\x3e\x32\xd2\x8f\x2a\xd4\xd4\x0e\x4b\x2b\x61\x95\xc8\x4b\x09\x9a\x8d\xac\xbd\x08\xb4\xa9\x98\xa8\x65\x69\x94\x49\xae\x80\xa4\x2f\x46\x5b\x48\x93\x12\xd0\x22\xbc\x98\xb0\x26\x6a\xfe\x28\xd8\xb2\x4c\xf4\x4e\x01\x57\x2b\x7b\x67\x09\x8e\xf3\x5a\xb6\x95\x80\xfc\x1a\x1f\xff\x8f\x80\xff\x7b\x08\x78\x84\x10\x0a\xbf\x1f\xcf\xa5\x8b\x6d\xc7\x49\x01\xf1\xaa\xf8\x76\xcd\x58\x5e\x0f\x79\x41\xc9\x6b\xbf\xb8\xb3\x6b\x99\x27\x93\xc4\x0d\xe2\x54\xa1\xf2\x24\x55\x81\x83\x46\x6b\x21\x87\xb6\xc4\x14\xd1\xe0\xf7\x80\x32\xbb\x38\x21\x6a\x3e\x4d\x33\x9e\xde\xcf\x27\xa0\xa5\x7e\xf0\xb3\xdb\x2e\xa2\xba\x9f\xa7\xa0\xf2\x5e\x51\xa8\x42\x77\xf3\x94\xcc\xd7\xb6\x1c\x74\x0d\x0f\x90\xfb\x41\x1f\x15\x58\x9e\x20\x47\xcb\x7f\xa0\xe7\xae\x26\x13\x1e\x39\x70\xe2\x80\xeb\x32\xfa\xd8\xd8\xb6\x9e\x40\xa4\x2e\xf2\x59\x73\xfd\xae\x85\x98\x75\x09\x7f\xcb\x40\x21\xb9\xa8\x4a\xaa\xf0\x0a\xcb\x57\xaf\x25\x4a\x1c\xdd\x16\xda\xb4\x92\xf7\x2b\x4c\xd4\x5d\x6e\x49\x35\xe6\x75\x98\x6b\x22\xf2\x95\x9b\xaa\xb9\x1b\xc5\xe1\xe5\x0c\x36\xda\xa0\xad\x51\xd2\xcd\xb7\x8c\xb0\x5b\xb3\x03\xab\xbf\x46\x0f\x96\x06\x4b\x5a\xaa\x53\x3c\x06\xbf\x8b\x2e\xb1\x8b\xe8\xb7\x16\x10\x91\x8f\x8e\xb7\xa5\xf3\x67\x39\x67\xcf\x1a\xa4\xbc\x0f\x14\x8b\x39\xaf\x84\x6f\x61\xf8\xaf\x79\xaf\x1a\xe6\x26\xda\x52\x6b\xd6\xba\x44\x4c\x56\xac\xdd\x95\x93\x57\x6b\x1f\xd8\x5b\x6d\xa6\x56\xdd\xe3\xb4\x66\xdd\xc7\xca\xfb\x0d\x8e\xd4\x6b\xbd\xe1\x76\x4f\xde\x15\xe6\x67\x6c\xd2\x6a\xb9\x1f\x4e\xc5\xf6\xa5\x44\x7b\x32\xc2\x81\x75\x88\x7b\x88\x0e\x5c\x3b\x90\xe6\xa6\x57\xf9\x32\xea\x07\xd7\x18\xfa\x58\x1e\xd5\x02\xf9\x12\x05\x79\x9f\xe3\x19\x8b\xff\x1c\x62\x96\x4a\xa4\x6d\x65\x0f\x7c\x58\xbe\x7e\x04\x11\xb2\x10\x96\x42\x77\xa9\x79\x45\xae\x19\xa3\x55\xba\xe1\xbf\x2a\xfa\x3e\x71\xb8\x1c\xb2\x25\x46\x57\xaf\xbf\xb0\x9f\x7b\xa8\xf7\x1f\x6a\x9c\x15\x9d\xa0\xe5\x13\x4f\x79\x31\xd7\x14\x02\x75\x4a\x71\x4e\xec\xcf\x4c\x69\x83\x42\xe0\xdd\x8e\xea\x35\x84\x75\x71\x5e\xd1\xeb\x8d\x46\x74\x49\x4d\x69\xa9\xf1\x1e\x23\x63\xcb\x7c\xb6\x42\x23\x05\xf0\x2b\x0d\x10\x9c\xb2\x42\xd5\x2a\x56\x2e\x6a\x30\x36\xc7\xec\xdb\x92\x76\x87\x9a\xca\xbb\x62\xb6\xcb\x1a\xca\x97\xb5\x78\x75\xca\x1e\x6b\xa4\x45\xe9\x1c\x8e\xaf\x07\xd4\x9a\xc3\x8d\x16\xb9\x6d\xd4\xdb\x72\x78\x0a\x4c\x9a\x11\xe5\x18\x69\x5a\xaa\x1c\x2c\x35\x9a\xba\xe7\x75\xd9\xf6\x9e\x83\xdd\x68\xb9\x9f\x27\x6e\x07\x0e\x9d\x10\x94\x43\xfc\xdc\x91\x96\x73\x3f\x87\xad\xd7\x9a\x9f\xaa\xec\x03\xcc\xd0\x58\xc9\xfc\xc1\x52\x41\x27\x8b\xa7\x08\x21\x0d\xc2\x5a\x66\x7b\xa4\x58\x0b\x25\xd4\x0f\x0d\x5b\xb1\xe2\x29\xa7\x7f\x6a\xb8\xfb\xdc\x04\xfe\x5e\x8f\xa2\x80\x42\x09\x0d\xcf\x5d\xd7\x31\x17\x7a\xf1\x52\xdf\x7b\x29\x23\x4b\x6d\x0c\x98\x1c\x6f\x5d\xc7\x9a\xd0\x7b\xc5\x29\xfb\x68\x27\xf9\x8a\x4b\x1e\xe3\x84\x1a\xb4\xdd\x0a\xa8\xed\x9e\xa7\x4c\x7d\x91\x6e\x03\x5a\xbe\x2b\x81\x34\x6d\xab\xb7\x7c\x47\x92\x8e\x15\xeb\xe3\x3a\xee\x1a\xb8\x69\x7e\xf2\xd9\xd2\x0e\x70\x4c\x92\x7d\x94\xe4\xea\x05\x98\x1a\x38\x43\xe7\xb6\xb4\xae\xa6\x50\x2f\x30\x19\xf4\x97\x68\xb6\xd7\x0a\x5a\xbd\x25\xa5\x21\xe0\x2a\xb7\xb5\x0c\xe4\x5a\x8b\x04\xaf\x33\x45\x8b\xef\x94\xa0\x7b\x56\x1c\xbc\xe1\xde\x35\x82\xd8\x55\x4f\xbf\xf8\x74\x4d\x71\x7e\x2f\xdc\x75\x1d\x15\xdc\x81\x6f\x39\xe8\x8f\xd5\xcd\xd7\xab\x1d\x35\xd6\x66\x41\xea\x83\x6b\xb3\x2f\x8e\x39\x9a\x07\xef\x30\x54\xe5\xa1\x98\x58\xce\xf4\x47\x22\x0a\xb4\xf5\xe7\x1c\xea\xc6\x3f\x87\x98\x24\xd7\x64\xec\xef\x81\x52\x7d\xfe\x00\x87\x70\xdc\xb4\xde\xbb\x29\xea\x6a\xc1\xd5\xc9\xad\x4f\xa8\x95\x49\xbd\x78\x65\xdf\xbd\x30\x26\x4b\x9b\xe6\x12\x33\x5e\x46\xf6\xfb\x0a\xfe\xb5\x5e\xa2\xd2\xa5\xf3\xb2\x93\x5d\xc6\x32\x82\xb1\xd9\x61\x6a\xeb\x2e\x37\x23\x57\x6b\x78\x2b\x66\x64\x97\x36\x10\xea\x88\x05\xd4\x77\x38\x9f\x59\xb4\xa5\x0d\xa2\x96\x29\xd7\xc8\xbe\xaf\x7a\xfe\xd3\xa5\xab\x5c\xe4\x14\xa3\x9b\x40\x52\x38\x7f\x24\xb5\xaa\x7e\x95\xe7\x5a\xa5\x9e\xce\xaa\x4e\xd7\x9e\x6a\x5c\xcd\x61\x4b\x9d\xf1\xad\x1b\x6c\xea\x95\x2a\x8a\x2d\x4d\x56\xd3\xcc\x20\x9d\xdd\x12\xb8\x5f\xca\x47\x27\x50\xee\xd8\x9b\xf5\x16\x7f\xaf\x63\x58\xea\x59\x3d\x77\xb0\xc1\x9e\x70\xc4\xa8\xb7\x13\x9e\xb7\xdb\x38\x9d\x0b\xe1\x05\xc4\xd6\xf1\x02\x49\x2c\xf7\xc1\x85\xb2\xb6\xe0\x8f\x7b\x78\x91\xe3\x65\xa8\x82\xc2\xff\xfe\x57\xff\xef\x7f\x99\x5f\x97\xb5\x92\xbc\x52\x3f\x24\x37\x58\x35\xe9\x95\xcb\x7a\xa8\x3d\x0e\xb2\x41\xd9\xdb\x0a\x37\xd4\x2c\x92\xe4\xe2\x23\x4f\xaf\x58\x51\x6b\xe5\xb9\xc1\xef\xea\x35\x1d\xaa\x97\xed\xf2\x34\x79\x6a\xeb\x40\xda\xb1\x17\x0e\x25\x38\x44\x4b\x3c\xfe\x11\x04\xbf\x65\x2a\x01\xa5\xd5\x91\x8e\x12\xee\x68\x4f\x01\xbf\x76\x3c\x02\x9d\xc3\xf6\xca\xed\x5c\x81\xaf\x15\x8a\x2b\x4c\x02\xb3\xae\xed\x7a\xa8\xcf\xae\x07\xd0\x60\xee\x9a\xc3\xb7\x8c\xa7\x34\x6e\x91\xe9\xdc\xfa\x9a\x16\x03\xf5\x47\x37\x18\x13\x85\x5a\xb2\x86\x31\x9e\xbb\xb7\x4f\x90\xf0\x00\x73\x5c\x8d\xf0\x25\x77\x3d\x56\x73\x5a\x4a\x09\x38\x5a\x1d\xa3\x3a\x4f\xb3\xa8\x9a\xcc\x4a\x03\xca\xc0\xdc\xad\x86\x58\x4d\xf0\x0c\x49\x19\xdd\xb3\x58\x52\xe4\xc5\x43\xaf\x81\xc7\x4b\x96\xc2\x4f\x96\x4c\xd6\x2b\xea\x2d\xc9\xd3\x18\x9b\x76\x40\xb3\xdd\x4d\xa5\x39\x5a\x82\x96\xd1\x4a\x4a\xe3\x58\x85\x12\xcc\xb4\xdc\x1d\xcb\xa9\xd8\xe9\xfe\xae\xcf\x36\x7a\x4d\xa3\xb4\xde\x8d\x77\x14\x27\xbb\x90\x6c\xbd\xed\x78\xaa\x26\x28\xdb\x3e\xbf\x15\x02\xdb\x84\xf2\x35\x0d\xf8\xb5\x18\xd7\x7c\x56\x5a\x88\x59\x3a\xd7\x30\x44\x5d\xd8\xc7\x8e\xa7\x22\xea\x13\xc3\xf9\x78\x28\x58\xd6\xb9\x11\x3b\xb3\x41\xce\x45\x33\xd3\x80\xce\xae\xe2\x9c\x0a\x07\x19\x4b\x98\x3f\x60\x97\xcf\xe2\x84\x5b\xaf\xce\xa5\x70\x43\xde\x6e\x8d\x59\x7f\xa2\x3d\x06\x07\xce\xa4\x5e\x1c\x6f\x72\xe3\x91\xf7\x7c\x2e\x3f\xb5\xcb\x85\x86\xcf\xb5\x82\xa9\x2d\xab\xc2\x9e\xe7\x55\x3e\x87\x96\xc3\x1e\x43\x01\x01\x37\xa1\xb9\xe0\x98\xbd\x6d\x24\xd4\x2b\xa9\xc7\x47\xab\xea\x14\x97\x80\xa4\xcc\x95\xbd\xf9\x67\xad\xaf\xf1\xd6\xa5\x01\xc2\xce\x08\xfc\xba\xb8\x50\x7a\x0e\x52\x41\xe3\xc5\xec\xf4\xd1\x89\xbe\x28\x44\x1c\x1c\x75\xc5\xff\x2b\x13\x29\xdd\xa4\x69\x8b\xf3\xda\xc3\x2b\xb6\xa2\x76\xb5\x32\xfa\xa5\xce\xf0\xca\xbc\x75\x1c\x5c\xa5\xed\x9b\x01\x42\x3f\x00\x9d\xd5\x20\xa8\x2f\x6b\xb7\xaa\x73\x6b\xd7\x65\x47\xe4\x80\xae\xa3\xb3\x28\x6d\xd2\x6a\xa3\x8b\x2b\xe5\xd3\x92\xe7\x69\xdb\x9b\x03\x85\xce\xf8\xe5\xdb\x20\x7c\x08\x8e\x82\xfb\xa7\x65\xb9\xff\x08\x92\xfd\xec\x46\xe5\x20\xef\x52\xc2\x19\xcd\xb3\xa0\xf2\xf7\x7f\xfc\xf6\xff\x7e\xfb\xff\x01\x00\x00\xff\xff\x35\xd8\xc3\x1e\x3b\x2d\x00\x00") + +func npcJsonBytes() ([]byte, error) { + return bindataRead( + _npcJson, + "npc.json", + ) +} + +func npcJson() (*asset, error) { + bytes, err := npcJsonBytes() + if err != nil { + return nil, err + } + + info := bindataFileInfo{name: "npc.json", size: 11579, mode: os.FileMode(420), modTime: time.Unix(1594526741, 0)} + a := &asset{bytes: bytes, info: info} + return a, nil +} + +var _treasureJson = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x94\x58\x4d\x6f\x1b\xb9\xb2\xdd\xe7\x57\x10\x5a\x3c\x6f\x6c\xcc\xfe\xed\x6c\xf9\x23\xc9\x58\x89\x9e\x65\x8c\x1f\x30\x18\x04\xd5\xec\x52\x77\x8d\xd8\xac\x4e\x91\x94\xac\x3c\xbc\xff\x7e\x51\xc5\x96\xd5\xce\x04\x17\xb8\x2b\x93\x2d\x7e\xd6\x39\x75\xea\xd0\xff\xf7\xc1\xb9\xc5\x40\xc9\x7f\xa3\x8c\x43\x5a\xfc\xb7\xfb\xf3\x83\x73\xce\xfd\xb9\xb8\xe1\x43\x58\x5c\x2e\x6e\x04\x52\x72\x0d\x86\xda\x61\xf6\xfd\xe2\x72\xb1\x04\xd9\x63\xeb\xb6\xd4\x15\xa1\x88\xfa\xa5\x8c\x8b\xcb\xc5\x2d\xfa\x9d\xe3\xad\xf3\x20\x6d\x5a\xfc\x75\x39\xad\x75\x2b\x70\xa0\xd8\x2d\x2e\x17\xf7\x2c\x48\x5d\x74\x9e\x29\x2e\x2e\x17\x0f\x30\xa0\x1b\x09\xbd\x2e\xf1\x10\x74\x2b\x3c\x9e\xdb\x7f\x83\x2c\x2e\x17\x1f\x81\xc4\x79\x1e\x9a\xf3\x82\x1f\x21\xb6\x3b\x14\xdf\x13\x6e\x75\x04\xc5\x0e\x5b\xd7\xf0\xab\x76\xb8\x48\xa7\xd3\xb5\x5d\x06\x88\x2e\x33\xe7\xde\x7a\x31\x53\xec\x5c\xcf\xa2\x9b\x3f\x32\xb4\xd8\xba\x96\x3c\x9e\x57\x7e\xe4\xd8\xb9\x2d\xcb\x6e\x71\xb9\xf8\x52\x86\x06\x05\x5b\xb7\xc3\xe3\xe2\x72\xf1\x95\x82\x0b\x30\xe8\x3d\xbf\x86\xd6\xb5\x6c\x31\x59\x03\xc5\xec\x46\xce\xda\xc6\xe8\x29\x9c\x17\x5b\x17\x49\x7a\x9b\xff\x29\x14\x82\x1b\x51\x77\xdd\x40\xd8\xeb\xb7\x8d\xa7\x94\x58\x92\x35\xa5\xae\xb5\x41\x08\xd8\xba\x80\x39\xa3\x9c\x97\xd9\xa0\x46\xcf\x45\xc4\x36\xd8\xd4\x1e\xf6\xfa\x41\xe0\x07\x6b\x80\x36\x14\xf6\x28\xae\x29\x39\xb3\x6d\xb1\x2b\xb6\xdc\x33\x37\xe0\x3d\xbb\x91\x46\x9d\xf6\x42\x11\x5d\xc3\x39\x07\x5c\xfc\xf5\xc1\x39\x5b\x7f\x71\x60\x89\xff\x04\x1f\x83\xde\xe7\x26\x70\xb1\x0b\xdc\x30\xe7\x54\xd9\xe0\x31\xa0\xfd\x26\x08\x29\x8f\x01\xb2\x0d\x10\xea\x20\xb6\xca\x85\xb7\x63\x2f\x29\xfa\x5c\xc4\xd8\x11\x18\x34\xa2\x4b\x06\x9d\x7b\x2b\x68\xf0\xdc\x81\x48\xe5\xc5\xdd\x11\x47\xc8\xbe\x3f\xcf\x7e\x80\x12\x73\x40\xdb\xf6\x21\xb0\xc5\xec\x81\x0f\xd1\x08\xa1\x8b\x7c\xc4\x30\xd8\x49\x3e\x72\x9a\x03\x88\x90\x7b\x14\x07\x32\x58\x70\x1e\xd9\xef\x6c\xd8\x0a\x28\xb8\x4d\x4f\x52\x3b\xc9\x10\x46\xbf\x0b\x60\xec\x5b\x43\xab\x6c\xa8\xd3\xce\x08\xea\xfd\xdc\x00\xa4\xf1\x7c\xaa\x67\x7d\xe2\xc6\x50\x80\xd8\x42\xa8\xf8\x81\x6c\x0d\x17\x5d\xfc\x0c\x5b\xcf\x68\x3f\xef\xea\x9e\x9b\x40\xe3\x88\x15\x71\xf6\x3b\xfd\xfb\x2c\x1a\x60\xfb\xf4\x07\x2a\x73\x3e\x18\x2a\x8b\x03\xc2\xc8\xff\x84\xe5\x5a\x06\xc5\x3d\x1d\x58\x5a\x0d\x3a\xf8\xdd\xb9\xad\xb8\xc2\x2b\x56\xd8\x0e\x13\xe6\xcb\x00\xc7\x81\x27\x0c\xca\x2c\x83\x96\xc2\x29\x35\x7c\xb0\xd4\xcd\x53\xba\xdc\x42\xd7\xa1\x06\xed\x3e\xd4\x1b\xdf\x07\xb0\xcc\x1a\xe0\x94\xa1\xb4\xc7\x79\x1a\x86\x06\x6d\xfb\x8f\x30\x0c\x58\x93\x35\xfb\x7e\x82\x45\x12\xd6\x1d\x4e\x89\xb7\x8b\xb4\xd5\x75\x1e\x21\xfe\x9c\x73\x75\xa0\xb6\x4e\x37\x5a\xd5\x3d\x57\x50\xf4\x24\x2b\x96\x48\xb1\x4b\xd9\x24\x61\x4d\xbb\xd9\xfc\x8d\xa7\x81\xea\x0f\x9b\x9e\x25\xd7\xb5\x36\xe4\x77\x35\x5d\x42\xc5\x6d\x33\x62\x1d\x93\x61\xbb\x9d\xcd\xce\xb0\xb3\x61\x99\x34\xf1\x58\x61\xe9\x85\x2d\xe5\x6a\x3c\x5f\x40\xfa\xd3\xfd\x5e\x40\x46\xf2\xca\x9d\x97\x9e\xc6\x59\x1e\x35\xcc\xbb\x6f\xa9\x34\x7f\xa3\xcf\xef\x30\x0b\xbe\xc7\x41\xf5\xe3\xda\x58\x70\x9d\xb2\x70\xe0\xee\x68\x40\x81\xdf\x4d\xe4\x5a\xf6\x20\x39\xb9\xff\x72\x03\x8c\xc9\x52\x25\xa6\x91\x04\x3c\xe1\x4c\x49\x97\xcc\x3b\xdd\x49\x07\x08\x0d\x14\x2b\x03\x6f\x69\x4f\x11\x32\x59\xfa\xdf\x65\xfa\x5e\x54\x42\x14\x40\x48\x7d\xfd\xfa\x80\x11\xc1\xf6\x9d\xc1\xd7\x11\x77\x02\x63\x7f\x34\x11\x4d\x99\x45\x5b\x9f\xb9\x48\x84\x50\x81\xea\x0a\x74\x15\xb3\x83\xee\xf4\x68\xda\x94\xe6\xe0\xa5\xec\x70\x18\x49\x8c\xec\xd6\x1d\x35\xa7\x6a\x6f\x8f\x6e\x64\x65\xb1\x42\x18\x53\xae\x64\x5f\x1d\x73\x7f\x0a\xc2\xd7\xb6\x75\xbe\xa4\xcc\xc3\x6c\xd5\xaf\x02\xd3\x61\xd6\xc2\x23\xa8\xb6\xc0\xd4\xe9\xd1\x42\xa2\x00\x63\x87\x5e\x60\x6b\xc9\xa5\xcc\xa9\xe0\x66\x74\x09\xbd\xa8\x74\x9c\x41\x56\x52\x69\xbd\xea\x73\x25\xc3\x73\x8f\xa7\x03\x3c\xab\x92\x95\x7a\xfc\x17\x10\xe7\x7b\xe1\x48\xde\xb8\xf3\xd2\xf3\x45\x72\x87\x9e\x4d\x3f\xb3\xef\xaf\xfa\xca\xe5\x19\xf2\x99\x39\xfc\x94\xaa\x8a\xbb\xa7\xd6\x6d\x43\xd5\x99\x1b\x04\x71\x59\x60\xb4\x76\x08\x6c\xb1\xbc\xe1\x90\xaf\x7c\xc9\x53\x50\x96\x3d\x58\x51\x5c\xf6\x94\xf0\xad\x8a\xd4\x5c\x3d\x34\x46\xdd\x5b\x66\x71\x02\x43\xd5\x4e\x97\xa5\x0c\xa3\x25\xdb\x3d\x09\x3a\xae\x39\x4b\xa9\xaf\x55\xce\x68\xf2\xc0\x5d\x17\xe6\x14\x7a\x10\x18\xc7\x30\x1f\xa1\xf7\x47\xcb\x5d\xbf\x4b\x70\x78\x9f\xce\xb1\x75\xad\x50\x98\xd8\x90\x51\xe2\x5c\x6b\x63\x9a\x24\xf6\xb7\x5a\x23\xb5\xa9\xf9\x61\x20\x43\x04\x1f\x2c\xac\x2b\xcc\x10\xdc\x96\x2c\xa6\x2b\x96\x0c\xf2\xdb\x88\xc9\x2a\xd1\x69\xb1\x2f\xa7\xf2\xb6\x26\xbf\xab\x89\xb7\xd6\x88\x4f\xc5\x78\x1d\xa8\x86\x69\xcd\x75\x54\x09\x01\x8f\xb3\x7b\x3d\xf1\xf8\x73\x5d\xed\x79\x8f\x56\x57\x47\xda\x55\xca\x64\xc4\xe0\x0e\x64\x82\xf8\x6c\x94\x39\xe3\x38\xb2\x26\xd0\x3c\x77\xef\xfe\xf7\xf9\xee\xe9\xcb\xf5\xa3\x61\xd5\x1e\x5d\x3a\x18\x82\x4b\x18\xb8\x6c\x43\xcd\x8b\x25\x47\x4d\x68\x07\x91\x86\x9a\x8c\xb3\x59\xcb\x22\xe8\x60\xbb\x0d\xe4\x2d\x39\xcf\x8e\x08\x33\xfa\xec\x70\x6f\x90\x4d\xbd\x8e\x43\x7b\xee\xf5\xd4\xb6\xe6\x18\x6e\x49\xd0\xa6\xbb\x84\xd1\x80\x9a\xed\xf0\xd6\x7c\x5b\xfa\xee\x35\x0b\x68\x1d\x33\xfd\x56\xc6\x2b\xc6\x3d\xa7\x7c\x95\x46\x44\xf3\x6f\x1f\x11\xb2\xdb\x53\x9a\x04\xe3\xbc\xdc\xa7\xb8\x2f\x21\xa2\x40\x33\x87\x66\x36\x60\x05\x1d\x79\x47\xc3\x50\x22\x65\x45\x7c\x45\x22\x2c\x8e\x86\x1a\x8e\x5f\x1d\xed\x97\xa7\x3c\xff\xf8\x45\xcf\xf8\xcb\xd3\x3c\xa1\x4a\x12\xba\x1e\x21\x98\x83\xdb\x8c\x88\xad\xe1\x28\x98\x7d\x3f\xd3\xb2\x4d\x19\x51\xae\xfe\x2e\x66\xcf\x6a\x27\x65\xc1\xd8\xd9\xbc\x67\x0c\xb8\xa3\x88\x89\xd2\x04\x7c\x99\xd2\x3d\xa3\x5c\x35\xa2\x9e\xa1\xea\x42\xfd\x72\x80\xb0\x7b\x9f\xe4\x83\xde\x1b\xc2\x37\x8a\x9d\x60\x4b\x18\xdf\x8b\x7c\xf4\xfa\xc9\x05\xfa\x5e\xcc\x75\xcc\x99\x13\x28\xb6\x93\xad\xbd\x61\x52\x83\xe7\xcd\xc0\xbc\x63\x97\x56\xef\xd6\x6d\xb9\x9b\x6b\xfd\x76\x4b\xd1\xc5\xa9\x3e\xb0\x8c\x09\x2f\x92\xeb\x81\xc4\xe4\x9f\x53\x12\x86\xd6\xb5\x25\x65\xe3\x5a\xc8\xa4\x5a\x1c\xb3\x00\xfd\xcc\xc4\xbb\x57\xce\xe4\x5d\x1a\xdf\xb9\xdd\xdf\x29\x04\x14\x5b\x34\x6a\x5c\x7f\xa7\xd8\x5d\xa4\x37\xc3\xfc\x08\x29\xbb\x1a\x1d\xed\x11\x88\xfd\xa8\xd1\xb3\x8c\x84\x98\x2d\xe7\x5b\xc5\x69\x6e\xfd\x56\x1c\x77\x17\xc9\xed\xad\x10\xcf\xa1\xc6\x43\xc3\x12\x2f\x92\xf3\x72\xb2\xd4\x23\x8b\x1e\x38\xff\x07\x8c\x59\x1f\x05\x1d\xaa\x39\x37\x73\x8d\x18\x5d\x83\x78\x6a\x5f\x24\xd7\x04\xe6\xb6\x3a\xb2\x51\xbb\x20\x26\x45\xb5\x3e\xc8\xd5\xa0\x72\x74\x5e\xf9\x59\x9f\x11\x17\xc9\x6d\xf5\x19\x21\x46\x90\xa1\x71\xdb\xc0\x07\xfc\x09\xcb\x17\x6c\x5b\x73\xde\x13\x59\xa8\xe5\x83\x86\x04\xc1\x04\xe7\x85\x7e\x80\xb4\x2e\x99\xff\x9e\x15\x88\xa9\xc0\xfc\xd3\xcf\x55\x6f\xe0\x04\x7d\xb5\x6b\xd7\x43\xa9\xee\xba\xba\x04\x68\xaa\x9d\x2b\x38\x0a\x45\xb3\xc2\x4b\x08\x81\xde\x6a\xf6\x12\x44\xf5\x7f\x46\x99\x61\xac\x56\xce\x64\x09\x7c\xae\x4c\x31\xdb\xbc\x94\x63\xca\x50\xf5\xc6\xb2\xe8\x6e\x68\x84\xa9\x45\x99\xe5\xd1\xbd\x3e\x12\x7c\x4f\x11\xac\x94\x44\x3c\x73\xfa\x53\x4c\x5a\x70\x30\xe6\x93\x0e\x40\x70\x93\x19\x59\x91\x17\x4e\xbe\x4a\xf0\xaa\x24\xf2\xf6\x1a\x9b\xd5\x73\xc1\x5a\xce\xf5\xb9\x54\xa3\xb7\x46\xd9\x96\xc1\x98\x24\x70\xd4\x07\x4c\x5d\x6b\x2d\x75\x88\xa2\x68\x4e\xeb\x09\x04\x5d\xc6\x57\x35\x68\x73\xbd\x3f\x42\x70\xc2\x4d\x55\x76\x5d\xf7\x22\x39\xc1\x40\xbe\xbe\xa9\x68\x48\xbd\x55\xb3\x0d\xbe\xe6\x4a\xd5\x4d\x8f\x98\xdd\xa0\xe7\x33\x03\xd1\x45\xcc\x15\xcc\xb3\x90\xd8\x63\xea\x00\x56\x22\x36\x9a\x2e\xb6\xfc\x78\x3c\xbd\x29\x9f\x41\x2b\x97\x5d\x46\x65\xe5\x74\xe9\x93\x8b\x50\xff\xf6\x2b\xec\x8d\xe3\xef\xc1\xcf\xfa\xb8\x54\xb0\xab\x7a\x18\xd4\x98\x92\x7d\xbb\x29\x61\x67\x08\x2b\xa2\x15\x46\x8e\xa9\x0c\xef\x85\x59\x73\xbe\x08\x04\xb7\x87\x50\xea\x33\x5c\xea\xfc\x5b\x50\x41\xb6\x16\xa5\xae\xd0\xf4\x55\xe0\x90\x1c\x46\x1c\xaa\x85\xfa\xb7\x59\x76\x37\xe8\xb3\x9f\x52\x5f\xc9\x12\x3d\xb7\xb5\x65\x52\x62\x8d\x2c\x70\x35\x06\x88\x66\x4e\xee\xb5\x2c\xce\x0a\xf2\x3d\x4b\x73\xaa\x61\xf7\x02\x5d\xad\xfe\x1f\x11\xf6\x7a\xb1\x4f\xc3\xc0\x7b\xbb\x8d\xb6\x47\xe5\x2a\xf9\x53\x3f\xaa\xa2\x48\xf1\x99\xde\x5d\xf7\x53\xcc\x7a\xa2\xee\x44\x41\xb5\x93\x87\x6a\x0f\x56\x14\xf4\x09\x70\x7c\x8b\xc4\x17\x8e\x57\xbd\x3e\xff\x55\x66\x0e\xd1\x4e\xbe\x06\xc9\x34\xcf\xfc\x35\x07\xca\xc6\xe3\xd3\xb4\x27\x0c\xd4\x11\x97\x34\xfb\x32\x02\x55\xa0\x8c\x72\xa6\x0f\xaf\x16\x80\x3f\xe8\xdd\x53\x5a\x67\xe8\x0d\xbe\x0d\x5a\x44\x48\xdd\xc0\x1c\x6e\x68\xec\xc0\x96\xe6\x55\xba\xae\xbf\x17\x18\x60\xfa\x0f\xca\xf5\x8f\x22\x54\x1f\xd3\x28\xc7\x70\x7a\x1e\xb8\x35\x82\xcc\x8e\x7c\xa3\xd2\x56\xe5\x56\xeb\x46\x44\xb7\x9c\xb2\x75\xd9\x43\xf0\xd8\x72\x34\xde\x50\x8c\x50\x4d\xe3\x92\xa5\x66\x3d\xc1\xc0\xb1\x9d\x61\xdd\xd8\x58\xb7\xb8\x1b\x50\x40\xbd\x87\xab\x46\xf2\xba\xab\xaf\xfa\x07\x90\x68\x72\xf4\x50\x9d\xc9\xa7\x3d\xcf\xb5\xe2\x33\xb4\x3a\xea\x33\xa4\xd1\xae\xf3\xd9\xc6\x3e\xc2\x48\xc9\x3d\xc2\x8f\x12\xc8\x50\x0a\xe0\xfb\x7a\xb1\x15\xeb\x13\xe0\x5d\xa5\xf8\x1a\x8f\xaf\x8a\xd0\x68\x47\xac\x77\xb5\xd2\x92\x29\x96\xc1\xec\x9e\x78\x0c\xd5\x19\x3f\x95\x66\x5e\xf2\x61\x1c\xfb\x6a\xe5\x36\x28\x23\xaa\x68\xe0\xdb\xbf\x43\x26\xad\x77\x9f\xc4\x5c\xc5\x33\x8f\xf0\x43\xff\x16\xf9\x5e\x98\xd2\x84\xdb\x87\xff\xff\xf0\xaf\x00\x00\x00\xff\xff\xe0\x20\x24\x45\x03\x13\x00\x00") + +func treasureJsonBytes() ([]byte, error) { + return bindataRead( + _treasureJson, + "treasure.json", + ) +} + +func treasureJson() (*asset, error) { + bytes, err := treasureJsonBytes() + if err != nil { + return nil, err + } + + info := bindataFileInfo{name: "treasure.json", size: 4867, mode: os.FileMode(420), modTime: time.Unix(1594526741, 0)} + a := &asset{bytes: bytes, info: info} + return a, nil +} + +var _wildJson = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x84\x58\x51\x8f\xe3\xb8\x0d\x7e\xdf\x5f\x21\xe4\x79\x0e\xb8\xbe\xf6\x6d\x92\x99\x4c\xf6\x3a\xd9\x9d\x4e\xa6\x9b\x02\x87\xc3\x82\x91\x69\x5b\x17\x59\xf4\x52\x52\xb2\x99\xa2\x40\xff\x46\xff\x5e\x7f\x49\x41\xca\x4e\x9c\xbd\x00\xf7\x64\xc5\x91\x29\x8a\x9f\xf8\xf1\xa3\xfe\xf5\xc1\x98\xd9\xd1\xf9\x0a\x39\x60\x8c\x5f\x19\x1b\x47\x21\xce\xfe\x6a\x7e\xfd\x60\x8c\x31\xbf\xce\xee\x63\x7b\x9a\xdd\xcd\xe6\x50\x79\x08\x55\xd4\xa1\xbe\x40\xb0\xed\xec\x6e\xf6\x80\x3e\x81\x3e\x23\x72\x9a\xfd\x76\x37\x7c\xf7\xc0\x27\x33\x7e\xf1\x90\x03\x9a\x88\x3a\x2d\xc7\x64\x76\x74\xf4\xb3\xbb\xd9\xf2\x77\x62\xfd\x7f\xe9\x89\xaa\xf3\xec\x25\x51\x6a\x9d\xf7\xf1\x62\x6c\x49\x8c\x31\xcd\xee\x66\x4f\x1e\xac\x43\x96\x69\x2b\x84\x24\x0e\xac\x5c\xd3\x8e\x9f\xae\xf4\xb3\xbb\xd9\x47\x8b\xa6\x76\xe8\xab\x89\x8d\x5f\x72\x68\x3c\xce\xee\x66\xcf\x74\x1c\xe7\xaf\x31\x82\x3e\x89\x58\x1f\x39\x24\x70\x41\x5e\xbd\x60\x62\x57\x3b\xac\x4c\x5d\x16\x3f\x1b\x7a\xf1\xc3\x94\x57\x70\xa1\x1e\x3d\x7b\x75\x07\xe4\xd1\xee\x06\x7c\x32\x3d\x04\x1d\x1e\x20\x04\xd9\xfa\x26\x61\xdf\xe3\xc5\xce\x1b\xb8\x46\xde\xbf\xb5\xce\xee\x31\xc9\x77\x6f\x39\x54\x2c\xef\xbe\x90\xb7\x10\x9c\x35\xbd\x2c\x36\xbb\x9b\x6d\x31\x8d\xc6\xb7\x44\x03\x16\xbf\x7d\x30\x46\xcd\x4d\x21\x94\xbf\x3a\xe0\xfd\x14\xc4\x39\x35\x02\x19\x65\x99\x55\x22\x23\xbf\x73\x4a\x12\x90\x05\x1c\xf4\xe1\x5d\x5d\xcb\x93\xa1\xb9\x78\xb9\x60\x48\xc8\xfa\x1a\x71\xaf\x4f\x8a\xd1\x05\x31\xf8\xe0\x92\x9e\x81\xe5\x60\x70\xf9\x43\xa4\x9e\x98\xd4\xb2\xc0\x22\x0f\xf2\x9e\x8e\x3a\x48\x26\xf6\xec\x42\x23\xfb\x79\x06\xc7\xfa\xd8\x4f\x82\x23\xbf\x76\x28\x46\xd7\xc0\xb1\x1d\xb0\xba\x40\xf5\x02\x51\x51\x72\x53\x60\x28\x54\x0a\x4b\xef\xaa\x82\xcf\xc1\x05\x54\x6c\xaa\xa6\x3c\x23\x8e\x50\x5d\x3e\x7b\x25\xbb\x8f\xde\x55\xf2\xd7\x46\xbd\x92\xc1\x11\xba\xfe\x1a\x9c\x2f\xe0\x3d\xca\xd1\xdf\x4a\x44\x6a\xf0\xfe\x36\x00\x31\x71\xb6\x29\x33\x5e\xa5\x91\x4f\x20\x7e\xdf\x7f\xcb\x58\x65\x9b\x34\x8f\x42\xe5\xd2\xff\xfe\xf3\xdf\x68\x6c\x59\x6c\x0e\x29\x79\x3c\xc3\x43\xa1\x76\x2c\x5e\xcd\x59\x37\x70\xc1\x04\x1c\x87\x11\x0a\x26\xd0\xdd\x2e\xf8\xd4\x8b\xd9\x07\xe8\x4a\xca\x35\x48\x32\x69\x09\xdc\x5d\x65\xd2\x80\x54\x62\xd4\x10\x3e\x81\xa0\xa2\x23\x86\x03\x9e\x40\x27\xac\xb0\x84\x6c\x95\x43\x42\xbe\x38\x79\x36\xf4\x31\x88\xf1\xe7\xdc\xed\x90\x47\xff\xd7\x25\xdc\x6b\x0a\x10\x13\xf2\xa9\x8c\x73\x87\x41\x1c\xfb\xcc\xb6\x15\xe3\x67\x13\x9f\x73\xea\x49\x93\xe7\x05\xa2\x04\x4c\xb0\xc9\x7a\xdc\x37\x68\x7d\x8e\x4e\x37\xb0\x69\xc1\xee\xf5\xc9\x62\xff\xfc\xf9\x26\x49\x00\x43\x63\x62\x22\x5d\xf7\x0d\xbb\x5e\x33\xfc\x8b\xf3\x1e\xd4\xfd\x2d\xe8\xc9\xdb\x42\xb2\x6d\xa2\xa3\x1e\xe4\x2d\x9c\xca\x17\x37\xd1\x2b\x0c\xf8\x35\x31\xb8\xf4\x03\x0f\xa2\x78\x33\xf7\xb2\x37\xc5\xc7\xbb\xa6\x1d\x86\x4c\x7b\xfd\x77\x41\x21\xe6\xae\x1c\xa1\x05\x31\xe7\x5e\x26\x4c\x92\x09\xb1\x1f\x72\x07\x23\x79\xd0\xfc\x7b\xfc\xe7\xdb\xe3\xeb\xa7\xfb\x67\x19\x26\xe4\x00\xfe\xfa\xe5\x92\x38\x82\xd8\xbf\xa0\xc8\xf4\xae\xeb\xad\x40\xf0\x51\xc0\xe8\xe8\x8b\xe5\x5f\xa0\x69\xf4\xd5\x33\x05\xf4\x0a\x82\x8b\xe9\x34\xc9\x13\x64\xe7\x29\x5f\xb1\x9c\x8c\x5b\x08\x09\x62\xa7\xcb\xbf\xc2\x01\x43\x99\x23\x0c\xa6\xc1\xdc\xb4\x50\xd1\x71\x62\x68\xd3\xba\x3a\x0d\xf9\xd2\x4a\x52\x0d\x63\x17\x5c\x2c\xa4\xb1\x71\x61\x3f\xbc\xec\x48\x62\x3c\x66\x17\xfa\x54\x7e\x5c\xe8\xb0\x25\x0e\x27\x4d\xb9\x1c\xce\x33\xdf\x88\x19\x43\x72\x3f\xc6\x64\x0b\x97\x39\x5b\x97\x5a\x64\x89\xf3\x2d\x40\x2b\x17\x2d\x89\x6f\x57\xf9\x38\xd7\x92\x13\x47\xb6\x9f\x53\xc0\x78\x06\xd2\x1c\x11\x7a\x2a\x7f\x64\x66\xe5\xac\x29\x48\xe3\xf0\x82\x6b\x4e\x86\xa9\x57\x13\x0f\x08\x95\x81\xe0\xba\x3f\xc2\x28\x2b\x5a\x86\xfe\x9c\x6c\x46\x88\x5a\x03\xb5\xca\x1d\x04\x63\x89\xfb\x38\x39\xe2\xb7\x16\x15\x46\x6c\x9c\x05\x6f\xb0\xae\x51\x99\x64\x0d\x7d\x21\xc8\x58\x80\x5a\xbb\x86\x21\x49\xf6\xdc\xb2\xf4\xa9\x14\xac\x17\xe2\x54\xa0\xc6\x48\x99\xad\x3a\xff\xea\xea\xa4\xa5\x8a\x21\x34\x28\xd5\x27\xa4\x9b\x46\x36\xb9\xef\xbd\xd3\x6f\xde\x88\x83\xa9\x3d\x28\x5c\x0c\x76\x1f\xcb\x40\xe9\x93\x11\x62\x66\x34\x16\x6c\xfb\xa7\x1b\xfb\xd3\xe1\xd6\xbd\x03\x57\xa6\x96\xc4\xbb\x8d\x36\xd8\xe4\x0e\x2e\x5d\x83\x7d\xdf\xed\xb2\xd6\x90\x7b\x6e\xb2\x12\xaa\x63\xd5\x0e\xf3\xec\x86\x4a\xa8\x64\xb5\x80\x5e\x69\xe8\x96\x9b\x0b\x0a\x07\x54\x9a\x79\xc0\x8e\xbc\x53\x7b\x0f\x4e\x5f\x64\xf4\x37\x8f\xc5\x23\x48\x30\x1f\xbf\x5b\x38\x94\x4c\x5f\x22\x68\xec\x97\xe8\x87\x64\x5d\x16\x43\x4b\x8f\x78\x45\xd2\x70\x66\xdf\x52\x02\xb5\xce\xbe\x82\xab\x0a\x60\x56\xb7\xf1\x7a\x55\x6d\x37\x60\x25\x97\xad\xa6\xaa\xa5\x9c\x4a\xfe\x69\xbe\xed\x0b\xab\xee\x1d\x77\x65\xc1\x8d\x87\x69\x22\x7b\xc4\x5e\xf3\xd2\x75\x23\x8a\x17\x10\x4b\xae\xa9\xf2\xe0\xd8\xba\xfe\x76\xe4\x5b\x10\x6c\xae\xc2\x7e\x00\x0f\x41\x70\x57\xb2\x7c\x7f\x2f\xa5\x65\xce\x39\xb6\x43\x65\x5b\x78\xca\xd5\x2e\xb3\x46\x65\x71\xb2\x9e\x86\x10\x87\x88\xa6\xa6\x09\x3d\x3c\xd0\x31\xf4\x94\xc5\x8d\x07\x76\xef\xef\x1e\x47\x35\x19\x13\xb1\x78\xfd\x08\x9c\xda\x6f\x59\x64\xc4\xdd\xec\x51\xa8\xb7\xd4\x0f\x55\x97\x57\x54\x53\x74\x8a\x19\x7c\x58\x81\xf3\x83\x9e\x34\xc7\x22\x85\x56\x99\xd9\x59\x50\x5f\x44\x4b\x8e\x4b\x3c\xcb\xc1\x33\x9d\x9b\x86\xfd\x99\xac\x7a\x71\x04\x9d\xb2\x86\xa6\x03\x53\x17\xa1\xb3\xc6\x84\xc4\x26\x26\x76\xfb\xa1\x32\x46\x52\xa7\xd6\xb9\x1a\xe7\xe4\xaa\xa8\x8f\x0b\x3f\x33\x56\x90\x54\xe6\xfc\x3d\x3b\xbb\x8f\x30\xe8\x1a\x17\x0c\xd5\xa6\x66\x52\xdd\x74\xa5\x5b\x44\x0f\x0e\x4e\x0a\x98\xd3\x63\x11\x74\x99\x4d\x82\xae\x47\x9d\x3c\x10\xec\x38\xff\x2d\xe6\x00\x9d\x13\x7c\x5b\xc7\xbe\x27\xd2\x92\xe9\x46\x8b\x17\xb4\xb1\x72\x3b\x8f\x5f\x95\x15\xae\x80\xb6\xc4\xca\x96\xf7\x7d\xef\x95\x13\xee\x63\x0f\x0c\x8d\xd6\x8f\xb9\x07\xbb\xdf\x21\x73\xa1\x8b\xb9\xcf\x78\xf9\xb5\x00\x66\x4a\x71\xaa\x6d\x52\x2a\x80\x2c\xda\xcb\x2c\x51\x61\x47\xd4\x32\x25\x63\x2a\xe9\xea\x85\xd7\x55\xf2\x84\x0a\xfd\x15\xdf\x09\x0b\xff\x14\x50\xf4\x94\x9c\x06\x39\xa5\x97\x45\x97\x8e\x71\xb0\xf6\x44\x14\x27\xee\xac\xe0\x1d\x7d\xc8\xa9\x34\x18\x61\x37\x95\x97\x2b\x67\xf7\xc4\x27\x33\xfe\x4d\x01\x4f\x31\xdb\x7d\x69\x2a\x10\x95\xf7\xd6\xce\xef\x4d\x6a\x5d\x2c\x0b\xaf\x5d\x49\xe0\xec\xc7\x35\xce\xe6\xd6\x39\xb6\x4c\xd4\xe9\x57\x39\xa6\x92\x1c\x9f\x43\x39\xb4\x2f\x68\x61\xe8\x43\x38\xba\xae\xa3\xa1\xe3\x88\xfd\x1f\x0c\x09\x59\x1f\x2f\x5b\xd8\xc2\xb8\x01\xd5\xa9\x76\x90\x79\x5b\xe7\x2b\xd3\x00\x7b\x67\xcf\xbf\x18\x4a\xc9\xda\x6a\x65\x92\x4a\x3b\x95\xb4\x3d\xb9\x48\xa2\x01\x6e\x00\x1e\x1a\xf4\x2a\x0a\x13\xe7\xae\xc7\x41\xce\x6a\x20\x4b\x73\xe8\x3d\x54\xa4\x6d\x8f\xc2\x2f\xf3\xea\xda\x17\x26\x40\x54\xd9\xd6\x22\xb0\xa6\x3d\x7a\x15\x72\x53\x81\x4b\x12\xd6\x9d\x66\xfb\x82\x7c\xee\x76\x45\x59\x2e\x98\x8e\xc1\xe6\xbe\x94\xd9\xd4\x1a\xab\x04\xf5\x90\xbb\xdd\x90\xad\x4b\xfa\xde\xc8\xb1\x98\xc0\x86\x9d\x27\xa5\xb3\x15\x35\x03\xea\xd2\x89\x9c\xf4\xc9\x11\x8d\x6d\x31\xa6\xa0\x7c\xb9\x3a\x81\x75\x41\x6b\xc3\xc7\xc3\x84\x20\x7f\x91\xda\xda\x15\x27\xfe\x96\xab\xac\xfd\x0a\xef\x63\xaf\x2e\xae\x41\xda\xb6\x92\xe1\x10\x9a\xa1\xeb\x59\xeb\x21\x48\x34\xf1\x65\x4d\x14\x24\xed\xf5\xd4\x7e\x12\x32\x89\x2d\x68\x4e\x7e\xf6\x38\xb2\xec\x2b\x34\x47\xd2\xc8\xbc\xa2\x0b\x15\x22\x1b\xef\x6c\x51\x9f\x9b\x00\xfb\x72\x74\x2f\xf0\xf7\x2e\x54\x1a\xd9\x4d\x72\x61\x2f\x2a\x4a\xb1\xff\x5e\x62\xb3\x75\x01\x7f\x5a\x94\x21\xf9\x3a\xee\x4a\x9c\xb6\xc4\xdd\x91\x68\xaa\x99\x5c\x08\x5f\xa1\xfa\x1d\xa5\x82\x5e\x6b\x25\x94\x0e\xa1\x54\x92\xb9\x87\xf7\x71\x84\xb0\x2f\xcf\x18\x07\x41\x4c\x54\x69\x62\xb2\xeb\xe2\x34\x1b\x17\x39\x84\x51\x14\xf7\xfd\x98\xb3\x76\x54\xc2\x50\x29\xab\xe7\x50\x44\xf4\xd2\x9f\xae\xe8\xfa\xa9\x85\x98\x14\xaf\x27\xd1\x90\xaa\x7b\xd1\xf7\x75\x56\xda\x76\x15\x16\x9d\x7a\x51\xc0\xab\x1c\x1a\x3e\x4d\xc3\xee\xd5\xaf\xb5\x34\xbc\x83\x68\xfc\xe4\xba\x9d\x46\xed\x33\x0d\x1b\xba\xd2\xc2\x3c\xb8\x37\xe9\x12\x3b\x08\x49\x93\x47\xba\xfb\xd3\x50\x5c\x6f\xa8\xdf\x96\x1d\x8e\xa2\xd7\xf9\xab\x56\x73\xd3\xd1\xf0\xcf\x5b\xeb\x38\xaa\x95\xad\x34\x98\xb2\xe6\x9b\xeb\xe3\xa9\xb0\x70\x4c\xc3\x4e\xb6\x10\x92\x04\xf2\x0a\xa4\x40\xf9\xfa\x8a\xe6\xbb\xe6\x15\x68\xfe\xea\xcd\x0c\x0f\x39\xa8\xca\x96\x34\x3b\xe9\xe8\x2f\x7e\xcc\xb3\x34\xb5\x4a\xbf\xc3\xd9\x59\x94\x14\x59\x68\xad\x78\x60\x68\x94\x85\x1e\x9b\x49\x04\x1e\x3d\xf6\xd2\x22\x14\xb9\x02\xa5\x31\x91\x8f\x9e\x5c\x79\xfb\xc4\xae\xae\x5d\x69\x4b\xa6\x57\x41\x2b\xbd\x7d\x58\x51\xd6\x32\xf6\x0c\xdd\x4e\x4b\x69\xa9\x83\x60\xf7\x58\xfc\x5e\x8b\xba\x99\x60\x16\xf6\xa5\xdd\x57\x3a\x74\x3d\x2a\x2c\x2e\xa8\xbe\x79\x55\x65\xb5\xd9\x67\xef\xa7\x99\x50\x26\x6f\x4a\xab\xbd\x39\x96\x0b\x98\x63\x69\x79\xb7\x2d\xe8\x4e\xb7\xae\xc6\x1f\x02\xfa\x2d\xbb\xeb\xfb\x92\xbf\xfc\xfc\xb3\x39\x21\x70\x34\x2e\x98\xbe\x68\xb6\x7b\x7f\x84\x53\x34\x41\xb5\xe7\xdd\xec\x5e\x15\x7e\x91\xa2\xe5\x56\x8c\x2b\x53\x65\xd4\xfb\xa7\xb9\x6b\x1a\x64\xe3\x42\x2c\xe5\xb9\x70\xa0\x8a\xfd\x49\x5c\xe6\x0c\xa1\x32\x01\x8f\x05\x88\xe0\x76\xa0\x5f\x5f\xab\xce\x98\x20\x24\xd3\x03\xeb\x69\x19\xd2\xc6\x58\x0a\xa9\xe8\x78\xed\x37\x2a\xa6\xfe\xb6\xba\xfe\xde\x63\x88\xee\xf0\x63\x9f\x39\x69\x4b\xa0\xa3\x1c\x85\x04\x6b\x55\xa6\x27\xd3\x43\x62\xa9\x37\x17\xbd\xa4\xb2\xc7\xfa\xbc\xd3\xe2\x79\x40\xd1\x37\xa4\xb7\x70\x4f\x2d\xa9\x04\x03\xbd\x3a\x9a\xb4\xa3\x9a\x96\xe9\xa6\x2c\xd6\xfe\xc5\xc4\x01\x97\xa1\x9b\xf1\x27\xd3\xd1\x01\xcb\xad\x1c\xdb\x68\x6a\x62\xd3\x16\x85\x36\xf1\xf6\x85\x11\x6c\x3b\x64\x17\x5a\x69\x2d\x44\xa5\x40\x73\x7d\x31\x50\xd7\x06\x18\xcd\xbe\x5c\x04\xbd\x81\x97\xb4\x33\x3d\xb8\x30\xf4\xab\xff\x10\xb2\x6d\x78\x38\x93\x5f\x3e\xbe\x18\x4f\x39\xa8\xe8\xfe\x42\xce\xa2\x00\x7f\x2c\x19\xb4\xa5\x0e\x83\xa1\xe0\x4f\xe5\xd8\x7c\xf8\xf7\x87\xff\x07\x00\x00\xff\xff\xed\x0a\xeb\x29\x37\x15\x00\x00") + +func wildJsonBytes() ([]byte, error) { + return bindataRead( + _wildJson, + "wild.json", + ) +} + +func wildJson() (*asset, error) { + bytes, err := wildJsonBytes() + if err != nil { + return nil, err + } + + info := bindataFileInfo{name: "wild.json", size: 5431, mode: os.FileMode(420), modTime: time.Unix(1594526741, 0)} + a := &asset{bytes: bytes, info: info} + return a, nil +} + +// Asset loads and returns the asset for the given name. +// It returns an error if the asset could not be found or +// could not be loaded. +func Asset(name string) ([]byte, error) { + cannonicalName := strings.Replace(name, "\\", "/", -1) + if f, ok := _bindata[cannonicalName]; ok { + a, err := f() + if err != nil { + return nil, fmt.Errorf("Asset %s can't read by error: %v", name, err) + } + return a.bytes, nil + } + return nil, fmt.Errorf("Asset %s not found", name) +} + +// MustAsset is like Asset but panics when Asset would return an error. +// It simplifies safe initialization of global variables. +func MustAsset(name string) []byte { + a, err := Asset(name) + if err != nil { + panic("asset: Asset(" + name + "): " + err.Error()) + } + + return a +} + +// AssetInfo loads and returns the asset info for the given name. +// It returns an error if the asset could not be found or +// could not be loaded. +func AssetInfo(name string) (os.FileInfo, error) { + cannonicalName := strings.Replace(name, "\\", "/", -1) + if f, ok := _bindata[cannonicalName]; ok { + a, err := f() + if err != nil { + return nil, fmt.Errorf("AssetInfo %s can't read by error: %v", name, err) + } + return a.info, nil + } + return nil, fmt.Errorf("AssetInfo %s not found", name) +} + +// AssetNames returns the names of the assets. +func AssetNames() []string { + names := make([]string, 0, len(_bindata)) + for name := range _bindata { + names = append(names, name) + } + return names +} + +// _bindata is a table, holding each asset generator, mapped to its name. +var _bindata = map[string]func() (*asset, error){ + "character.json": characterJson, + "city.json": cityJson, + "data.go": dataGo, + "magic.json": magicJson, + "maze.json": mazeJson, + "monster.json": monsterJson, + "npc.json": npcJson, + "treasure.json": treasureJson, + "wild.json": wildJson, +} + +// AssetDir returns the file names below a certain +// directory embedded in the file by go-bindata. +// For example if you run go-bindata on data/... and data contains the +// following hierarchy: +// data/ +// foo.txt +// img/ +// a.png +// b.png +// then AssetDir("data") would return []string{"foo.txt", "img"} +// AssetDir("data/img") would return []string{"a.png", "b.png"} +// AssetDir("foo.txt") and AssetDir("notexist") would return an error +// AssetDir("") will return []string{"data"}. +func AssetDir(name string) ([]string, error) { + node := _bintree + if len(name) != 0 { + cannonicalName := strings.Replace(name, "\\", "/", -1) + pathList := strings.Split(cannonicalName, "/") + for _, p := range pathList { + node = node.Children[p] + if node == nil { + return nil, fmt.Errorf("Asset %s not found", name) + } + } + } + if node.Func != nil { + return nil, fmt.Errorf("Asset %s not found", name) + } + rv := make([]string, 0, len(node.Children)) + for childName := range node.Children { + rv = append(rv, childName) + } + return rv, nil +} + +type bintree struct { + Func func() (*asset, error) + Children map[string]*bintree +} + +var _bintree = &bintree{nil, map[string]*bintree{ + "character.json": &bintree{characterJson, map[string]*bintree{}}, + "city.json": &bintree{cityJson, map[string]*bintree{}}, + "data.go": &bintree{dataGo, map[string]*bintree{}}, + "magic.json": &bintree{magicJson, map[string]*bintree{}}, + "maze.json": &bintree{mazeJson, map[string]*bintree{}}, + "monster.json": &bintree{monsterJson, map[string]*bintree{}}, + "npc.json": &bintree{npcJson, map[string]*bintree{}}, + "treasure.json": &bintree{treasureJson, map[string]*bintree{}}, + "wild.json": &bintree{wildJson, map[string]*bintree{}}, +}} + +// RestoreAsset restores an asset under the given directory +func RestoreAsset(dir, name string) error { + data, err := Asset(name) + if err != nil { + return err + } + info, err := AssetInfo(name) + if err != nil { + return err + } + err = os.MkdirAll(_filePath(dir, filepath.Dir(name)), os.FileMode(0755)) + if err != nil { + return err + } + err = ioutil.WriteFile(_filePath(dir, name), data, info.Mode()) + if err != nil { + return err + } + err = os.Chtimes(_filePath(dir, name), info.ModTime(), info.ModTime()) + if err != nil { + return err + } + return nil +} + +// RestoreAssets restores an asset under the given directory recursively +func RestoreAssets(dir, name string) error { + children, err := AssetDir(name) + // File + if err != nil { + return RestoreAsset(dir, name) + } + // Dir + for _, child := range children { + err = RestoreAssets(dir, filepath.Join(name, child)) + if err != nil { + return err + } + } + return nil +} + +func _filePath(dir, name string) string { + cannonicalName := strings.Replace(name, "\\", "/", -1) + return filepath.Join(append([]string{dir}, strings.Split(cannonicalName, "/")...)...) +} diff --git a/cmd/generate.go b/cmd/generate.go new file mode 100644 index 0000000..e99f448 --- /dev/null +++ b/cmd/generate.go @@ -0,0 +1,118 @@ +package cmd + +import ( + "fmt" + "github.com/spf13/cobra" + "mazeratsgen/internal/dice" + "mazeratsgen/internal/tables" + "time" +) + +var generateCmd = &cobra.Command{ + Use: "generate", + Short: "Generate various things", +} + +var generateNameCmd = &cobra.Command{ + Use: "name", + Short: "Generate a name", + Run: func(cmd *cobra.Command, args []string) { + n := tables.GenRandomName(flagSeed) + template := "{{.FullName}}" + output, err := buildOutput(n, template, flagFormat) + if err != nil { + panic(err) + } + fmt.Printf(output) + }, +} + +var generateCharCmd = &cobra.Command{ + Use: "character", + Short: "Generate a playable character", + Run: func(cmd *cobra.Command, args []string) { + t := tables.CharacterTable{Roller: dice.NewRoller(flagSeed)} + i := t.Generate() + template := t.Template() + output, err := buildOutput(i, template, flagFormat) + if err != nil { + panic(err) + } + fmt.Printf(output) + }, +} + +var generateMonsterCmd = &cobra.Command{ + Use: "monster", + Short: "Generate a monster", + Run: func(cmd *cobra.Command, args []string) { + t := tables.MonsterTable{Roller: dice.NewRoller(flagSeed)} + i := t.Generate() + template := t.Template() + output, err := buildOutput(i, template, flagFormat) + if err != nil { + panic(err) + } + fmt.Printf(output) + }, +} + +var generateCityCmd = &cobra.Command{ + Use: "city", + Short: "Generate a city", + Run: func(cmd *cobra.Command, args []string) { + t := tables.CityTable{Roller: dice.NewRoller(flagSeed)} + i := t.Generate() + template := t.Template() + output, err := buildOutput(i, template, flagFormat) + if err != nil { + panic(err) + } + fmt.Printf(output) + }, +} + +var generateSpellCmd = &cobra.Command{ + Use: "spell", + Short: "Generate a spell", + Run: func(cmd *cobra.Command, args []string) { + t := tables.MagicTable{Roller: dice.NewRoller(flagSeed)} + i := t.Generate() + template := t.Template() + output, err := buildOutput(i, template, flagFormat) + if err != nil { + panic(err) + } + fmt.Printf(output) + }, +} + +func buildOutput(i interface{}, template string, format string) (string, error) { + var output interface{} + var err error + if format == "json" { + output, err = tables.ConvertToJSON(i) + } else { + output, err = tables.ConvertToText(i, template) + } + if err != nil { + return "", err + } + return fmt.Sprintf("%s\n", output), nil +} + +var flagFormat string +var flagSeed int64 + +func init() { + rootCmd.AddCommand(generateCmd) + + generateCmd.PersistentFlags().StringVarP(&flagFormat, "format", "f", "text", `output format: "text", "json"`) + generateCmd.PersistentFlags().Int64VarP(&flagSeed, "seed", "s", time.Now().UnixNano(), "seed for randomness") + + generateCmd.AddCommand(generateCharCmd) + generateCmd.AddCommand(generateCityCmd) + generateCmd.AddCommand(generateMonsterCmd) + generateCmd.AddCommand(generateNameCmd) + generateCmd.AddCommand(generateSpellCmd) +} diff --git a/cmd/root.go b/cmd/root.go new file mode 100644 index 0000000..016386a --- /dev/null +++ b/cmd/root.go @@ -0,0 +1,21 @@ +package cmd + +import ( + "fmt" + "github.com/spf13/cobra" + "os" +) + +var rootCmd = &cobra.Command{ + Use: "mrg [command]", + Short: "Generate Maze Rats things", +} + +// Execute adds all child commands to the root command and sets flags appropriately. +// This is called by main.main(). It only needs to happen once to the rootCmd. +func Execute() { + if err := rootCmd.Execute(); err != nil { + fmt.Println(err) + os.Exit(1) + } +} diff --git a/cmd/server.go b/cmd/server.go new file mode 100644 index 0000000..13af138 --- /dev/null +++ b/cmd/server.go @@ -0,0 +1,61 @@ +package cmd + +import ( + "github.com/gorilla/mux" + "github.com/spf13/cobra" + "github.com/throttled/throttled" + "github.com/throttled/throttled/store/memstore" + "log" + "mazeratsgen/internal/handlers" + "net/http" +) + +var serverCmd = &cobra.Command{ + Use: "server", + Short: "Create a web server with REST API", + Run: startServer, +} + +func init() { + rootCmd.AddCommand(serverCmd) +} + +func startServer(cmd *cobra.Command, args []string) { + r := mux.NewRouter() + handlers.LoadHandlers(r) + + r.PathPrefix("/").Handler(http.StripPrefix("/", http.FileServer(http.Dir("web/swagger")))) + + r.Use(loggingMiddleware) + log.Printf("Starting web server on 0.0.0.0:8080") + + store, err := memstore.New(65536) + if err != nil { + log.Fatal(err) + } + + // Maximum burst of 30 which refills at 5 tokens per minute. + quota := throttled.RateQuota{MaxRate: throttled.PerMin(30), MaxBurst: 5} + + rateLimiter, err := throttled.NewGCRARateLimiter(store, quota) + if err != nil { + log.Fatal(err) + } + + httpRateLimiter := throttled.HTTPRateLimiter{ + RateLimiter: rateLimiter, + VaryBy: &throttled.VaryBy{Path: true}, + } + + log.Fatal(http.ListenAndServe(":8080", httpRateLimiter.RateLimit(r))) +} + +func loggingMiddleware(next http.Handler) http.Handler { + return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { + log.Printf( + "%s %s %s %s", + r.RemoteAddr, r.Method, r.URL, r.Header["User-Agent"], + ) + next.ServeHTTP(w, r) + }) +} diff --git a/cmd/wip/data.html b/cmd/wip/data.html new file mode 100644 index 0000000..b2adc63 --- /dev/null +++ b/cmd/wip/data.html @@ -0,0 +1,1173 @@ + + + + + + + +
+ Cities + +
+ + + +
+ Wilds + +
+ + + +
+ Dungeons + +
+ + + +
+ Treasures + +
+ + + +
+ Characters + +
+ + + +
+ NPCs + +
+ + + +
+ Magic + +
+ + + +
+ Monsters + + + + +
+ + + diff --git a/cmd/wip/game.html b/cmd/wip/game.html new file mode 100644 index 0000000..64c64ae --- /dev/null +++ b/cmd/wip/game.html @@ -0,0 +1,544 @@ + + + + + + + +
+ Cities + +
+ + + +
+ Wilds + +
+ + + +
+ Dungeons + +
+ + + +
+ Treasures + +
+ + + +
+ Characters + +
+ + + +
+ NPCs + +
+ + + +
+ Magic + +
+ + + +
+ Monsters + {{- range $monster := .Monsters }} + + {{- end }} + +
+ + + diff --git a/cmd/wip/main.go b/cmd/wip/main.go new file mode 100644 index 0000000..9491273 --- /dev/null +++ b/cmd/wip/main.go @@ -0,0 +1,116 @@ +package main + +import ( + "math/rand" + "mazeratsgen/internal/helpers" + "mazeratsgen/internal/tables" + "os" + "text/template" + "time" +) + +type MagicInfo struct { + Mutations []string + Insanities []string + Catastrophes []string +} + +type TreasuresInfo struct { + MiscItems []string + WornItems []string + Weapons []string + Books []string + Tools []string + MagicalIngredients []string + Treasures []string + Potions []tables.Potion + ValuableMaterials []string +} + +type Variables struct { + Characters []tables.Character + Cities []tables.City + MagicInfo MagicInfo + Monsters []tables.Monster + NPCs []tables.NPC + Wilds []tables.Wild + Dungeons []tables.Maze + Treasures TreasuresInfo +} + +func main() { + rand.Seed(time.Now().UnixNano()) + + var potions []tables.Potion + for i := 0; i < 10; i++ { + potions = append(potions, tables.GenPotion()) + } + + treasuresInfo := TreasuresInfo{ + MiscItems: helpers.GenUniqueItems(10, tables.TreasureTable{}.GenMiscItem), + WornItems: helpers.GenUniqueItems(10, tables.TreasureTable{}.GenWornItem), + Weapons: helpers.GenUniqueItems(10, tables.TreasureTable{}.GenWeaponItem), + Books: helpers.GenUniqueItems(10, tables.TreasureTable{}.GenBookSubject), + Tools: helpers.GenUniqueItems(10, tables.TreasureTable{}.GenToolItem), + ValuableMaterials: helpers.GenUniqueItems(10, tables.TreasureTable{}.GenValuableMaterial), + MagicalIngredients: helpers.GenUniqueItems(10, tables.TreasureTable{}.GenMagicalIngredient), + Treasures: helpers.GenUniqueItems(10, tables.GenTreasure), + Potions: potions, + } + + chars := []tables.Character{} + chars = append(chars, tables.GenCharacter("Upper Class", "Male")) + + cities := []tables.City{} + cities = append(cities, tables.GenCity()) + + magicInfo := MagicInfo{ + Mutations: helpers.GenUniqueItems(10, tables.MagicTable{}.GenMutation), + Insanities: helpers.GenUniqueItems(10, tables.MagicTable{}.GenInsanity), + Catastrophes: helpers.GenUniqueItems(10, tables.MagicTable{}.GenCatastrophe), + } + + monsters := []tables.Monster{} + monsters = append(monsters, tables.GenMonster()) + monsters = append(monsters, tables.GenMonster()) + monsters = append(monsters, tables.GenMonster()) + + // Civilized, Underworld, Wilderness + npcs := []tables.NPC{} + npcs = append(npcs, tables.GenNPC()) + npcs = append(npcs, tables.GenNPC()) + npcs = append(npcs, tables.GenNPC()) + npcs = append(npcs, tables.GenNPC()) + npcs = append(npcs, tables.GenNPC()) + npcs = append(npcs, tables.GenNPC()) + + wilds := []tables.Wild{} + wilds = append(wilds, tables.GenWild()) + wilds = append(wilds, tables.GenWild()) + wilds = append(wilds, tables.GenWild()) + + dungeons := []tables.Maze{} + dungeons = append(dungeons, tables.GenMaze()) + dungeons = append(dungeons, tables.GenMaze()) + dungeons = append(dungeons, tables.GenMaze()) + + variables := Variables{ + Characters: chars, + Cities: cities, + MagicInfo: magicInfo, + Monsters: monsters, + NPCs: npcs, + Wilds: wilds, + Dungeons: dungeons, + Treasures: treasuresInfo, + } + + tmpl, err := template.ParseFiles(helpers.LocalFile("game.html")) + if err != nil { + panic(err) + } + err = tmpl.Execute(os.Stdout, variables) + if err != nil { + panic(err) + } +} diff --git a/cmd/wip/output.html b/cmd/wip/output.html new file mode 100644 index 0000000..dbd14d7 --- /dev/null +++ b/cmd/wip/output.html @@ -0,0 +1,1467 @@ + + + + + + + +
+ Cities + +
+ + + +
+ Wilds + +
+ + + +
+ Dungeons + +
+ + + +
+ Treasures + +
+ + + +
+ Characters + +
+ + + +
+ NPCs + +
+ + + +
+ Magic + +
+ + + +
+ Monsters + + + + +
+ + + diff --git a/go.mod b/go.mod new file mode 100644 index 0000000..92bfc2b --- /dev/null +++ b/go.mod @@ -0,0 +1,21 @@ +module mazeratsgen + +go 1.14 + +require ( + github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751 + github.com/go-bindata/go-bindata v3.1.2+incompatible // indirect + github.com/go-openapi/spec v0.19.8 // indirect + github.com/go-openapi/swag v0.19.9 // indirect + github.com/gorilla/mux v1.7.4 + github.com/hashicorp/golang-lru v0.5.4 // indirect + github.com/mailru/easyjson v0.7.1 // indirect + github.com/spf13/cobra v1.0.0 + github.com/swaggo/swag v1.6.7 + github.com/throttled/throttled v2.2.4+incompatible + github.com/urfave/cli/v2 v2.2.0 // indirect + golang.org/x/net v0.0.0-20200707034311-ab3426394381 // indirect + golang.org/x/text v0.3.3 // indirect + golang.org/x/tools v0.0.0-20200711155855-7342f9734a7d // indirect + gopkg.in/yaml.v2 v2.3.0 // indirect +) diff --git a/go.sum b/go.sum new file mode 100644 index 0000000..9311000 --- /dev/null +++ b/go.sum @@ -0,0 +1,266 @@ +cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= +github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= +github.com/KyleBanks/depth v1.2.1 h1:5h8fQADFrWtarTdtDudMmGsC7GPbOAu6RVB3ffsVFHc= +github.com/KyleBanks/depth v1.2.1/go.mod h1:jzSb9d0L43HxTQfT+oSA1EEp2q+ne2uh6XgeJcm8brE= +github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= +github.com/PuerkitoBio/purell v1.1.0/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0= +github.com/PuerkitoBio/purell v1.1.1 h1:WEQqlqaGbrPkxLJWfBwQmfEAE1Z7ONdDLqrN38tNFfI= +github.com/PuerkitoBio/purell v1.1.1/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0= +github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578 h1:d+Bc7a5rLufV/sSk/8dngufqelfh6jnri85riMAaF/M= +github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578/go.mod h1:uGdkoq3SwY9Y+13GIhn11/XLaGBb4BfwItxLd5jeuXE= +github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= +github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751 h1:JYp7IbQjafoB+tBA3gMyHYHrpOtNuDiK/uB5uXxq5wM= +github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= +github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= +github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8= +github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q= +github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8= +github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= +github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= +github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk= +github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= +github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= +github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= +github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= +github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= +github.com/cpuguy83/go-md2man/v2 v2.0.0 h1:EoUDS0afbrsXAZ9YQ9jdu/mZ2sXgT1/2yyNng4PGlyM= +github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= +github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ= +github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no= +github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= +github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk= +github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= +github.com/gin-contrib/gzip v0.0.1/go.mod h1:fGBJBCdt6qCZuCAOwWuFhBB4OOq9EFqlo5dEaFhhu5w= +github.com/gin-contrib/sse v0.0.0-20170109093832-22d885f9ecc7/go.mod h1:VJ0WA2NBN22VlZ2dKZQPAPnyWw5XTlK1KymzLKsr59s= +github.com/gin-contrib/sse v0.0.0-20190301062529-5545eab6dad3/go.mod h1:VJ0WA2NBN22VlZ2dKZQPAPnyWw5XTlK1KymzLKsr59s= +github.com/gin-contrib/sse v0.1.0/go.mod h1:RHrZQHXnP2xjPF+u1gW/2HnVO7nvIa9PG3Gm+fLHvGI= +github.com/gin-gonic/gin v1.3.0/go.mod h1:7cKuhb5qV2ggCFctp2fJQ+ErvciLZrIeoOSOm6mUr7Y= +github.com/gin-gonic/gin v1.4.0/go.mod h1:OW2EZn3DO8Ln9oIKOvM++LBO+5UPHJJDH72/q/3rZdM= +github.com/go-bindata/go-bindata v1.0.0 h1:DZ34txDXWn1DyWa+vQf7V9ANc2ILTtrEjtlsdJRF26M= +github.com/go-bindata/go-bindata v3.1.2+incompatible h1:5vjJMVhowQdPzjE1LdxyFF7YFTXg5IgGVW4gBr5IbvE= +github.com/go-bindata/go-bindata v3.1.2+incompatible/go.mod h1:xK8Dsgwmeed+BBsSy2XTopBn/8uK2HWuGSnA11C3Joo= +github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= +github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= +github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= +github.com/go-openapi/jsonpointer v0.17.0/go.mod h1:cOnomiV+CVVwFLk0A/MExoFMjwdsUdVpsRhURCKh+3M= +github.com/go-openapi/jsonpointer v0.19.2/go.mod h1:3akKfEdA7DF1sugOqz1dVQHBcuDBPKZGEoHC/NkiQRg= +github.com/go-openapi/jsonpointer v0.19.3 h1:gihV7YNZK1iK6Tgwwsxo2rJbD1GTbdm72325Bq8FI3w= +github.com/go-openapi/jsonpointer v0.19.3/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg= +github.com/go-openapi/jsonreference v0.17.0/go.mod h1:g4xxGn04lDIRh0GJb5QlpE3HfopLOL6uZrK/VgnsK9I= +github.com/go-openapi/jsonreference v0.19.0/go.mod h1:g4xxGn04lDIRh0GJb5QlpE3HfopLOL6uZrK/VgnsK9I= +github.com/go-openapi/jsonreference v0.19.2/go.mod h1:jMjeRr2HHw6nAVajTXJ4eiUwohSTlpa0o73RUL1owJc= +github.com/go-openapi/jsonreference v0.19.3 h1:5cxNfTy0UVC3X8JL5ymxzyoUZmo8iZb+jeTWn7tUa8o= +github.com/go-openapi/jsonreference v0.19.3/go.mod h1:rjx6GuL8TTa9VaixXglHmQmIL98+wF9xc8zWvFonSJ8= +github.com/go-openapi/spec v0.19.0/go.mod h1:XkF/MOi14NmjsfZ8VtAKf8pIlbZzyoTvZsdfssdxcBI= +github.com/go-openapi/spec v0.19.4 h1:ixzUSnHTd6hCemgtAJgluaTSGYpLNpJY4mA2DIkdOAo= +github.com/go-openapi/spec v0.19.4/go.mod h1:FpwSN1ksY1eteniUU7X0N/BgJ7a4WvBFVA8Lj9mJglo= +github.com/go-openapi/spec v0.19.8 h1:qAdZLh1r6QF/hI/gTq+TJTvsQUodZsM7KLqkAJdiJNg= +github.com/go-openapi/spec v0.19.8/go.mod h1:Hm2Jr4jv8G1ciIAo+frC/Ft+rR2kQDh8JHKHb3gWUSk= +github.com/go-openapi/swag v0.17.0/go.mod h1:AByQ+nYG6gQg71GINrmuDXCPWdL640yX49/kXLo40Tg= +github.com/go-openapi/swag v0.19.2/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk= +github.com/go-openapi/swag v0.19.5 h1:lTz6Ys4CmqqCQmZPBlbQENR1/GucA2bzYTE12Pw4tFY= +github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk= +github.com/go-openapi/swag v0.19.9 h1:1IxuqvBUU3S2Bi4YC7tlP9SJF1gVpCvqN0T2Qof4azE= +github.com/go-openapi/swag v0.19.9/go.mod h1:ao+8BpOPyKdpQz3AOJfbeEVpLmWAvlT1IfTe5McPyhY= +github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= +github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= +github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zVXpSg4= +github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= +github.com/golang/groupcache v0.0.0-20190129154638-5b532d6fd5ef/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= +github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= +github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= +github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= +github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= +github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= +github.com/gorilla/mux v1.7.4 h1:VuZ8uybHlWmqV03+zRzdwKL4tUnIp1MAQtp1mIFE1bc= +github.com/gorilla/mux v1.7.4/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= +github.com/gorilla/websocket v1.4.0/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ= +github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= +github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= +github.com/grpc-ecosystem/grpc-gateway v1.9.0/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= +github.com/hashicorp/golang-lru v0.5.4 h1:YDjusn29QI/Das2iO9M0BHnIbxPeyuCHsjMW+lJfyTc= +github.com/hashicorp/golang-lru v0.5.4/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4= +github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= +github.com/inconshreveable/mousetrap v1.0.0 h1:Z8tu5sraLXCXIcARxBp/8cbvlwVa7Z1NHg9XEKhtSvM= +github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= +github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo= +github.com/json-iterator/go v1.1.5/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= +github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= +github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= +github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q= +github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= +github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= +github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= +github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= +github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= +github.com/kr/pty v1.1.5/go.mod h1:9r2w37qlBe7rQ6e1fg1S/9xpWHSnaqNdHD3WcMdbPDA= +github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= +github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= +github.com/mailru/easyjson v0.0.0-20180823135443-60711f1a8329/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= +github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= +github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e h1:hB2xlXdHp/pmPZq0y3QnmWAArdw9PqbmotexnWx/FU8= +github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= +github.com/mailru/easyjson v0.7.1 h1:mdxE1MF9o53iCb2Ghj1VfWvh7ZOwHpnVG/xwXrV90U8= +github.com/mailru/easyjson v0.7.1/go.mod h1:KAzv3t3aY1NaHWoQz1+4F1ccyAH66Jk7yos7ldAVICs= +github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= +github.com/mattn/go-isatty v0.0.7/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= +github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= +github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= +github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= +github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= +github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= +github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= +github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= +github.com/oklog/ulid v1.3.1/go.mod h1:CirwcVhetQ6Lv90oh/F+FBtV6XMibvdAFo93nm5qn4U= +github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= +github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= +github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= +github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= +github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw= +github.com/prometheus/client_golang v0.9.3/go.mod h1:/TN21ttK/J9q6uSwhBd54HahCDft0ttaMvbicHlPoso= +github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= +github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= +github.com/prometheus/common v0.0.0-20181113130724-41aa239b4cce/go.mod h1:daVV7qP5qjZbuso7PdcryaAu0sAZbrN9i7WWcTMWvro= +github.com/prometheus/common v0.4.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= +github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= +github.com/prometheus/procfs v0.0.0-20190507164030-5867b95ac084/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= +github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU= +github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg= +github.com/russross/blackfriday/v2 v2.0.1 h1:lPqVAte+HuHNfhJ/0LC98ESWRz8afy9tM/0RK8m9o+Q= +github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= +github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0= +github.com/shurcooL/sanitized_anchor_name v1.0.0 h1:PdmoCO6wvbs+7yrJyMORt4/BmY5IYyJwS/kOiWx8mHo= +github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc= +github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= +github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM= +github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= +github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ= +github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= +github.com/spf13/cobra v1.0.0 h1:6m/oheQuQ13N9ks4hubMG6BnvwOeaJrqSPLahSnczz8= +github.com/spf13/cobra v1.0.0/go.mod h1:/6GTrnGXV9HjY+aR4k0oJ5tcvakLuG6EuKReYlHNrgE= +github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo= +github.com/spf13/pflag v1.0.3 h1:zPAT6CGy6wXeQ7NtTnaTerfKOsV6V6F8agHXFiazDkg= +github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= +github.com/spf13/viper v1.4.0/go.mod h1:PTJ7Z/lr49W6bUbkmS1V3by4uWynFiR9p7+dSq/yZzE= +github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= +github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= +github.com/stretchr/objx v0.2.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE= +github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= +github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= +github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= +github.com/swaggo/files v0.0.0-20190704085106-630677cd5c14/go.mod h1:gxQT6pBGRuIGunNf/+tSOB5OHvguWi8Tbt82WOkf35E= +github.com/swaggo/gin-swagger v1.2.0/go.mod h1:qlH2+W7zXGZkczuL+r2nEBR2JTT+/lX05Nn6vPhc7OI= +github.com/swaggo/swag v1.5.1/go.mod h1:1Bl9F/ZBpVWh22nY0zmYyASPO1lI/zIwRDrpZU+tv8Y= +github.com/swaggo/swag v1.6.7 h1:e8GC2xDllJZr3omJkm9YfmK0Y56+rMO3cg0JBKNz09s= +github.com/swaggo/swag v1.6.7/go.mod h1:xDhTyuFIujYiN3DKWC/H/83xcfHp+UE/IzWWampG7Zc= +github.com/throttled/throttled v1.0.0 h1:GQ7a1ilkYMXnZ6V0EG7RiU3qHk1k/kpXO/aIQQXPfEQ= +github.com/throttled/throttled v2.2.4+incompatible h1:aVKdoH/qT5Mo1Lm/678OkX2pFg7aRpHlTn1tfgaSKxs= +github.com/throttled/throttled v2.2.4+incompatible/go.mod h1:0BjlrEGQmvxps+HuXLsyRdqpSRvJpq0PNIsOtqP9Nos= +github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= +github.com/ugorji/go v1.1.4/go.mod h1:uQMGLiO92mf5W77hV/PUCpI3pbzQx3CRekS0kk+RGrc= +github.com/ugorji/go v1.1.5-pre/go.mod h1:FwP/aQVg39TXzItUBMwnWp9T9gPQnXw4Poh4/oBQZ/0= +github.com/ugorji/go/codec v0.0.0-20181022190402-e5e69e061d4f/go.mod h1:VFNgLljTbGfSG7qAOspJ7OScBnGdDN/yBr0sguwnwf0= +github.com/ugorji/go/codec v1.1.5-pre/go.mod h1:tULtS6Gy1AE1yCENaw4Vb//HLH5njI2tfCQDUqRd8fI= +github.com/urfave/cli v1.20.0 h1:fDqGv3UG/4jbVl/QkFwEdddtEDjh/5Ov6X+0B/3bPaw= +github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA= +github.com/urfave/cli/v2 v2.1.1 h1:Qt8FeAtxE/vfdrLmR3rxR6JRE0RoVmbXu8+6kZtYU4k= +github.com/urfave/cli/v2 v2.1.1/go.mod h1:SE9GqnLQmjVa0iPEY0f1w3ygNIYcIJ0OKPMoW2caLfQ= +github.com/urfave/cli/v2 v2.2.0 h1:JTTnM6wKzdA0Jqodd966MVj4vWbbquZykeX1sKbe2C4= +github.com/urfave/cli/v2 v2.2.0/go.mod h1:SE9GqnLQmjVa0iPEY0f1w3ygNIYcIJ0OKPMoW2caLfQ= +github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= +github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q= +github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= +github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= +go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= +go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= +go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0= +go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= +golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= +golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= +golang.org/x/crypto v0.0.0-20190611184440-5c40567a22f8/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= +golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= +golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= +golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= +golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= +golang.org/x/mod v0.2.0 h1:KU7oHjnv3XNWfa5COkzUifxZmxp1TyI7ImMXqFxLwvQ= +golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= +golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= +golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/net v0.0.0-20181005035420-146acd28ed58/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/net v0.0.0-20181114220301-adae6a3d119a/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/net v0.0.0-20181220203305-927f97764cc3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= +golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= +golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= +golang.org/x/net v0.0.0-20190522155817-f3200d17e092/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks= +golang.org/x/net v0.0.0-20190611141213-3f473d35a33a/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= +golang.org/x/net v0.0.0-20190613194153-d28f0bde5980/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= +golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= +golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297 h1:k7pJ2yAPLPgbskkFdhRCsA77k2fySZ1zf2zCjvQCiIM= +golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= +golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= +golang.org/x/net v0.0.0-20200625001655-4c5254603344 h1:vGXIOMxbNfDTk/aXCmfdLgkrSV+Z2tcbze+pEc3v5W4= +golang.org/x/net v0.0.0-20200625001655-4c5254603344/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= +golang.org/x/net v0.0.0-20200707034311-ab3426394381 h1:VXak5I6aEWmAXeQjA+QSZzlgNrpq9mjcfDemuexIKsU= +golang.org/x/net v0.0.0-20200707034311-ab3426394381/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= +golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= +golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20181228144115-9a3f9b0469bb/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20190610200419-93c9922d18ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20190616124812-15dcb6c0061f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= +golang.org/x/text v0.3.2 h1:tW2bmiBqwgJj/UpqtC8EpXEZVYOwU0yG4iWbprSVAcs= +golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= +golang.org/x/text v0.3.3 h1:cokOdA+Jmi5PJGXLlLllQSgYigAEfHXJAERHVMaCc2k= +golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= +golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= +golang.org/x/tools v0.0.0-20180221164845-07fd8470d635/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= +golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= +golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= +golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= +golang.org/x/tools v0.0.0-20190606050223-4d9ae51c2468/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= +golang.org/x/tools v0.0.0-20190611222205-d73e1c7e250b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= +golang.org/x/tools v0.0.0-20190614205625-5aca471b1d59 h1:QjA/9ArTfVTLfEhClDCG7SGrZkZixxWpwNCDiwJfh88= +golang.org/x/tools v0.0.0-20190614205625-5aca471b1d59/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= +golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= +golang.org/x/tools v0.0.0-20200626171337-aa94e735be7f h1:JcoF/bowzCDI+MXu1yLqQGNO3ibqWsWq+Sk7pOT218w= +golang.org/x/tools v0.0.0-20200626171337-aa94e735be7f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= +golang.org/x/tools v0.0.0-20200711155855-7342f9734a7d h1:F3OmlXCzYtG9YE6tXDnUOlJBzVzHF8EcmZ1yTJlcgIk= +golang.org/x/tools v0.0.0-20200711155855-7342f9734a7d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= +golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4= +golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= +google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= +google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= +google.golang.org/grpc v1.21.0/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= +gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= +gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/go-playground/assert.v1 v1.2.1/go.mod h1:9RXL0bg/zibRAgZUYszZSwO/z8Y/a8bDuhia5mkpMnE= +gopkg.in/go-playground/validator.v8 v8.18.2/go.mod h1:RX2a/7Ha8BgOhfk7j780h4/u/RRjR0eouCJSH80/M2Y= +gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo= +gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bli9HhUf9+ttbYbLASfIpnQbh74= +gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= +gopkg.in/yaml.v2 v2.2.2 h1:ZCJp+EgiOT7lHqUV2J862kp8Qj64Jo6az82+3Td9dZw= +gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= +gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= +gopkg.in/yaml.v2 v2.3.0 h1:clyUAQHOM3G0M3f5vQj7LuJrETvjVot3Z5el9nffUtU= +gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= +honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= diff --git a/internal/data/character.json b/internal/data/character.json new file mode 100644 index 0000000..cbd9c58 --- /dev/null +++ b/internal/data/character.json @@ -0,0 +1,66 @@ +{ + "appearance": [ + ["Aquiline", "Athletic", "Barrel-Chested", "Boney", "Brawny", "Brutish"], + ["Bullnecked", "Chiseled", "Coltish", "Corpulent", "Craggy", "Delicate"], + ["Furrowed", "Gaunt", "Gorgeous", "Grizzled", "Haggard", "Handsome"], + ["Hideous", "Lanky", "Pudgy", "Ripped", "Rosy", "Scrawny"], + ["Sinewy", "Slender", "Slumped", "Solid", "Square-Jawed", "Statuesque"], + ["Towering", "Trim", "Weathered", "Willowy", "Wiry", "Wrinkled"] + ], + "clothing": [ + ["Antique", "Battle-torn", "Bedraggled", "Blood-stained", "Ceremonial", "Dated"], + ["Decaying", "Eccentric", "Elegant", "Embroidered", "Exotic", "Fashionable"], + ["Flamboyant", "Food-stained", "Formal", "Frayed", "Frumpy", "Garish"], + ["Grimy", "Haute couture", "Lacey", "Livery", "Mud-stained", "Ostentatious"], + ["Oversized", "Patched", "Patterned", "Perfumed", "Practical", "Rumpled"], + ["Sigils", "Singed", "Tasteless", "Undersized", "Wine-stained", "Worn out"] + ], + "background": [ + ["Alchemist", "Begger-prince", "Blackmailer", "Bounty-hunter", "Chimney sweep", "Coin-clipper"], + ["Contortionist", "Counterfeiter", "Cultist", "Cutpurse", "Debt-collector", "Deserter"], + ["Fence", "Fortuneteller", "Galley slave", "Gambler", "Gravedigger", "Headsman"], + ["Hedge knight", "Highwayman", "Housebreaker", "Kidnapper", "Mad prophet", "Mountebank"], + ["Peddler", "Pit-fighter", "Poisoner", "Rat-catcher", "Scrivener", "Sellsword"], + ["Slave", "Smuggler", "Street performer", "Tatooist", "Urchin", "Usurer"] + ], + "items": [ + ["Animal Scent", "Bear Trap", "Bedroll", "Caltrops", "Chain (10 ft.)", "Chalk"], + ["Chisel", "Crowbar", "Fishing Net", "Glass Marbles", "Glue", "Grappling Hook"], + ["Grease", "Hacksaw", "Hammer", "Hand drill", "Horn", "Iron spikes"], + ["Iron tongs", "Lantern and Oil", "Large Sack", "Lockpicks (3)", "Manacles", "Medicine (3)"], + ["Metal file", "Rations (3)", "Rope (50 ft.)", "Steel wire", "Shovel", "Steel mirror"], + ["Ten Foot Pole", "Tinderbox", "Torch", "Vial of Acid", "Vial of Poison", "Waterskin"] + ], + "mannerism": [ + ["Anecdotes", "Breathy", "Chuckles", "Clipped", "Cryptic", "Deep voice"], + ["Drawl", "Enunciates", "Flowery speech", "Gravelly voice", "High formal", "Hypnotic"], + ["Interrupts", "Laconic", "Laughs", "Long pauses", "Melodious", "Monotone"], + ["Mumbles", "Narrates", "Overly casual", "Quaint sayings", "Rambles", "Random facts"], + ["Rapid-fire", "Rhyming", "Robotic", "Slow speech", "Speechifies", "Squeky"], + ["Street slang", "Stutters", "Talks to self", "Trails off", "Very loud", "Whispers"] + ], + "personality": [ + ["Bitter", "Brave", "Cautious", "Chipper", "Contrary", "Cowardly"], + ["Cunning", "Driven", "Entitled", "Gregarious", "Grumpy", "Heartless"], + ["Honor-bound", "Hotheaded", "Inquisitive", "Irascible", "Jolly", "Know-it-all"], + ["Lazy", "Loyal", "Menacing", "Mopey", "Nervous", "Protective"], + ["Righteous", "Rude", "Sarcastic", "Savage", "Scheming", "Serene"], + ["Spacey", "Stoic", "Stubborn", "Stuck-up", "Suspicious", "Wisecracking"] + ], + "physical_detail": [ + ["Acid scars", "Battle scars", "Birthmark", "Braided hair", "Brand mark", "Broken nose"], + ["Bronze skinned", "Burn scars", "Bushy eyebrows", "Curly hair", "Dark skinned", "Dreadlocks"], + ["Exotic accent", "Flogging scars", "Freckles", "Gold tooth", "Hoarse voice", "Huge beard"], + ["Long hair", "Matted hair", "Missing ear", "Missing teeth", "Mustache", "Muttonchops"], + ["Nine fingers", "Oiled hair", "One-eyed", "Pale skinned", "Piercings", "Ritual scars"], + ["Sallow skin", "Shaved head", "Sunburned", "Tangled hair", "Tatoos", "Topnot"] + ], + "feat": [ + "A +1 to all attack rolls", + "A single spell slot", + "Briarborn (Advantage on tracking, foraging, survival)", + "Fingersmith (Advantage on tinkering and picking locks or pockets)", + "Roofrunner (Advantage on climbing, leaping, or balancing)", + "Shadowjack (Advantage on moving silently or hiding in shadows)" + ] +} diff --git a/internal/data/city.json b/internal/data/city.json new file mode 100644 index 0000000..3e4356a --- /dev/null +++ b/internal/data/city.json @@ -0,0 +1,98 @@ +{ + "city_themes": [ + ["EXTERNAL","Aristocracy","Art","Bureaucracy","Castes","Catacombs"], + ["EXTERNAL","EXTERNAL","Crime families","Cruelty","EXTERNAL","EXTERNAL"], + ["EXTERNAL","Festivals","Feuds","Intrigue","Theme","Martial law"], + ["Meritocracy","EXTERNAL","Opulence","EXTERNAL","Pilgrimages","Piracy"], + ["Plutocracy","Poverty","Rituals","Slavery","Spices","Theocracy"], + ["Thievery","Trade","Tyranny","EXTERNAL","Wizardry","Xenophobia"] + ], + "city_events": [ + ["Assassination","Carnival","Conscription","Coronation","Coup","Cult activity"], + ["Curfew","Discovery","Earthquake","EXTERNAL","Fashion trend","Fire"], + ["Flood","Heavy fog","Heavy taxes","Holy day","Hysteria","Inquisition"], + ["Insurrection","Invasion","Jailbreak","Mass eviction","Mass pardon","Negotiations"], + ["Plague","Proclamation","Prohibition","Public games","Refugees","Rioting"], + ["Roundup","Scandal","Serial killer","Shortage","Tournament","Trial"] + ], + "district_themes": [ + ["Catacombs","EXTERNAL","Construction","Crafts","Criminality","Culture"], + ["Dining","Education","Entertainment","Finance","Foreigners","Ghettoes"], + ["Government","Graveyards","Green space","Industrialization","Judgement","Livestock"], + ["EXTERNAL","Marketplace","Memorials","Military","Opulence","Pollution"], + ["Poverty","Punishment","Religion","Science","Trade","Trash"], + ["EXTERNAL","EXTERNAL","Vices","EXTERNAL","Wizardry","Wonders"] + ], + "upper_class_buildings": [ + ["Academy","Alchemist","Archive","Art dealer","Barber","Bookbinder"], + ["Bookseller","Castle","Clockmaker","Clothier","Courthouse","Furrier"], + ["Gallery","Garden","Haberdashery","Jeweler","Law office","Locksmith"], + ["Lounge","Manor","Museum","Observatory","Opera house","Park"], + ["Physician","Printer","Public baths","Restaurant","Salon","Stables"], + ["Taxidermist","Temple","Tobacconist","Townhouse","Winery","Zoo"] + ], + "lower_class_buildings": [ + ["Apothecary","Asylum","Baker","Brewery","Butcher","Candlemaker"], + ["Catacombs","Cheesemaker","Criminal den","Curiosity shop","Dock","Fighting pit"], + ["Forge","Fortuneteller","Gambling hall","Leatherworks","Marketplace","Mason"], + ["Mill","Moneylender","Orphanage","Outfitter","Prison","Sewers"], + ["Shipyards","Shrine","Stockyard","Stonecarver","Tattooist","Tavern"], + ["Theater","Veterinarian","Warehouse","Watchtower","Weaver","Workshop"] + ], + "city_activities": [ + ["Abduct","Beg","Brawl","Burgle","Celebrate","Chase"], + ["Construct","Cook","Dance","Duel","EXTERNAL","Execute"], + ["Extinguish","Extort","Follow","Gamble","Haul","Interrogate"], + ["Marry","EXTERNAL","Mourn","Party","Patrol","Perform"], + ["Play","Preach","Process","Proclaim","Protest","Release"], + ["Repair","Riot","Rob","Search","Sell","EXTERNAL"] + ], + "building_rooms": [ + ["Arboretum","Atrium","Attic","Aviary","Ballroom","Baths"], + ["Bed chamber","Cabinet","Chapel","Cloakroom","Dining room","Dressing room"], + ["EXTERNAL","Garden","Garret","Greenhouse","Junk room","Kitchen"], + ["Larder","Library","Map room","Menagerie","Mews","Nursery"], + ["Pantry","Parlor","Privy","Root cellar","Saucery","Scullery"], + ["Smoking room","Spicery","Still room","Study","Trophy room","Wardrobe"] + ], + "tactical_street_features": [ + ["Arcade","Awnings","Balconies","Barricades","Bridge","Canal"], + ["Carriages","Catwalks","EXTERNAL","Climbable walls","Clotheslines","Crowd"], + ["Dead end","Dense fog","Downpour","EXTERNAL","Flooding","Food stalls"], + ["Fountain","Gates","Ladders","Livestock","Muddy","Overgrown"], + ["Roof access","Roof gardens","Sewer access","Sinkhole","Slick","Steep roofs"], + ["Steep streets","Steps","Torn up street","Vermin swarms","Well","EXTERNAL"] + ], + "tactical_building_features": [ + ["EXTERNAL","Balconies","Basement access","Brightly lit","Broken furniture","Broken glass"], + ["Cabinets","Carpeted floors","Chandeliers","Crawlspaces","Drain pipes","Dumbwaiters"], + ["Echoing marble","Hanging chains","Huge fireplace","Narrow ledges","Open windows","Ornate weapons"], + ["Overgrown","Patrols","Piles of trash","Pillars","Rotting ceiling","Rotting floors"], + ["Rotting walls","Screens","Servant passages","Sewer access","Shadowy alcoves","Skylights"], + ["Spyholes","Staircases","Tall bookshelves","Unlit","Watchdogs","Window drapes"] + ], + "factions": [ + ["Art movement","Beggar's guild","Black market","Brotherhood","City guard","Conspiracy"], + ["Craft guild","Crime family","Crime ring","Dark cult","Explorer's club","Free company"], + ["Gourmand club","Heist crew","Heretical sect","High council","Hired killers","Local militia"], + ["National church","Noble house","Outlander clan","Outlaw gang","Political party","Religious order"], + ["Religious sect","Resistance","Royal army","Royal house","Scholar's circle","Secret society"], + ["Spy network","Street artists","Street gang","Street musicians","Theater troupe","Trade company"] + ], + "faction_traits": [ + ["Bankrupt","Bureaucratic","Charitable","Confused","Connected","Corrupt"], + ["Decadent","Decaying","Delusional","Divided","Dwindling","Efficient"], + ["Esoteric","Expanding","Hunted","Incompetent","Incorruptible","Insane"], + ["Insular","Manipulative","Martial","EXTERNAL","Pious","Popular"], + ["Righteous","Ruthless","Secret","Subversive","Suppressed","Threatened"], + ["Thriving","Unpopular","Up-and-coming","Wealthy","Well-prepared","Xenophobic"] + ], + "faction_goals": [ + ["Advise leader","Avoid detection","Awaken being","Collect artifacts","Construct base","EXTERNAL"], + ["Control politics","Create artifact","EXTERNAL","EXTERNAL","Defend borders","Defend leader"], + ["Destroy artifacts","Destroy being","Destroy villain","Enforce law","Enrich members","Entertain"], + ["Exchange goods","Hear rumors","Indulge tastes","EXTERNAL","Map the wild","Overthrow order"], + ["Preserve lineage","Preserve lore","Produce goods","Promote arts","Promote craft","Purge traitors"], + ["Sell services","Share knowledge","Spread beliefs","Summon evil","Survive","Transport goods"] + ] +} diff --git a/internal/data/data.go b/internal/data/data.go new file mode 100644 index 0000000..b9210fc --- /dev/null +++ b/internal/data/data.go @@ -0,0 +1,209 @@ +package data + +import ( + "encoding/json" + "log" + "mazeratsgen/assets/bindata" +) + +type tableStruct struct { + Character characterTable + City cityTable + Magic magicTable + Maze mazeTable + Monster monsterTable + NPC npcTable + Treasure treasureTable + Wild wildTable +} + +var Tables = tableStruct{ + Character: CharacterTable(), + City: CityTable(), + Magic: MagicTable(), + Maze: MazeTable(), + Monster: MonsterTable(), + NPC: NPCTable(), + Treasure: TreasureTable(), + Wild: WildTable(), +} + +type characterTable struct { + Appearance [][]string `json:"appearance"` + Clothing [][]string `json:"clothing"` + Background [][]string `json:"background"` + Items [][]string `json:"items"` + Mannerism [][]string `json:"mannerism"` + Personality [][]string `json:"personality"` + PhysicalDetail [][]string `json:"physical_detail"` + Feat []string `json:"feat"` +} + +type cityTable struct { + CityThemes [][]string `json:"city_themes"` + CityEvents [][]string `json:"city_events"` + DistrictThemes [][]string `json:"district_themes"` + UpperClassBuildings [][]string `json:"upper_class_buildings"` + LowerClassBuildings [][]string `json:"lower_class_buildings"` + CityActivities [][]string `json:"city_activities"` + BuildingRooms [][]string `json:"building_rooms"` + TacticalStreetFeatures [][]string `json:"tactical_street_features"` + TacticalBuildingFeatures [][]string `json:"tactical_building_features"` + Factions [][]string `json:"factions"` + FactionTraits [][]string `json:"faction_traits"` + FactionGoals [][]string `json:"faction_goals"` +} + +type magicTable struct { + PhysicalEffects [][]string `json:"physical_effects"` + PhysicalElements [][]string `json:"physical_elements"` + PhysicalForms [][]string `json:"physical_forms"` + EtherealEffects [][]string `json:"ethereal_effects"` + EtherealElements [][]string `json:"ethereal_elements"` + EtherealForms [][]string `json:"ethereal_forms"` + Mutations [][]string `json:"mutations"` + Insanities [][]string `json:"insanities"` + Catastrophes [][]string `json:"catastrophes"` +} + +type mazeTable struct { + DungeonEntrances [][]string `json:"dungeon_entrances"` + DungeonForms [][]string `json:"dungeon_forms"` + DungeonLayout [][]string `json:"dungeon_layout"` + DungeonRuinations [][]string `json:"dungeon_ruinations"` + DungeonRewards [][]string `json:"dungeon_rewards"` + DungeonActivities [][]string `json:"dungeon_activities"` + DungeonRooms [][]string `json:"dungeon_rooms"` + DungeonRoomDetails [][]string `json:"dungeon_room_details"` + DungeonTricks [][]string `json:"dungeon_tricks"` + DungeonHazards [][]string `json:"dungeon_hazards"` + TrapEffects [][]string `json:"trap_effects"` + TrapTriggers [][]string `json:"trap_triggers"` +} + +type monsterTable struct { + Aerial [][]string `json:"aerial"` + Terrestrial [][]string `json:"terrestrial"` + Aquatic [][]string `json:"aquatic"` + Features [][]string `json:"features"` + Traits [][]string `json:"traits"` + Abilities [][]string `json:"abilities"` + Tactics [][]string `json:"tactics"` + Personality [][]string `json:"personality"` + Weakness [][]string `json:"weakness"` +} + +type npcTable struct { + CivilizedNPCs [][]string `json:"civilized_npcs"` + UnderworldNPCs [][]string `json:"underworld_npcs"` + WildernessNPCs [][]string `json:"wilderness_npcs"` + FemaleNames [][]string `json:"female_names"` + MaleNames [][]string `json:"male_names"` + UpperClassSurnames [][]string `json:"upper_class_surnames"` + LowerClassSurnames [][]string `json:"lower_class_surnames"` + Assets [][]string `json:"assets"` + Liabilities [][]string `json:"liabilities"` + NPCGoals [][]string `json:"npc_goals"` + Misfortunes [][]string `json:"misfortunes"` + Missions [][]string `json:"missions"` + Methods [][]string `json:"methods"` + Appearances [][]string `json:"appearances"` + PhysicalDetails [][]string `json:"physical_details"` + Clothing [][]string `json:"clothing"` + Personalities [][]string `json:"personalities"` + Mannerisms [][]string `json:"mannerisms"` + Secrets [][]string `json:"secrets"` + Reputations [][]string `json:"reputations"` + Hobbies [][]string `json:"hobbies"` + Relationships [][]string `json:"relationships"` + DivineDomains [][]string `json:"divine_domains"` + AfterTheParty [][]string `json:"after_the_party"` +} + +type treasureTable struct { + MiscItems [][]string `json:"misc_items"` + WornItems [][]string `json:"worn_items"` + WeaponItems [][]string `json:"weapon_items"` + BookSubjects [][]string `json:"book_subjects"` + ToolItems [][]string `json:"tool_items"` + Potions [][]string `json:"potions"` + MagicalIngredients [][]string `json:"magical_ingredients"` + TreasureItems [][]string `json:"treasure_items"` + TreasureTraits [][]string `json:"treasure_traits"` + ValuableMaterials [][]string `json:"valuable_materials"` +} + +type wildTable struct { + WildernessRegions [][]string `json:"wilderness_regions"` + WildernessRegionTraits [][]string `json:"wilderness_region_traits"` + WildernessLandmarks [][]string `json:"wilderness_landmarks"` + WildernessStructures [][]string `json:"wilderness_structures"` + WildernessDiscoveries [][]string `json:"wilderness_discoveries"` + WildernessActivities [][]string `json:"wilderness_activities"` + WildernessHazards [][]string `json:"wilderness_hazards"` + EdiblePlants [][]string `json:"edible_plants"` + PoisonousPlants [][]string `json:"poisonous_plants"` + InnAdjectives [][]string `json:"inn_adjectives"` + InnNouns [][]string `json:"inn_nouns"` + InnQuirks [][]string `json:"inn_quirks"` +} + +func CharacterTable() characterTable { + var table characterTable + unmarshalTable("character.json", &table) + return table +} + +func CityTable() cityTable { + var table cityTable + unmarshalTable("city.json", &table) + return table +} + +func MagicTable() magicTable { + var table magicTable + unmarshalTable("magic.json", &table) + return table +} + +func MazeTable() mazeTable { + var table mazeTable + unmarshalTable("maze.json", &table) + return table +} + +func MonsterTable() monsterTable { + var table monsterTable + unmarshalTable("monster.json", &table) + return table +} + +func NPCTable() npcTable { + var table npcTable + unmarshalTable("npc.json", &table) + return table +} + +func TreasureTable() treasureTable { + var table treasureTable + unmarshalTable("treasure.json", &table) + return table +} + +func WildTable() wildTable { + var table wildTable + unmarshalTable("wild.json", &table) + return table +} + +func unmarshalTable(path string, table interface{}) { + asset, err := bindata.Asset(path) + if err != nil { + log.Fatal(err) + } + + err = json.Unmarshal(asset, &table) + if err != nil { + log.Fatal(err) + } +} diff --git a/internal/data/magic.json b/internal/data/magic.json new file mode 100644 index 0000000..930559e --- /dev/null +++ b/internal/data/magic.json @@ -0,0 +1,74 @@ +{ + "physical_effects": [ + ["Animating","Attracting","Binding","Blossoming","Consuming","Creeping"], + ["Crushing","Diminishing","Dividing","Duplicating","Enveloping","Expanding"], + ["Fusing","Grasping","Hastening","Hindering","Illuminating","Imprisoning"], + ["Levitating","Opening","Petrifying","Phasing","Piercing","Pursuing"], + ["Reflecting","Regenerating","Rending","Repelling","Resurrecting","Screaming"], + ["Sealing","Shapeshifting","Shielding","Spawning","Transmuting","Transporting"] + ], + "physical_elements": [ + ["Acid","Amber","Bark","Blood","Bone","Brine"], + ["Clay","Crow","Crystal","Ember","Flash","Fungus"], + ["Glass","Honey","Ice","Insect","Wood","Lava"], + ["Moss","Obsidian","Oil","Poison","Rat","Salt"], + ["Sand","Sap","Serpent","Slime","Stone","Tar"], + ["Thorn","Vine","Water","Wine","Wood","Worm"] + ], + "physical_forms": [ + ["Altar","Armor","Arrow","Beast","Blade","Cauldron"], + ["Chain","Chariot","Claw","Cloak","Colossus","Crown"], + ["Elemental","Eye","Fountain","Gate","Golem","Hammer"], + ["Horn","Key","Mask","Monolith","Pit","Prison"], + ["Sentinel","Servant","Shield","Spear","Steed","Swarm"], + ["Tentacle","Throne","Torch","Trap","Wall","Web"] + ], + "ethereal_effects": [ + ["Avenging","Banishing","Bewildering","Blinding","Charming","Communicating"], + ["Compelling","Concealing","Deafening","Deceiving","Deciphering","Disguising"], + ["Dispelling","Emboldening","Encoding","Energizing","Enlightening","Enraging"], + ["Excruciating","Foreseeing","Intoxicating","Maddening","Mesmerizing","Mindreading"], + ["Nullifying","Paralyzing","Revealing","Revolting","Scrying","Silencing"], + ["Soothing","Summoning","Terrifying","Warding","Wearying","Withering"] + ], + "ethereal_elements": [ + ["Ash","Chaos","Distortion","Dream","Dust","Echo"], + ["Ectoplasm","Fire","Fog","Ghost","Harmony","Heat"], + ["Light","Lightening","Memory","Mind","Mutation","Negation"], + ["Plague","Plasma","Probability","Rain","Rot","Shadow"], + ["Smoke","Snow","Soul","Star","Stasis","Steam"], + ["Thunder","Time","Void","Warp","Whisper","Wind"] + ], + "ethereal_forms": [ + ["Aura","Beacon","Beam","Blast","Blob","Bolt"], + ["Bubble","Call","Cascade","Circle","Cloud","Coil"], + ["Cone","Cube","Dance","Disk","Field","Form"], + ["Gaze","Loop","Moment","Nexus","Portal","Pulse"], + ["Pyramid","Ray","Shard","Sphere","Spray","Storm"], + ["Swarm","Torrent","Touch","Vortex","Wave","Word"] + ], + "mutations": [ + ["Ages","Attracts birds","Child-form","Corpulence","Covered in hair","EXTERNAL"], + ["EXTERNAL","EXTERNAL","EXTERNAL","EXTERNAL","EXTERNAL","EXTERNAL"], + ["Cyclops","Extra arms","Extra eyes","Extra legs","Forked tongue","Gender swap"], + ["Hunchback","EXTERNAL","Long arms","Lose all hair","Loses teeth","EXTERNAL"], + ["EXTERNAL","No eyes","No mouth","EXTERNAL","Second face","Sheds skin"], + ["Shrinks","Shrivels","Skin boils","Slime trail","Translucent skin","Weeps blood"] + ], + "insanities": [ + ["Always lies","Always polite","EXTERNAL","Cannot count","Cannot lie","Faceblind"], + ["Fears birds","Fears blood","Fears books","Fears darkness","Fears fire","Fears gold"], + ["Fears horses","Fears iron","Fears music","Fears own hand","Fears PC","Fears rain"], + ["Fears rivers","Fears silence","Fears sleep","Fears sunlight","Fears the moon","Fears trees"], + ["EXTERNAL","'Gorgeous'","Hates violence","'Invisible'","'Invulnerable'","EXTERNAL"], + ["'EXTERNAL'","'EXTERNAL'","Must sing","EXTERNAL","Says thoughts","See dead people"] + ], + "catastrophes": [ + ["All iron rusts","Animals die","EXTERNAL","Birds attack","City appears","Deadly fog"], + ["Dream plague","Endless night","Endless rain","Endless storm","Endless twilight","Endless winter"], + ["Fae return","Forest appears","Forgetfulness","Graves open","Lamentations","Maggots"], + ["EXTERNAL","EXTERNAL","Mass slumber","Meteor strike","Mirrors speak","No stars"], + ["Outsider enters","People shrink","People vanish","Plants wither","Portal opens","Rifts open"], + ["Shadows speak","Space distorts","Stones speak","Total silence","Tower appears","Water to blood"] + ] +} diff --git a/internal/data/maze.json b/internal/data/maze.json new file mode 100644 index 0000000..44f3ce7 --- /dev/null +++ b/internal/data/maze.json @@ -0,0 +1,98 @@ +{ + "dungeon_entrances": [ + ["All libraries","Beaver dam","Behind waterfall","Chalk rectangle","Chest bottom ","Chimney"], + ["Cupboard","Dolmen shadow","Down a well","Fiery pit","Fog road","Forest spring "], + ["Giant book","Gypsy wagon","Hollow tree","Huge keyhole","Iron maiden","Living tattoo"], + ["Magic painting","Man-shape hole","Maze potion","Mirror","Monster mouth","Monster wound"], + ["Narrow alley","Rain door","Sewer grate","Sudden rift","Tidal cave","Towertop"], + ["Tree roots","Under the bed","Unfolded map","Up a tree","Whirlpool","Wine barrel"] + ], + "dungeon_forms": [ + ["Arena","Asylum","Aviary","Bank","Baths","Body"], + ["EXTERNAL","Casino","Catacombs","Cave","Court","EXTERNAL"], + ["Room","Garden","Hideout","Hotel","EXTERNAL","Laboratory"], + ["Library","Market","Mine","Monastery","Museum","Nursery"], + ["Orphanage","Palace","Prison","Sewer","Ship","Slave pit"], + ["Temple","Theater","EXTERNAL","University","Vault","Zoo"] + ], + "dungeon_layout": [ + ["Ant colony","Central hub","Claustrophobic","Crisscrossing","Curved","Disorienting"], + ["Galleria","Geometric","Gonzo","Haphazard","Highly regular","Honeycomb"], + ["Intertwined","Isolated wings","Layered","Linear","Loops","Many corridors"], + ["Mazes","Mix of layouts","Multiple hubs","No corridors","Open plan","Open voids"], + ["Organic","Oversized","Recursive","Repetitive","Sprawling","Suspended"], + ["Symbol shape","Tall and narrow","Themed zones","Vertical","Winding","Ziggurat"] + ], + "dungeon_ruinations": [ + ["Arcane disaster","Army invasion","Cannibalism","Civil war","Collapse","Crystal growth"], + ["Curse","Degeneration","Earthquake","Eruption","Evil unearthed","Experiments"], + ["Explosion","Famine","Fire","Flooding","Fungus","Haunting"], + ["Ice","EXTERNAL","Lava flow","Magical sleep ","Melted","Monster attack"], + ["EXTERNAL","Outsider attack","Overgrowth","Petrification ","Plague","Planar overlay"], + ["Poison gas","Resources gone","Revolt","Risen dead","Too many traps","War"] + ], + "dungeon_rewards": [ + ["Ancient lore","Animal ally","Army","Blessing","Blueprints","Cultural artifact"], + ["Enemy weakness","Faction ally","Forewarning","Guide","Holy relic","Influential ally"], + ["Instructions","Jewels","Key","Lost formula","Machine","EXTERNAL"], + ["Magical ally","Map","Marital ally","Masterpiece","EXTERNAL","Oracle"], + ["Piles of loot","Planar portal","Prophecy","Renown","Spell","Transformation"], + ["Transport","EXTERNAL","Uncovered plot","EXTERNAL","Vision","Weapon"] + ], + "dungeon_activities": [ + ["Besiege","Capture","EXTERNAL","Collect","Construct","Control"], + ["Deliver","Demolish","Escape","Feed","Fortify","Guard monster"], + ["Hide","Hunt","Loot","Map","Mine","EXTERNAL"], + ["Negotiate","Patrol","Perform ritual","Purge","Question","Raid"], + ["Repair","Rescue","Research","Revive","Riddle","Scavenge"], + ["Seize","Tunnel","Unearth","Vandalize","EXTERNAL","Worship"] + ], + "dungeon_rooms": [ + ["Armory","Banquet hall","Barracks","EXTERNAL","Catacombs","Cavern"], + ["Chasm","Courtyard","Crypt","Dormitory","Fighting pit","Forge"], + ["Fountain","Gate house","Guard room","Kennel","EXTERNAL","Laboratory"], + ["Mess hall","Mine shaft","Museum","Oubliette","Pool","Prison"], + ["Record room","Shrine","Slaughterhouse","Stables","Storeroom","Throneroom"], + ["Torture room","Treasury","EXTERNAL","Vault","Well","Workshop"] + ], + "dungeon_room_details": [ + ["Bas-relief","Blood trail","Bones","Chains","Chalk marks","Claw marks"], + ["Corpses","Cracked beams","Crumbling walls","Decaying food ","Decaying nest ","Dripping water"], + ["Fading murals","Faint breeze","Faint footsteps","Fallen pillars","Fungus","Furniture"], + ["Graffiti","Mosaics","Recent repairs","Rotting books","Rubble","Shed skin"], + ["Slime trails","Spider webs","Stalactites","Stench","Smoke stains","Thick dust"], + ["Torn clothes","Tree roots","Unusual smell","Vibrations","Vines","Whispers"] + ], + "dungeon_tricks": [ + ["Absorption","Activation","Animation","Blessings","Communication","Confusion"], + ["Consumption","Creation","Curses","Deception","Duplication","EXTERNAL"], + ["Exchange","Imprisonment","Instructions","Interrogation","Mind-control","EXTERNAL"], + ["Mood-alteration","Nullification","EXTERNAL","Planeshift","Protection","Rejuvenation"], + ["Release","Reversal","Rotation","Scrying","Size-alteration","Summoning"], + ["Theft","Time-alteration","Transformation","Transmutation","Transportation","Wonder"] + ], + "dungeon_hazards": [ + ["Acid drip","Bloodsuckers","Cave-in","Choking dust","Crude oil","Crystal shards"], + ["Deafening noise","Dense fog","Ensnaring vines","Fallen floor","Flooding","Freezing"], + ["Geysers","Magma","Magnetic field","Mud flow","Narrow ledge","Narrow passage"], + ["Poison goo","Poison plants","Precipice","Quicksand","Radiation","Rockslide"], + ["Rotten ceiling","Rotten floor","Sinkhole","Slippery slope","Spider webs","Spores"], + ["Steam vents","Strong winds","Tar pit","Tight passage","Toppling object","Toxic fumes"] + ], + "trap_effects": [ + ["Acid pool","Adhesive","Alarm","Armor melts","Bear trap","Blinding spray"], + ["Blunt pendulum","Boiling tar","Collapsing floor","Crocodile pit","Crushing walls","Deep pit"], + ["Falling cage","Falling ceiling","Fills with sand","Flooding","Giant magnet","Hard vacuum"], + ["Lava flow","Lightning","Living statues","Missile fire","Monster freed","Net trap"], + ["Pendulum blade","Poison gas","Poison needle","Quicksand","Rage gas","Rolling boulder"], + ["Room freezes","Room on fire","Sleeping gas","Spiked pit","Tombs open","Wall spikes"] + ], + "trap_triggers": [ + ["Blow","Break","Burn","Choice","Countdown","Darkness"], + ["Drain","Eat","Insert","Kill","Knock","Light"], + ["Magic","Melody","Noise","Open","Phrase","Pour"], + ["Press","Proximity","Pull","Read","Reflect","Release"], + ["Remove","Retrieve","Rudeness","Shut","Sit","Sleep"], + ["Slide","Touch","Turn","Unbalance","Unearth","Write"] + ] +} diff --git a/internal/data/monster.json b/internal/data/monster.json new file mode 100644 index 0000000..36b767b --- /dev/null +++ b/internal/data/monster.json @@ -0,0 +1,74 @@ +{ + "aerial": [ + ["Albatross", "Bat", "Beetle", "Bird of Paradise", "Butterfly", "Condor"], + ["Crane", "Crow", "Dragonfly", "Eagle", "Falcon", "Firefly"], + ["Flamingo", "Fly", "Flying Squirrel", "Goose", "Gull", "Hummingbird"], + ["Kingfisher", "Locust", "Magpie", "Mantis", "Mockingbird", "Mosquito"], + ["Moth", "Owl", "Parrot", "Peacock", "Pelican", "Pteranodon"], + ["Rooster", "Sparrow", "Swan", "Vulture", "Wasp", "Woodpecker"] + ], + "terrestrial": [ + ["Ant", "Ape", "Armadillo", "Badger", "Bear", "Boar"], + ["Caterpillar", "Centipede", "Chameleon", "Cockroach", "Deer", "Elephant"], + ["Ferret", "Fox", "Giraffe", "Goat", "Horse", "Human"], + ["Mole", "Ostrich", "Ox", "Porcupine", "Rabbit", "Raccoon"], + ["Rat", "Rhinoceros", "Scorpion", "Sheep", "Slug", "Snail"], + ["Snake", "Spider", "Squirrel", "Tiger", "Wolf", "Wolverine"] + ], + "aquatic": [ + ["Alligator", "Amoeba", "Anglerfish", "Beaver", "Clam", "Crab"], + ["Dolphin", "Eel", "Frog", "Hippopotamus", "Jellyfish", "Leech"], + ["Lobster", "Manatee", "Manta Ray", "Muskrat", "Narwhal", "Newt"], + ["Octopus", "Otter", "Penguin", "Platypus", "Pufferfish", "Salamander"], + ["Sea Anemone", "Sea Urchin", "Seahorse", "Seal", "Shark", "Shrimp"], + ["Squid", "Swordfish", "Tadpole", "Turtle", "Walrus", "Whale"] + ], + "features": [ + ["Antlers", "Beak", "Carapace", "Claws", "Compound eyes", "Eye Stalks"], + ["Fangs", "Fins", "Fur", "Gills", "Hooves", "Horns"], + ["Legless", "Long tongue", "Many-eyed", "Many-limbed", "Mucus", "Pincers"], + ["Plates", "Plumage", "Proboscis", "Scales", "Segments", "Shaggy hair"], + ["Shell", "Spikes", "Spinnerets", "Spines", "Stinger", "Suction cups"], + ["Tail", "Talons", "Tentacles", "Trunk", "Tusks", "Wings"] + ], + "traits": [ + ["Amphibious", "Bloated", "Brittle", "Cannibal", "Clay-like", "Colossal"], + ["Crystalline", "Decaying", "EXTERNAL", "Ethereal", "Ever-young", "Eyeless"], + ["Fearless", "Fluffy", "Fungal", "Gelatinous", "Geometric", "Hardened"], + ["Illusory", "Intelligent", "Iridescent", "Luminous", "Many-headed", "Mechanical"], + ["EXTERNAL", "Planar", "Reflective", "Rubbery", "Shadowy", "Sharp"], + ["Skeletal", "Slimy", "Sticky", "Stinking", "Tiny", "Translucent"] + ], + "abilities": [ + ["Absorbing", "Acid blood", "Anti-magic", "Blinding", "Breath weapon", "Camouflaging"], + ["Duplicating", "Electric", "Entangling", "EXTERNAL", "Exploding", "Flying"], + ["Gaze weapon", "Hypnotizing", "Impervious", "Invisible", "Life-draining", "Magnetic"], + ["Mimicking", "Mind-Reading", "Paralyzing", "Phasing", "EXTERNAL", "Poisonous"], + ["Radioactive", "Reflective", "Regenerating", "Shapeshifting", "Spell-casting", "Stealthy"], + ["Strangling", "Super-strength", "Telekinetic", "Teleporting", "Vampiric", "Wall-Crawling"] + ], + "tactics": [ + ["Ambush", "Call for support", "Capture", "Charge", "Climb foes", "Compel worship"], + ["Create barrier", "Deceive", "Demand duel", "Disorient", "Encircle", "Evade"], + ["Gang up", "Gather strength", "Go berserk", "Harry", "Hurl foes", "Immobilize"], + ["Manipulate", "Mock", "Monologue", "Order minion", "Protect leader", "Protect self"], + ["Scatter foes", "Stalk", "Steal from", "Swarm", "Target insolent", "Target leader"], + ["Target nearest", "Target richest", "Target strongest", "Target weakest", "Toy with", "Use terrain"] + ], + "personality": [ + ["Alien", "Aloof", "Bored", "Cautious", "Cowardly", "Curious"], + ["Devious", "Distractible", "Educated", "Embittered", "Envious", "Erudite"], + ["Fanatical", "Forgetful", "Generous", "Hateful", "Honorable", "Humble"], + ["Jaded", "Jovial", "Legalistic", "Manipulative", "Megalomaniac", "Melancholy"], + ["Meticulous", "Mystical", "Obsessive", "Out of Touch", "Paranoid", "Polite"], + ["Psychopathic", "Sophisticated", "Touchy", "Unimpressed", "Vain", "Xenophobic"] + ], + "weakness": [ + ["Bells", "Birdsong", "Children", "Cold", "Cold Iron", "Competition"], + ["Conversation", "Deformity", "Flattery", "Flowers", "Gifts", "Gold"], + ["Heat", "Holy Icon", "Holy Water", "Home Cooking", "EXTERNAL", "Mirrors"], + ["Mistletoe", "Moonlight", "Music", "EXTERNAL", "Phylactery", "EXTERNAL"], + ["Puzzles", "Riddles", "Rituals", "Silver", "Sunlight", "Tears"], + ["True Name", "EXTERNAL", "Weak Spot", "EXTERNAL", "Wine", "Wormwood"] + ] +} diff --git a/internal/data/npc.json b/internal/data/npc.json new file mode 100644 index 0000000..158e876 --- /dev/null +++ b/internal/data/npc.json @@ -0,0 +1,194 @@ +{ + "civilized_npcs": [ + ["Acolyte","Actor","Apothecary","Baker","Barber","Blacksmith"], + ["Brewer","Bureaucrat","Butcher","Carpenter","Clockmaker","Courier"], + ["Courtier","Diplomat","Fishmonger","Guard","Haberdasher","Innkeeper"], + ["Item-seller","Jeweler","Knight","Locksmith","Mason","Miller"], + ["Musician","Noble","Painter","Priest","Scholar","Scribe"], + ["Sculptor","Shipwright","Soldier","Tailor","Taxidermist","Wigmaker"] + ], + "underworld_npcs": [ + ["Alchemist","Beggar-prince","Blackmailer","Bounty-hunter","Chimney sweep","Coin-clipper"], + ["Contortionist","Counterfeiter","Cultist","Cutpurse","Debt-collector","Deserter"], + ["Fence","Fortuneteller","Galley slave","Gambler","Gravedigger","Headsman"], + ["Hedge knight","Highwayman","Housebreaker","Kidnapper","Mad prophet","Mountebank"], + ["Peddler","Pit-fighter","Poisoner","Rat-catcher","Scrivener","Sellsword"], + ["Slave","Smuggler","Street performer","Tattooist","Urchin","Usurer"] + ], + "wilderness_npcs": [ + ["Apiarist","Bandit","Caravan Guard","Caravaneer","Druid","Exile"], + ["Explorer","Farmer","Fisherman","Forager","Fugitive","Hedge wizard"], + ["Hermit","Hunter","Messenger","Minstrel","Monk","Monster hunter"], + ["Outlander","Tinker","Pilgrim","Poacher","Raider","Ranger"], + ["Sage","Scavenger","Scout","Shepherd","Seer","Surveyor"], + ["Tinker","Tomb raider","Trader","Trapper","Witch","Woodcutter"] + ], + "female_names": [ + ["Adelaide","Alma","Barsaba","Beatrix","Bianca","Cleopha"], + ["Clover","Constance","Damaris","Daphne","Demona","Elsbeth"], + ["Esme","Fern","Hester","Hippolyta","Jessamine","Jilly"], + ["Morgot","Minerva","Nerissa","Odette","Olga","Orchid"], + ["Pepper","Phoebe","Piety","Poppy","Silence","Sybil"], + ["Trillby","Tuesday","Ursula","Vivian","Wendy","Zora"] + ], + "male_names": [ + ["Balthazar","Basil","Bertram","Blaxton","Chadwick","Clovis"], + ["Destrian","Ellis","Erasmus","Faustus","Finn","Fitzhugh"], + ["Florian","Fox","Godwin","Hannibal","Jasper","Jiles"], + ["Jules","Leopold","Merrick","Mortimer","Ogden","Orion"], + ["Oswald","Percival","Peregrine","Quentin","Redmaine","Reinhold"], + ["Silas","Stilton","Stratford","Tenpiece","Waverly","Webster"] + ], + "upper_class_surnames": [ + ["Belvedere","Bithesea","Calaver","Carvolo","De Rippe","Droll"], + ["Dunlow","Edevane","Erelong","Febland","Fernsby","Fisk"], + ["Gastrell","Girdwood","Gorgon","Grimeson","Gruger","Hitheryon"], + ["La Marque","Malmora","Miter","Oblington","Onymous","Phillifent"], + ["Protendorfer","Romatet","Rothery","Shorbeck","Slora","Southark"], + ["","","","","",""] + ], + "lower_class_surnames": [ + ["Barrow","Beetleman","Berrycloth","Birdwhistle","Bobich","Chips"], + ["Coffin","Crumpling","Culpepper","Dankwork","Digworthy","Dreggs"], + ["Gimble","Graveworm","Greelish","Hardwick","Hatman","Hovel"], + ["Knibbs","Midnighter","Needle","Nethercoat","Pestle","Relish"], + ["Rumbold","Rummage","Sallow","Saltmarsh","Silverless","Skitter"], + ["Slee","Slitherly","Stoker","Tarwater","Tumbler","Villin"] + ], + "assets": [ + ["Authority","Avoids detection","Calls in favors","Charming","Cooks the books","Erases evidence"], + ["Excellent liar","Extremely rich","EXTERNAL","EXTERNAL","Feared","Fortified base"], + ["Gorgeous","Hears rumors","Huge family","Huge library","Impersonator","Interrogator"], + ["Knows a guy","Knows a way in","Launder money","Learned","Local celebrity", "Local knowledge"], + ["Loyal henchman","Middling oracle","Nothing to lose","Owns the guards","Powerful spouse","Procures gear"], + ["Pulls the string","Secret lab","Sells contraband","Smuggles goods","Spy network","War hero"] + ], + "liabilities": [ + ["Addiction","Alcoholic","Corrupt ally","Coward","Decadent","Forbidden love"], + ["Gambler","Glutton","Greedy","Heretic","Huge debts","Imposter"], + ["EXTERNAL","Jealous","Leave evidence","Many enemies","Misinformed","Money trail"], + ["Narcissist","Needs medicine","OCD","Paranoid","Partier", "Poor equipment"], + ["Protective","Scandalous","Softhearted","Strict routines","Superstitious","Suspicious"], + ["Temper","Trusting","Vulnerable base","Wanted","Weak-willed","Wildly despised"] + ], + "npc_goals": [ + ["A better life","Acceptance","EXTERNAL","EXTERNAL","EXTERNAL","EXTERNAL"], + ["Enlightenment","Fame","EXTERNAL","Freedom","Glory","EXTERNAL"], + ["Infamy","Infiltrate FACTION","Justice","EXTERNAL","EXTERNAL","Learning"], + ["EXTERNAL","Love","Mastery","Power","Read location", "EXTERNAL"], + ["Resolve dispute","EXTERNAL","Reveal a secret","Revenge","EXTERNAL","Serve a deity"], + ["Serve evil","EXTERNAL","Serve ideology","Serve leader","Serve the needy","Wealth"] + ], + "misfortunes": [ + ["Abandoned","Addicted","Arrested","Blackmailed","Burgled","Challenged"], + ["Condemned","Crippled","Cursed","Defrauded","Demoted","Depressed"], + ["Discredited","Dismissed","Disowned","Exiled","Famished","Forgotten"], + ["Framed","Haunted","Humiliated","Impoverished","Kidnapped", "Lost"], + ["Mobbed","Mutilated","Overworked","Poisoned","Pursued","Rejected"], + ["Replaced","Robbed","Sick","Sued","Suspected","Transformed"] + ], + "missions": [ + ["Apprehend","Assassinate","Blackmail","Burgle","Chart","Convince"], + ["Deface","Defraud","Deliver","Destroy","Discredit","Escort"], + ["Exfiltrate","Extort","Follow","Frame","Impersonate","Impress"], + ["Infiltrate","Interrogate","Investigate","Kidnap","Locate", "Plant"], + ["Protect","Raid","Replace","Retrieve","Rob","Ruin"], + ["Sabotage","Smuggle","Surveil","Take Over","Terrorize","Threaten"] + ], + "methods": [ + ["Alchemy","Blackmail","Bluster","Bribery","Bullying","Bureaucracy"], + ["Charm","Commerce","Cronies","Debate","Deceit","Deduction"], + ["Eloquence","Espionage","Fast-talking","Favors","Hard Work","Humour"], + ["Investigation","Legal maneuvers","Manipulation","Misdirection","Money","Nagging"], + ["Negotiation","Persistence","Piety","Preparation","Quick Wit","Research"], + ["Rumors","Sabotage","Teamwork","Theft","Threats","Violence"] + ], + "appearances": [ + ["Aquiline","Athletic","Barrel-Chested","Boney","Brawny","Brutish"], + ["Bullnecked","Chiseled","Coltish","Corpulent","Craggy","Delicate"], + ["Furrowed","Gaunt","Gorgeous","Grizzled","Haggard","Handsome"], + ["Hideous","Lanky","Pudgy","Ripped","Rosy","Scrawny"], + ["Sinewy","Slender","Slumped","Solid","Square-Jawed","Statuesque"], + ["Towering","Trim","Weathered","Willowy","Wiry","Wrinkled"] + ], + "physical_details": [ + ["Acid scars","Battlescars","Birthmark","Braided hair","Brand mark","Broken nose"], + ["Bronze skinned","Burn cars","Bushy eyebrows","Curly hair","Dark skinned","Dreadlocks"], + ["Exotic accent","Flogging scars","Freckles","Gold tooth","Hoarse voice","Huge beard"], + ["Long hair","Matted hair","Missing ear","Missing teeth","Mustache","Muttonchops"], + ["Nine fingers","Oiled hair","One-eyed","Pale skinned","Piercings","Ritual scars"], + ["Sallow skin","Shaved head","Sunburned","Tangled hair","Tattoos","Topknot"] + ], + "clothing": [ + ["Antique","Battle-torn","Bedraggled","Blood-stained","Ceremonial","Dated"], + ["Decaying","Eccentric","Elegant","Embroidered","Exotic","Fashionable"], + ["Flamboyant","Food-stained","Formal","Frayed","Frumpy","Garish"], + ["Grimy","Haute couture","Lacey","Livery","Mud-stained","Ostentatious"], + ["Oversized","Patched","Patterned","Perfumed","Practical","Rumpled"], + ["Sigils","Singed","Tasteless","Undersized","Wine-stained","Worn out"] + ], + "personalities": [ + ["Antique","Battle-torn","Bedraggled","Blood-stained","Ceremonial","Dated"], + ["Decaying","Eccentric","Elegant","Embroidered","Exotic","Fashionable"], + ["Flamboyant","Food-stained","Formal","Frayed","Frumpy","Garish"], + ["Grimy","Haute couture","Lacey","Livery","Mud-stained","Ostentatious"], + ["Oversized","Patched","Patterned","Perfumed","Practical","Rumpled"], + ["Sigils","Singed","Tasteless","Undersized","Wine-stained","Worn out"] + ], + "mannerisms": [ + ["Anecdotes","Breathy","Chuckles","Clipped","Cryptic","Deep voice"], + ["Drawl","Enunciates","Flowery speech","Gravelly voice","Highly formal","Hypnotic"], + ["Interrupts","Laconic","Laughs","Long pauses","Melodious","Monotone"], + ["Mumbles","Narrates","Overly casual","Quaint sayings","Rambles","Random facts"], + ["Rapid-fire","Rhyming","Robotic","Slow speech","Speechifies","Squeaky"], + ["Street slang","Stutters","Talks to self","Trails off","Very loud","Whispers"] + ], + "secrets": [ + ["Addicted","Artificial","Assassin","Bankrupt","Beholden","Counterspy"], + ["Cultist","Demigod","Evil lineage","Exile","Fence","Fugitive"], + ["Ghost","Has a child","Heretic","High born","Huge fortune","Illusion"], + ["Insurrectionist","Low born","Married","Mind-controlled","EXTERNAL","Monster hunter"], + ["Non-human","EXTERNAL","Polygamist","Protects relic","Scandalous birth","Secret police"], + ["Serial killer","Smuggler","Spy","Time traveler","Transformed","War criminal"] + ], + "reputations": [ + ["Ambitious","Authoritative","Boor","Borrower","Celebrity","Charitable"], + ["Cheat","Dangerous","Entertainer","Gossip","Hardworking","Holy"], + ["Honest","Hypochondriac","Idiot","Influential","Layabout","Leader"], + ["Misanthrope","Miser","Neighborly","Nutjob","Obnoxious","Overeducated"], + ["Partier","Pious","Proper","Prophet of doom","Repulsive","Respected"], + ["Riffraff","Scandalous","Slime ball","Terrifying","Weirdo","Wise"] + ], + "hobbies": [ + ["Archaeology","Art collecting","Bad fiction","Calligraphy","Card games","Clockwork"], + ["Collecting cats","Cuisine","Dark lore","Dog breeding","Embroidery","Exercise"], + ["Falconry","Fashion","Fishing","Foreign cultures","Gardening","History"], + ["Horseracing","Hunting","Instrument","Knitting","Lawn games","Mountaineering"], + ["Opera","Painting","Poetry","Puzzle-solving","Riddling","Science"], + ["Sculpture","Sketching","Smoking","Theater","Weaving","Whiskey"] + ], + "relationships": [ + ["Adviser","Blackmailer","Business partner","Business rival","Buyer","Captor"], + ["Client","Confidant","Debtor","Disciple","Guardian","Henchman"], + ["Idol","Informant","Master","Mentor","Nemesis","Offspring"], + ["Parent","Patron","Political rival","Prisoner","Protégé","Quarry"], + ["Right hand","Romantic rival","Servant","Sibling","Social rival","Spouse"], + ["Stalker","Suitor","Supplicant","Supplier","Sweetheart","Unrequited love"] + ], + "divine_domains": [ + ["EXTERNAL","Balance","Betrayal","Chance","Chaos","Conquest"], + ["Cycles","Death","Destiny","Dreams","EXTERNAL","Gateways"], + ["Judgement","Love","Memory","Monsters","Moon","Motherhood"], + ["EXTERNAL","Oaths","Order","Plague","Purification","Reason"], + ["Schemes","Secrets","Storms","Summer","Sun","The Forge"], + ["The Sea","The Wild","Time","Underworld","Wealth","Winter"] + ], + "after_the_party": [ + ["Absurd boasts","Adopted a child","Awarded medal","Bought the inn","Cursed","Duel scheduled"], + ["Elected to office","Given a quest","Got married","In a coffin","In love","In the stocks"], + ["Inconvenient pet","Insulted a noble","Insulted FACTION","Joined a cult","Letter of thanks","Lost"], + ["Lost at gambling","Lost reputation","New identity","New tattoo","Poisoned","Recruited"], + ["Robbed","Roof on fire","Shanghaied","Sick","Signed contract","Someone died"], + ["Spilled secrets","Started a cult","Swindled","Thrown in jail","Unruly mob","Wrong clothes"] + ] +} diff --git a/internal/data/treasure.json b/internal/data/treasure.json new file mode 100644 index 0000000..179f0ba --- /dev/null +++ b/internal/data/treasure.json @@ -0,0 +1,82 @@ +{ + "misc_items": [ + ["Bowl","Brass bell","Brooch","Carved figurine","Cup","Deck of cards"], + ["Drawing","Foreign coin","Game piece","Glass eye","Glass jar","Hair comb"], + ["Handkerchief","Hinged box","Hourglass","Human tooth","Hunting horn","Loaded dice"], + ["Long fork","Numbered key","Oil lamp","Old doll","Paint pot","Pencil"], + ["Purse","Quill pen","Salve","Scissors","Scroll","Sealed letter"], + ["Sewing needle","Shaving razor","Silver button","Skull","Tobacco pipe","Wine bottle"] + ], + "worn_items": [ + ["Belt","Blouse","Boots","Bracelet","Breastplate","Brigandine"], + ["Cincture","Cloak","Coat","Dress","Earring","Eyepatch"], + ["Gauntlets","Glove","Gown","Hat","Helmet","Hose"], + ["Leather armor","Locket","Mail Shirt","Mask","Necklace","Padded armor"], + ["Plate mail","Ring","Robe","Sandals","Scarf","Shirt"], + ["Shoes","Skirt","Slippers","Socks","Trousers","Veil"] + ], + "weapon_items": [ + ["Arming sword","Backsword","Battleaxe","Blowpipe","Claymore","Club"], + ["Crossbow","Cutlass","Dagger","Flail","Flanged mace","Glaive"], + ["Halberd","Hammer","Hatchet","Horsebow","Hunting knife","Lance"], + ["Longbow","Longsword","Mace","Maul","Morningstar","Pike"], + ["Scimitar","Shortbow","Sickle","Sling","Spear","Staff"], + ["Stake","Stiletto","Throwing axe","Warhammer","Warpick","Whip"] + ], + "book_subjects": [ + ["Alchemy","Art","Astrology","Blackmail","Charts & maps","Conspiracies"], + ["Cookbook","Criminals","Divination","Etiquette","Fashion","Genealogy"], + ["Hagiography","History","Journal","Language","Laws","Letters"], + ["Lost empires","Lost places","Love poems","Monsters","Mythology","Odd customs"], + ["Oratory","Propaganda","Prophecies","Siegecraft","Songs","State secrets"], + ["Sword fighting","Theology","Treasures","War chronicle","Who's who","Witch-hunting"] + ], + "tool_items": [ + ["Acid flask","Bear trap","Bellows","Bolt-cutters","Chain","Chisel"], + ["Crowbar","Door ram","Ear trumpet","Fire oil","Fishing hook","Goggles"], + ["Grappling hook","Grease","Hacksaw","Hammer","Hand drill","Lantern"], + ["Lens","Lock/key","Lockpicks","Manacles","Metal file","Mortar/pestle"], + ["Needle","Pickaxe","Pitchfork","Pliers","Pole","Pulleys"], + ["Rope","Scissors","Shovel","Spikes","Steel wire","Tongs"] + ], + "potions": [ + ["EXTERNAL","Body swap","Camouflage","Control animals","EXTERNAL","Cure affliction"], + ["Detect evil","Detect gold","Detect hidden","Direction sense","EXTERNAL","EXTERNAL"], + ["Extra arm","Flight","Ghost-speech","Heat vision","EXTERNAL","Invulnerable"], + ["EXTERNAL","Magic immunity","Mirror image","EXTERNAL","EXTERNAL","EXTERNAL"], + ["EXTERNAL","Night vision","EXTERNAL","Restore health","Speed","Stretchy"], + ["Super-jump","Super-strength","Telekinesis","Tongues","Water-breathing","Water-walking"] + ], + "magical_ingredients": [ + ["Ancient liquor","EXTERNAL","Blind eye","Boiled cat","EXTERNAL","Bottled fog"], + ["Coffin nail","Corpse's hair","Crossroad dust","Cultist entrails","EXTERNAL","Exotic spice"], + ["Killer's hand","King's tooth","Last breath","Liar's tongue","Plant","Lodestone"], + ["Monk's vow","EXTERNAL","Newborn's cry","Oil portrait","EXTERNAL","EXTERNAL"], + ["EXTERNAL","Pyre ember","Queen bee","Queen's blood","Ship's barnacle","Star-metal"], + ["Thief's finger","Tomb flower","EXTERNAL","Wedding ring","Widow's tears","Wizard skull"] + ], + "treasure_items": [ + ["Alchemy recipe","Amulet","Astrolabe","Blueprints","Calligraphy","Carpet"], + ["Compass","Contract","Crown","Crystal","Deed","Embroidery"], + ["Fine china","Fine liquor","Instrument","Magical book","Microscope","Music box"], + ["Orrery","Painting","Perfume","Prayer book","Printing block","Rare textile"], + ["Royal robes","Saint's relic","Scrimshaw","Sextant","Sheet music","Signet ring"], + ["Silverware","Spices","Spyglass","Tapestry","Telescope","Treasure map"] + ], + "treasure_traits": [ + ["Altered","Ancient","Blessed","Bulky","Compact","Consumable"], + ["Cultural value","Cursed","Damaged","Disguised","Draws enemies","EXTERNAL"], + ["EXTERNAL","Embellished","Encoded","Exotic","Extra-planar","Famous"], + ["Forbidden","Fragile","Heavy","Immovable","Impracticable","Indestructible"], + ["Intelligent","Masterwork","Military value","Non-human","Owned","Partial"], + ["Political value","Religious value","Repaired","Royal","Toxic","Vile"] + ], + "valuable_materials": [ + ["Alabaster","Amber","Aquamarine","Azurite","Beryl","Black Pearl"], + ["Bloodstone","Bone China","Chalcedony","Cinnabar","Coral","Diamond"], + ["Ebony", "Emerald", "Fire Agate","Garnet","Gold","Ivory"], + ["Jade","Jasper","Jet","Lapis Lazuli","Malachite","Moonstone"], + ["Onyx","Opal","Pearl","Platinum","Porcelain","Ruby"], + ["Sapphire","Serpentine","Silver","Star Iron","Topaz","Turquoise"] + ] +} diff --git a/internal/data/wild.json b/internal/data/wild.json new file mode 100644 index 0000000..0c7a32a --- /dev/null +++ b/internal/data/wild.json @@ -0,0 +1,98 @@ +{ + "wilderness_regions": [ + ["Ashy","Badlands","Bay","Beach","Delta","Desert"], + ["Dry lands","Dune sea","Dust bowl","Fjords","Flood lands","Foothills"], + ["Forest","Glaciers","Heath","Highlands","Hills","Ice fields"], + ["Jungle","Lowlands","Mesas","Moor","Mountains","Petrified forest"], + ["Plains","Rainforest","Riverlands","Salt pan","Savanna","Steppe"], + ["Taiga","Thickets","Tundra","Volcanic plain","Wetlands","Woodlands"] + ], + "wilderness_landmarks": [ + ["Bog","Boulder field","Butte","Cave","Cliff","Crag"], + ["Crater","Creek","Crossing","Ditch","Field","Forest"], + ["Grove","Hill","Hollow","Hot springs","Lair","Lake"], + ["Lakebed","Marsh","Mesa","Moor","Pass","Pit"], + ["Pond","Rapids","Ravine","Ridge","Rise","River"], + ["Rockslide","Spring","Swamp","Thickets","Valley","Waterfall"] + ], + "wilderness_structures": [ + ["Altar","Aqueduct","Bandit’s camp","Battlefield","Bonfire","Bridge"], + ["Cairn","Crossroads","Crypt","Dam","Dungeon","Farm"], + ["Ford","Fortress","Gallows","Graveyard","Hedge","Hunter’s camp"], + ["Inn","Lumber camp","Mine","Monastery","Monument","Orchard"], + ["Outpost","Pasture","Ruin","Seclusion","Shack","Shrine"], + ["Standing stone","Temple","Village","Wall","Watchtower","Waystone"] + ], + "wilderness_region_traits": [ + ["Ashen","Blasted","Blighted","Broken","Consuming","Corrupted"], + ["Creeping","Desolate","EXTERNAL","Eternal","EXTERNAL","Forsaken"], + ["Frozen","Haunted","Howling","Jagged","Lonely","Misty"], + ["Perilous","Petrified","Phantasmal","Ravenous","Savage","Shadowy"], + ["Shifting","Shivering","Sinister","Sinking","Smoldering","Sweltering"], + ["Thorny","Thundering","Torrential","EXTERNAL","Wandering","Withered"] + ], + "wilderness_discoveries": [ + ["Blood stains","Bones","Broken weapons","Burrow","EXTERNAL","EXTERNAL"], + ["Cut ropes","Dead animal","EXTERNAL","Food scraps","Grave marker","Human corpse"], + ["EXTERNAL","EXTERNAL","Magical effect","Map","Message","Migration"], + ["EXTERNAL","Nest","Portal","Resources","Rift","Strange plant"], + ["EXTERNAL","Supplies","Torn flag","Tracks","Trap","Treasure cache"], + ["EXTERNAL","EXTERNAL","EXTERNAL","EXTERNAL","EXTERNAL","Wizard fight"] + ], + "wilderness_activities": [ + ["Ambush","Argue","Birth","Build","Bury","Capture"], + ["EXTERNAL","Convene","Demolish","Die","Duel","EXTERNAL"], + ["Eat","Excavate","Feast","Felling","Fish","Flee"], + ["Forage","Hunt","March","Raid","Rescue","Rest"], + ["Sacrifice","Scout","Sing","Skin","Skirmish","Slay"], + ["Sleep","Swim","Track","Trap","Wander","Worship"] + ], + "wilderness_hazards": [ + ["Avalanche","Blizzard","Brushfire","Cloudburst","Cyclone","Dense fog"], + ["Downpour","Drizzle","Dust storm","Earthquake","Eruption","Flooding"], + ["Forest fire","Hail","Heat wave","Hurricane","Ice storm","Light mist"], + ["Locust swarm","Magma flow","Meteor strike","Monsoon","Mudflow","Mudslide"], + ["Predator","Quicksand","Rain of frogs","Rockslide","Sandstorm","Sleet"], + ["Snow","Stampede","Thunderstorm","Tsunami","Whirlpool","Windstorm"] + ], + "edible_plants": [ + ["Acorns","Apples","Asparagus","Blackberries","Blueberries","Carrots"], + ["Cattail","Cherries","Chickweed","Chicory","Clover","Dandelion"], + ["Dead-nettle","Elderberries","Fireweed","Gooseberries","Hazelnuts","Henbit"], + ["Hickory nuts","Honeysuckle","Leeks","Milk thistle","Mint","Mulberries"], + ["Mushrooms","Mustard","Onion","Pecans","Persimmons","Raspberries"], + ["Strawberries","Walnuts","Watercress","Wild garlic","Wild grapes","Wood sorrel"] + ], + "poisonous_plants": [ + ["Angel’s trumpet","Baneberry","Belladona","Black truffle","Bleeding heart","Celandine"], + ["Cocklebur","Columbine","Crowncup","Death cap","Dumbcane","Foxglove"], + ["Hemlock","Hogweed","Holly","Horse chestnut","Hyacinth","Ivy"], + ["Jessamine","Kudu","Larkspur","Mandrake","Mangrove","Mistletoe"], + ["Moonflower","Nightshade","Oleander","Ragwort","Reindeer lichen","Snakeweed"], + ["Spindle","Stinkhorn","Waxcap","Wine-Cap","Wolfsbane","Wormwood"] + ], + "inn_adjectives": [ + ["Bellowing","Blazing","Bleak","Blessed","Bloody","Crimson"], + ["Cunning","Copper","Dancing","Dead","Drunken","Flying"], + ["Ghastly","Golden","Helpful","Hideous","Howling","Hungry"], + ["Moldy","Muttering","Nimble","Oozing","Petrified","Prancing"], + ["Romantic","Salty","Singing","Shivering","Shrieking","Silver"], + ["Smoking","Thirsty","Wicked","Tipsy","Whistling","Wanton"] + ], + "inn_nouns": [ + ["Axe","Barrel","Bear","Bell","Boot","Bowl"], + ["Bucket","Candle","Cock","Cow","Dragon","Egg"], + ["Elephant","Flea","Fork","Giant","Griffin","Hart"], + ["Hog","Hound","Lamb","Lion","Mackerel","Maid"], + ["Monk","Moon","Pipe","Prince","Rat","Skull"], + ["Spoon","Star","Swan","Sword","Whale","Wife"] + ], + "inn_quirks": [ + ["100 years in past","Always night","Animal fights","Bard duels","Bigger inside","Black market"], + ["Brand new","Cannibals","EXTERNAL","Constant party","Dancing contest","Dead drop"], + ["EXTERNAL","Expensive","EXTERNAL","EXTERNAL","Famous chef","Fey patrons"], + ["Fight club","Five floors","Ghost staff","Haunted","Hideout","EXTERNAL"], + ["Magic sword","Magically moves","Mercs for hire","EXTERNAL","Preaching","Secure storage"], + ["Staff are kids","Talking painting","Underground","VIP lounge","Voice in well","Women only"] + ] +} diff --git a/internal/dice/dice.go b/internal/dice/dice.go new file mode 100644 index 0000000..cbfc3b8 --- /dev/null +++ b/internal/dice/dice.go @@ -0,0 +1,104 @@ +package dice + +import ( + "encoding/json" + "errors" + "fmt" + "math/rand" + "regexp" + "strconv" + "strings" +) + +type diceRequest struct { + count int + diceType int +} + +type DiceRoller interface { + Roll(request string) ([]int, error) + TableRoll() [2]int +} + +type Roller struct { + Rand *rand.Rand + Seed int64 + DiceRoller +} + +func NewRoller(seed int64) *Roller { + return &Roller{ + Rand: rand.New(rand.NewSource(seed)), + Seed: seed, + } +} + +// RollToJSON takes a []int and returns JSON with those ints in "results" +func RollToJSON(rolls []int) ([]byte, error) { + result := struct { + Results []int `json:"results"` + }{ + Results: rolls, + } + + jsonResults, err := json.Marshal(result) + if err != nil { + return []byte{}, err + } + + return jsonResults, nil +} + +// RollToText takes a []int and returns them a spaced separated string +func RollToText(rolls []int) string { + results := []string{} + for _, r := range rolls { + results = append(results, strconv.Itoa(r)) + } + response := strings.Join(results, " ") + response = response + "\n" + return response +} + +// Roll takes a string in the format of "XdY" and returns []int for its results +func (r *Roller) Roll(request string) ([]int, error) { + var result []int + + diceRequest, err := parseRoll(request) + if err != nil { + return result, err + } + + for i := 1; i <= diceRequest.count; i++ { + result = append(result, r.Rand.Intn(diceRequest.diceType)+1) + } + + return result, nil +} + +// TableRoll returns a roll used for selecting an item on a Maze Rats table +func (r *Roller) TableRoll() [2]int { + result, _ := r.Roll("2d6") + return [2]int{result[0], result[1]} +} + +func parseRoll(request string) (diceRequest, error) { + regexString := "[1-9][0-9]*d[1-9]+" + diceRegEx := regexp.MustCompile(regexString) + correctRequest := diceRegEx.Match([]byte(request)) + if !correctRequest { + errMsg := fmt.Sprintf("Must pass string matching '%v' "+ + "you passed '%v'", + regexString, request) + return diceRequest{}, errors.New(errMsg) + } + + var parsedRequest []string = strings.Split(request, "d") + count, _ := strconv.Atoi(parsedRequest[0]) + diceType, _ := strconv.Atoi(parsedRequest[1]) + + return diceRequest{ + count: count, + diceType: diceType, + }, nil +} diff --git a/internal/dice/dice_test.go b/internal/dice/dice_test.go new file mode 100644 index 0000000..9213f67 --- /dev/null +++ b/internal/dice/dice_test.go @@ -0,0 +1,52 @@ +package dice + +import ( + "errors" + "reflect" + "testing" +) + +func TestRoll(t *testing.T) { + roller := NewRoller(1) + result, err := roller.Roll("2d6") + if err != nil { + t.Error(err) + } + + if !reflect.DeepEqual(result, []int{6, 4}) { + t.Errorf("Expected roll to equal [6, 4], but got %#v", result) + } +} + +func TestRollToJSON(t *testing.T) { + r := NewRoller(1) + roll, _ := r.Roll("2d6") + result, err := RollToJSON(roll) + if err != nil { + t.Error(err) + } + expectedResult := `{"results":[6,4]}` + if !reflect.DeepEqual([]byte(expectedResult), result) { + t.Errorf("Expected '%v', but got '%v'", string(expectedResult), string(result)) + } +} + +func TestParseRoll(t *testing.T) { + _, err := parseRoll("1e6") + expectedMsg := "Must pass string matching '[1-9][0-9]*d[1-9]+' you passed '1e6'" + expectedError := errors.New(expectedMsg) + if err.Error() != expectedError.Error() { + t.Errorf("Expected error message: %v; got: %v", expectedError, err) + } + + result, err := parseRoll("2d10") + if err != nil { + t.Errorf("Expected 'parseRoll(\"2d10\")' to not error, got %v", err) + } + if result.count != 2 { + t.Errorf("Expected 'result.count' to equal '2'; got: %v", result.count) + } + if result.diceType != 10 { + t.Errorf("Expected 'result.count' to equal '10'; got: %v", result.count) + } +} diff --git a/internal/handlers/character.go b/internal/handlers/character.go new file mode 100644 index 0000000..c89ac3b --- /dev/null +++ b/internal/handlers/character.go @@ -0,0 +1,41 @@ +package handlers + +import ( + "fmt" + "github.com/gorilla/mux" + "mazeratsgen/internal/dice" + "mazeratsgen/internal/tables" + "net/http" + "strconv" + "time" +) + +// @Summary Generate a player character +// @Tags character +// @Produce application/json, text/plain +// @Method GET +// @Router /api/generate/character [get] +// @Success 200 {object} tables.Character +func GenCharacter(w http.ResponseWriter, r *http.Request) { + t := tables.CharacterTable{Roller: dice.NewRoller(time.Now().UnixNano())} + WriteResponse(w, r, t.Generate(), t.Template()) +} + +// @Summary Generate a specific player character using a seed +// @Tags character +// @Produce application/json, text/plain +// @Method GET +// @Router /api/character/{seed} [get] +// @Param seed path int64 true "Int64" +// @Success 200 {object} tables.Character +func Character(w http.ResponseWriter, r *http.Request) { + vars := mux.Vars(r) + seed, err := strconv.ParseInt(vars["seed"], 10, 64) + if err != nil { + w.Write([]byte(fmt.Sprintf("Unable to parse '%v' as Int64", vars["seed"]))) + return + } + + t := tables.CharacterTable{Roller: dice.NewRoller(seed)} + WriteResponse(w, r, t.Generate(), t.Template()) +} diff --git a/internal/handlers/city.go b/internal/handlers/city.go new file mode 100644 index 0000000..082f742 --- /dev/null +++ b/internal/handlers/city.go @@ -0,0 +1,41 @@ +package handlers + +import ( + "fmt" + "github.com/gorilla/mux" + "mazeratsgen/internal/dice" + "mazeratsgen/internal/tables" + "net/http" + "strconv" + "time" +) + +// @Summary Generate a city +// @Tags city +// @Produce application/json, text/plain +// @Method GET +// @Router /api/generate/city [get] +// @Success 200 {object} tables.City +func GenCity(w http.ResponseWriter, r *http.Request) { + t := tables.CityTable{Roller: dice.NewRoller((time.Now().UnixNano()))} + WriteResponse(w, r, t.Generate(), t.Template()) +} + +// @Summary Generate a specific city using a seed +// @Tags city +// @Produce application/json, text/plain +// @Method GET +// @Router /api/city/{seed} [get] +// @Param seed path int64 true "Int64" +// @Success 200 {object} tables.City +func City(w http.ResponseWriter, r *http.Request) { + vars := mux.Vars(r) + seed, err := strconv.ParseInt(vars["seed"], 10, 64) + if err != nil { + w.Write([]byte(fmt.Sprintf("Unable to parse '%v' as Int64", vars["seed"]))) + return + } + + t := tables.CityTable{Roller: dice.NewRoller(seed)} + WriteResponse(w, r, t.Generate(), t.Template()) +} diff --git a/internal/handlers/dice.go b/internal/handlers/dice.go new file mode 100644 index 0000000..bf0a747 --- /dev/null +++ b/internal/handlers/dice.go @@ -0,0 +1,31 @@ +package handlers + +import ( + "github.com/gorilla/mux" + "mazeratsgen/internal/dice" + "net/http" + "time" +) + +// @Summary Roll some dice +// @Tags dice +// @Produce application/json, text/plain +// @Method GET +// @Router /api/roll/{xdy} [get] +// @Param xdy path string true "Roll in xdy format (e.g. 1d6)" +// @Success 200 +func Roll(w http.ResponseWriter, r *http.Request) { + vars := mux.Vars(r) + roller := dice.NewRoller(time.Now().UnixNano()) + response, err := roller.Roll(vars["xdy"]) + if err != nil { + w.WriteHeader(http.StatusInternalServerError) + // TODO: Return json error + w.Write([]byte(err.Error())) + return + } + + template := "{{ range . }}{{ . }}\n{{end}}" + + WriteResponse(w, r, response, template) +} diff --git a/internal/handlers/handlers.go b/internal/handlers/handlers.go new file mode 100644 index 0000000..6d2d972 --- /dev/null +++ b/internal/handlers/handlers.go @@ -0,0 +1,58 @@ +package handlers + +import ( + "fmt" + "github.com/gorilla/mux" + "mazeratsgen/internal/tables" + "net/http" +) + +func LoadHandlers(r *mux.Router) { + r.HandleFunc("/api/generate/name", GenName) + r.HandleFunc("/api/generate/spell", GenSpell) + + r.HandleFunc("/api/generate/monster", GenMonster) + r.HandleFunc("/api/monster/{seed}", Monster) + + r.HandleFunc("/api/generate/character", GenCharacter) + r.HandleFunc("/api/character/{seed}", Character) + + r.HandleFunc("/api/generate/city", GenCity) + r.HandleFunc("/api/city/{seed}", City) + + r.HandleFunc("/api/roll/{xdy}", Roll) +} + +func WriteResponse(w http.ResponseWriter, r *http.Request, i interface{}, t string) { + var response interface{} + var err error + if r.Header.Get("Accept") == "text/plain" { + w.Header().Set("Content-Type", "text/plain") + response, err = tables.ConvertToText(i, t) + if err != nil { + // TODO: Return json error + w.WriteHeader(http.StatusInternalServerError) + w.Write([]byte(err.Error())) + return + } + } else { + w.Header().Set("Content-Type", "application/json") + response, err = tables.ConvertToJSON(i) + if err != nil { + // TODO: Return json error + w.WriteHeader(http.StatusInternalServerError) + w.Write([]byte(err.Error())) + return + } + } + w.WriteHeader(http.StatusOK) + switch response.(type) { + case []byte: + w.Write(response.([]byte)) + case string: + w.Write([]byte(response.(string))) + default: + err := fmt.Sprintf("Error writing response, '%v' not handled", response) + w.Write([]byte(err)) + } +} diff --git a/internal/handlers/monster.go b/internal/handlers/monster.go new file mode 100644 index 0000000..d5c5ef6 --- /dev/null +++ b/internal/handlers/monster.go @@ -0,0 +1,41 @@ +package handlers + +import ( + "fmt" + "github.com/gorilla/mux" + "mazeratsgen/internal/dice" + "mazeratsgen/internal/tables" + "net/http" + "strconv" + "time" +) + +// @Summary Generate a monster +// @Tags monster +// @Produce application/json, text/plain +// @Method GET +// @Router /api/generate/monster [get] +// @Success 200 {object} tables.Monster +func GenMonster(w http.ResponseWriter, r *http.Request) { + t := tables.MonsterTable{Roller: dice.NewRoller(time.Now().UnixNano())} + WriteResponse(w, r, t.Generate(), t.Template()) +} + +// @Summary Generate a specific monster using a seed +// @Tags monster +// @Produce application/json, text/plain +// @Method GET +// @Router /api/monster/{seed} [get] +// @Param seed path int64 true "Int64" +// @Success 200 {object} tables.Monster +func Monster(w http.ResponseWriter, r *http.Request) { + vars := mux.Vars(r) + seed, err := strconv.ParseInt(vars["seed"], 10, 64) + if err != nil { + w.Write([]byte(fmt.Sprintf("Unable to parse '%v' as Int64", vars["seed"]))) + return + } + + t := tables.MonsterTable{Roller: dice.NewRoller(seed)} + WriteResponse(w, r, t.Generate(), t.Template()) +} diff --git a/internal/handlers/name.go b/internal/handlers/name.go new file mode 100644 index 0000000..20e3ead --- /dev/null +++ b/internal/handlers/name.go @@ -0,0 +1,20 @@ +package handlers + +import ( + "mazeratsgen/internal/tables" + "net/http" + "strings" + "time" +) + +// @Summary Generate a character name +// @Tags character +// @Produce application/json, text/plain +// @Method GET +// @Router /api/generate/name [get] +// @Success 200 +func GenName(w http.ResponseWriter, r *http.Request) { + n := tables.GenRandomName(time.Now().UnixNano()) + template := strings.TrimSpace("{{.FullName}}") + WriteResponse(w, r, n, template) +} diff --git a/internal/handlers/spell.go b/internal/handlers/spell.go new file mode 100644 index 0000000..df2acb0 --- /dev/null +++ b/internal/handlers/spell.go @@ -0,0 +1,19 @@ +package handlers + +import ( + "mazeratsgen/internal/dice" + "mazeratsgen/internal/tables" + "net/http" + "time" +) + +// @Summary Generate a spell +// @Tags magic +// @Produce application/json, text/plain +// @Method GET +// @Router /api/generate/spell [get] +// @Success 200 +func GenSpell(w http.ResponseWriter, r *http.Request) { + t := tables.MagicTable{Roller: dice.NewRoller(time.Now().UnixNano())} + WriteResponse(w, r, t.Generate(), t.Template()) +} diff --git a/internal/helpers/helpers.go b/internal/helpers/helpers.go new file mode 100644 index 0000000..b9acfb2 --- /dev/null +++ b/internal/helpers/helpers.go @@ -0,0 +1,37 @@ +package helpers + +import ( + "mazeratsgen/internal/dice" + "path" + "runtime" +) + +func LocalFile(filepath string) string { + _, thisFile, _, _ := runtime.Caller(1) + return path.Join(path.Dir(thisFile), filepath) +} + +type genFunc func([2]int) string + +func GenUniqueItems(total int, fn genFunc, seed int64) []string { + roller := dice.NewRoller(seed) + items := []string{} + + // Generate initial items + for i := 0; i <= total; i++ { + items = append(items, fn(roller.TableRoll())) + } + + // Walk items and check if they match any other item. If they do then replace + // it with a fresh item. This doesn't guarantee unique items, but prevents + // Denial of Service attacks (a bit) + for i, item := range items { + for x := 0; x < len(items); x++ { + if items[x] == item { + items[i] = fn(roller.TableRoll()) + break + } + } + } + return items +} diff --git a/internal/tables/character.go b/internal/tables/character.go new file mode 100644 index 0000000..c801994 --- /dev/null +++ b/internal/tables/character.go @@ -0,0 +1,164 @@ +package tables + +import ( + data "mazeratsgen/internal/data" + dice "mazeratsgen/internal/dice" + "mazeratsgen/internal/helpers" + "strings" +) + +type CharacterTable struct { + Roller *dice.Roller +} + +// charAbilities holds values related to character stats +type charAbilities struct { + STR int + DEX int + WIL int +} + +type CharacterStats struct { + MaxHealth int `json:"max_health"` + Armor int `json:"armor"` + STR int `json:"str"` + DEX int `json:"dex"` + WIL int `json:"wil"` +} + +type Character struct { + Name string `json:"name"` + Stats CharacterStats + Feature string `json:"feature"` + Weapons []string `json:"weapons"` + Items []string `json:"items"` + Appearance string `json:"appearance"` + PhysicalDetail string `json:"physical_detail"` + Background string `json:"background"` + Clothing string `json:"clothing"` + Personality string `json:"personality"` + Mannerism string `json:"mannerism"` + Seed int64 +} + +func (t *CharacterTable) Generate() Character { + abilityRoll, _ := t.Roller.Roll("1d6") + abilites := t.Abilities(abilityRoll[0]) + + classRoll, _ := t.Roller.Roll("1d2") + var class string + if classRoll[0] == 1 { + class = "Upperclass" + } else { + class = "Lowerclass" + } + + genderRoll, _ := t.Roller.Roll("1d2") + var gender string + if genderRoll[0] == 1 { + gender = "Male" + } else { + gender = "Female" + } + + result, _ := t.Roller.Roll("1d6") + featureRoll := result[0] + + return Character{ + Name: GenName(class, gender, t.Roller.Seed).FullName, + Stats: CharacterStats{ + Armor: 6, + MaxHealth: t.MaxHealth(), + STR: abilites.STR, + DEX: abilites.DEX, + WIL: abilites.WIL, + }, + Feature: t.Feat(featureRoll), + Weapons: helpers.GenUniqueItems(2, TreasureTable{Roller: t.Roller}.WeaponItem, t.Roller.Seed), + Items: helpers.GenUniqueItems(6, t.Item, t.Roller.Seed), + Appearance: t.Appearance(t.Roller.TableRoll()), + PhysicalDetail: t.PhysicalDetail(t.Roller.TableRoll()), + Background: t.Background(t.Roller.TableRoll()), + Clothing: t.Clothing(t.Roller.TableRoll()), + Personality: t.Personality(t.Roller.TableRoll()), + Mannerism: t.Mannerism(t.Roller.TableRoll()), + Seed: t.Roller.Seed, + } +} + +func (t CharacterTable) Template() string { + return strings.TrimSpace(` +Name: {{.Name}} +Feature: {{.Feature}} +Background: {{.Background}} +Stats: + Health: {{.Stats.MaxHealth}} + Armor: {{.Stats.Armor}} (+1 for shield, +1 for light armor, +2 for heavy armor) + STR: {{.Stats.STR}} (Used for raw power, stamina, or physical resilience) + DEX: {{.Stats.DEX}} (Used for speed, agility, or precision) + WIL: {{.Stats.WIL}} (Used for force of personality, perception, or willpower) +Appearance: {{.Appearance}} +Physical Detail: {{.PhysicalDetail}} +Clothing: {{.Clothing}} +Personality: {{.Personality}} +Mannerism: {{.Mannerism}} +Items: +{{- range $item := .Items }} + {{$item}} +{{- end}} +Seed: {{ .Seed }} +`) +} + +// GenAbilities will return a STR/DEX/WIL for a character +func (t CharacterTable) Abilities(roll int) charAbilities { + stats := [6][3]int{ + [3]int{2, 1, 0}, + [3]int{2, 0, 1}, + [3]int{1, 2, 0}, + [3]int{0, 2, 1}, + [3]int{1, 0, 2}, + [3]int{0, 1, 2}, + } + + return charAbilities{ + STR: stats[roll-1][0], + DEX: stats[roll-1][1], + WIL: stats[roll-1][2], + } +} + +// GenMaxHealth is silly, it's always 4 for level 1 characters +func (t CharacterTable) MaxHealth() int { return 4 } + +func (t CharacterTable) Feat(roll int) string { + return data.Tables.Character.Feat[roll-1] +} + +func (t CharacterTable) Appearance(roll [2]int) string { + return data.Tables.Character.Appearance[roll[0]-1][roll[1]-1] +} + +func (t CharacterTable) Background(roll [2]int) string { + return data.Tables.Character.Background[roll[0]-1][roll[1]-1] +} + +func (t CharacterTable) Clothing(roll [2]int) string { + return data.Tables.Character.Clothing[roll[0]-1][roll[1]-1] +} + +func (t CharacterTable) Item(roll [2]int) string { + return data.Tables.Character.Items[roll[0]-1][roll[1]-1] +} + +func (t CharacterTable) Personality(roll [2]int) string { + return data.Tables.Character.Personality[roll[0]-1][roll[1]-1] +} + +func (t CharacterTable) PhysicalDetail(roll [2]int) string { + return data.Tables.Character.PhysicalDetail[roll[0]-1][roll[1]-1] +} + +func (t CharacterTable) Mannerism(roll [2]int) string { + return data.Tables.Character.Mannerism[roll[0]-1][roll[1]-1] +} diff --git a/internal/tables/character_test.go b/internal/tables/character_test.go new file mode 100644 index 0000000..3c01971 --- /dev/null +++ b/internal/tables/character_test.go @@ -0,0 +1,81 @@ +package tables + +import ( + "reflect" + "strings" + "testing" +) + +func TestGenCharacter(t *testing.T) { + t.Parallel() + char := GenCharacter(1) + tests := []struct { + field string + actual interface{} + expected interface{} + }{ + {field: "Name", actual: char.Name, expected: "Vivian Villin"}, + {field: "Stats.MaxHealth", actual: char.Stats.MaxHealth, expected: 4}, + {field: "Stats.Armor", actual: char.Stats.Armor, expected: 6}, + {field: "Stats.STR", actual: char.Stats.STR, expected: 0}, + {field: "Stats.DEX", actual: char.Stats.DEX, expected: 1}, + {field: "Stats.WIL", actual: char.Stats.WIL, expected: 2}, + {field: "Feature", actual: char.Feature, expected: "Shadowjack (Advantage on moving silently or hiding in shadows)"}, + {field: "Weapons", actual: char.Weapons, expected: []string{"Warhammer", "Whip"}}, + {field: "Items", actual: char.Items, expected: []string{"Vial of Acid", "Waterskin", "Chisel", "Fishing Net", "Metal file", "Hacksaw"}}, + {field: "Appearance", actual: char.Appearance, expected: "Bullnecked"}, + {field: "PhysicalDetail", actual: char.PhysicalDetail, expected: "Bushy eyebrows"}, + {field: "Background", actual: char.Background, expected: "Peddler"}, + {field: "Clothing", actual: char.Clothing, expected: "Food-stained"}, + {field: "Personality", actual: char.Personality, expected: "Cowardly"}, + {field: "Mannerism:", actual: char.Mannerism, expected: "Robotic"}, + } + for _, sTest := range tests { + // https://github.com/golang/go/wiki/CommonMistakes#using-reference-to-loop-iterator-variable + sTest := sTest + + t.Run("Character."+sTest.field, func(t *testing.T) { + t.Parallel() + if !reflect.DeepEqual(sTest.actual, sTest.expected) { + t.Errorf("Expected %#v to equal %#v", sTest.actual, sTest.expected) + } + }) + } +} + +var expectedText = strings.TrimSpace(` +Name: Vivian Villin +Feature: Shadowjack (Advantage on moving silently or hiding in shadows) +Background: Peddler +Stats: + Health: 4 + Armor: 6 (+1 for shield, +1 for light armor, +2 for heavy armor) + STR: 0 (Used for raw power, stamina, or physical resilience) + DEX: 1 (Used for speed, agility, or precision) + WIL: 2 (Used for force of personality, perception, or willpower) +Appearance: Bullnecked +Physical Detail: Bushy eyebrows +Clothing: Food-stained +Personality: Cowardly +Mannerism: Robotic +Items: + Vial of Acid + Waterskin + Chisel + Fishing Net + Metal file + Hacksaw +`) + +func TestCharacterToText(t *testing.T) { + t.Parallel() + char := GenCharacter(1) + result, err := CharacterToText(char) + if err != nil { + t.Error(err) + } + + if result != expectedText { + t.Errorf("Exected following to be equal:\n%#v\n%#v", result, expectedText) + } +} diff --git a/internal/tables/city.go b/internal/tables/city.go new file mode 100644 index 0000000..8a2b25e --- /dev/null +++ b/internal/tables/city.go @@ -0,0 +1,274 @@ +package tables + +import ( + "mazeratsgen/internal/data" + "mazeratsgen/internal/dice" + "mazeratsgen/internal/helpers" + "strings" +) + +type CityTable struct { + Roller *dice.Roller +} + +type Building struct { + Type string + Rooms []string + TacticalFeature string +} + +type Faction struct { + Type string + Trait string + Goal string +} + +type City struct { + Theme string + Events []string + DistrictThemes []string + Activities []string + TacticalStreetFeatures []string + UpperClassBuildings []Building + LowerClassBuildings []Building + Factions []Faction + Seed int64 +} + +func (t *CityTable) Generate() City { + upperClassBuildings := []Building{} + + // Future Jerry...the weird for loops here are to add noise to seed + // This will break if more than 6 rooms are needed + + for i := 0; i < 3; i++ { + tempRoller := dice.NewRoller(t.Roller.Seed + int64(i)) + tempTable := CityTable{Roller: tempRoller} + upperClassBuildings = append(upperClassBuildings, tempTable.UpperClassBuilding(tempRoller.TableRoll())) + } + + lowerClassBuildings := []Building{} + for i := 4; i < 7; i++ { + tempRoller := dice.NewRoller(t.Roller.Seed + int64(i)) + tempTable := CityTable{Roller: tempRoller} + lowerClassBuildings = append(lowerClassBuildings, tempTable.LowerClassBuilding(tempRoller.TableRoll())) + } + + return City{ + Theme: t.CityTheme(t.Roller.TableRoll()), + Events: helpers.GenUniqueItems(3, t.CityEvent, t.Roller.Seed), + DistrictThemes: helpers.GenUniqueItems(3, t.DistrictTheme, t.Roller.Seed), + UpperClassBuildings: upperClassBuildings, + LowerClassBuildings: lowerClassBuildings, + Activities: helpers.GenUniqueItems(3, t.CityActivity, t.Roller.Seed), + TacticalStreetFeatures: helpers.GenUniqueItems(3, t.TacticalStreetFeature, t.Roller.Seed), + Factions: []Faction{ + t.GenFaction(t.Roller.TableRoll()), + t.GenFaction(t.Roller.TableRoll()), + }, + Seed: t.Roller.Seed, + } +} + +func (t *CityTable) Template() string { + return strings.TrimSpace(` +Theme: {{.Theme}} +Events: +{{- range $event := .Events}} + {{$event}} +{{- end}} +District Themes: +{{- range $theme := .DistrictThemes}} + {{$theme}} +{{- end}} +Upper Class Buildings: +{{- range $building := .UpperClassBuildings}} + {{$building.Type}}: + Tactical Feature: {{$building.TacticalFeature}} + Rooms: + {{- range $room := $building.Rooms}} + {{$room}} + {{- end}} +{{- end}} +Lower Class Buildings: +{{- range $building := .LowerClassBuildings}} + {{$building.Type}}: + Tactical Feature: {{$building.TacticalFeature}} + Rooms: + {{- range $room := $building.Rooms}} + {{$room}} + {{- end}} +{{- end}} +Activities: +{{- range $activity := .Activities }} + {{$activity}} +{{- end}} +Tactical Street Features: +{{- range $feature := .TacticalStreetFeatures }} + {{$feature}} +{{- end}} +Factions: +{{- range $faction := .Factions }} + {{$faction.Type}}: + Trait: {{$faction.Trait}} + Goal: {{$faction.Goal}} +{{- end}} +Seed: {{.Seed}} +`) +} + +func (t *CityTable) CityTheme(roll [2]int) string { + switch roll { + case [2]int{1, 1}: + roll, _ := t.Roller.Roll("1d6") + return MonsterTable{Roller: t.Roller}.Base(roll[0]) + case [2]int{2, 1}: + return t.CityActivity(t.Roller.TableRoll()) + case [2]int{2, 2}: + return t.CityEvent(t.Roller.TableRoll()) + case [2]int{2, 5}: + return t.DistrictTheme(t.Roller.TableRoll()) + case [2]int{2, 6}: + return NPCTable{Roller: t.Roller}.DivineDomain(t.Roller.TableRoll()) + case [2]int{3, 1}: + return t.GenFaction(t.Roller.TableRoll()).Type + case [2]int{3, 5}: + return t.LowerClassBuilding(t.Roller.TableRoll()).Type + case [2]int{4, 2}: + return "Pick an existing NPC" + case [2]int{4, 4}: + return MagicTable{Roller: t.Roller}.PhysicalElement(t.Roller.TableRoll()) + case [2]int{6, 4}: + return t.UpperClassBuilding(t.Roller.TableRoll()).Type + default: + return data.Tables.City.CityThemes[roll[0]-1][roll[1]-1] + } +} + +func (t *CityTable) CityEvent(roll [2]int) string { + switch roll { + case [2]int{1, 4}: + return t.GenFaction(t.Roller.TableRoll()).Type + default: + return data.Tables.City.CityEvents[roll[0]-1][roll[1]-1] + } +} + +func (t *CityTable) DistrictTheme(roll [2]int) string { + npcTable := NPCTable{Roller: t.Roller} + switch roll { + case [2]int{1, 2}: + return npcTable.CivilizedNPC(t.Roller.TableRoll()) + case [2]int{4, 1}: + return t.LowerClassBuilding(t.Roller.TableRoll()).Type + case [2]int{6, 1}: + return npcTable.UnderworldNPC(t.Roller.TableRoll()) + case [2]int{6, 2}: + return t.UpperClassBuilding(t.Roller.TableRoll()).Type + case [2]int{6, 4}: + return npcTable.WildernessNPC(t.Roller.TableRoll()) + default: + return data.Tables.City.DistrictThemes[roll[0]-1][roll[1]-1] + } +} + +func (t CityTable) GenBuilding(roll int) Building { + if roll <= 3 { + return t.LowerClassBuilding(t.Roller.TableRoll()) + } + return t.UpperClassBuilding(t.Roller.TableRoll()) +} + +func (t CityTable) UpperClassBuilding(roll [2]int) Building { + return Building{ + Type: data.Tables.City.UpperClassBuildings[roll[0]-1][roll[1]-1], + TacticalFeature: t.TacticalBuildingFeature(t.Roller.TableRoll()), + Rooms: helpers.GenUniqueItems(3, t.BuildingRoom, t.Roller.Seed), + } +} + +func (t CityTable) LowerClassBuilding(roll [2]int) Building { + return Building{ + Type: data.Tables.City.LowerClassBuildings[roll[0]-1][roll[1]-1], + TacticalFeature: t.TacticalBuildingFeature(t.Roller.TableRoll()), + Rooms: helpers.GenUniqueItems(3, t.BuildingRoom, t.Roller.Seed), + } +} + +func (t CityTable) BuildingRoom(roll [2]int) string { + switch roll { + case [2]int{3, 1}: + return MazeTable{Roller: t.Roller}.DungeonRoom(t.Roller.TableRoll()) + default: + return data.Tables.City.BuildingRooms[roll[0]-1][roll[1]-1] + } +} + +func (t CityTable) TacticalStreetFeature(roll [2]int) string { + mazeTable := MazeTable{Roller: t.Roller} + switch roll { + case [2]int{2, 3}: + return t.CityActivity(t.Roller.TableRoll()) + case [2]int{3, 4}: + return mazeTable.DungeonActivity(t.Roller.TableRoll()) + case [2]int{6, 6}: + return WildTable{Roller: t.Roller}.WildernessActivity(t.Roller.TableRoll()) + default: + return data.Tables.City.TacticalStreetFeatures[roll[0]-1][roll[1]-1] + } +} + +func (t CityTable) TacticalBuildingFeature(roll [2]int) string { + switch roll { + case [2]int{1, 1}: + roll, _ := t.Roller.Roll("1d6") + return MonsterTable{Roller: t.Roller}.Base(roll[0]) + "Nests" + default: + return data.Tables.City.TacticalBuildingFeatures[roll[0]-1][roll[1]-1] + } +} + +func (t CityTable) FactionTrait(roll [2]int) string { + switch roll { + case [2]int{4, 4}: + return NPCTable{Roller: t.Roller}.Personality(t.Roller.TableRoll()) + default: + return data.Tables.City.FactionTraits[roll[0]-1][roll[1]-1] + } +} + +func (t CityTable) GenFaction(roll [2]int) Faction { + return Faction{ + Type: data.Tables.City.Factions[roll[0]-1][roll[1]-1], + Trait: t.FactionTrait(t.Roller.TableRoll()), + Goal: t.FactionGoal(t.Roller.TableRoll()), + } +} + +func (t CityTable) FactionGoal(roll [2]int) string { + switch roll { + case [2]int{1, 6}: + return "Control " + t.GenFaction(t.Roller.TableRoll()).Type + case [2]int{2, 3}: + return "Kill a specific monster" + case [2]int{2, 4}: + return "Defeat " + t.GenFaction(t.Roller.TableRoll()).Type + case [2]int{4, 4}: + return "Infiltrate " + t.GenFaction(t.Roller.TableRoll()).Type + default: + return data.Tables.City.FactionGoals[roll[0]-1][roll[1]-1] + } +} + +func (t CityTable) CityActivity(roll [2]int) string { + switch roll { + case [2]int{2, 5}: + return MazeTable{Roller: t.Roller}.DungeonActivity(t.Roller.TableRoll()) + case [2]int{4, 2}: + return NPCTable{Roller: t.Roller}.Mission(t.Roller.TableRoll()) + case [2]int{6, 6}: + return WildTable{Roller: t.Roller}.WildernessActivity(t.Roller.TableRoll()) + default: + return data.Tables.City.CityActivities[roll[0]-1][roll[1]-1] + } +} diff --git a/internal/tables/city_test.go b/internal/tables/city_test.go new file mode 100644 index 0000000..31c86b8 --- /dev/null +++ b/internal/tables/city_test.go @@ -0,0 +1,23 @@ +package tables + +import ( + "mazeratsgen/internal/dice" + "testing" +) + +func TestCityTableGenMethods(t *testing.T) { + roller := dice.NewRoller(1) + table := CityTable{Roller: roller} + table.CityTheme(roller.TableRoll()) + table.CityEvent(roller.TableRoll()) + table.DistrictTheme(roller.TableRoll()) + table.UpperClassBuilding(roller.TableRoll()) + table.LowerClassBuilding(roller.TableRoll()) + table.CityActivity(roller.TableRoll()) + table.BuildingRoom(roller.TableRoll()) + table.TacticalStreetFeature(roller.TableRoll()) + table.TacticalBuildingFeature(roller.TableRoll()) + table.GenFaction(roller.TableRoll()) + table.FactionTrait(roller.TableRoll()) + table.FactionGoal(roller.TableRoll()) +} diff --git a/internal/tables/magic.go b/internal/tables/magic.go new file mode 100644 index 0000000..741d653 --- /dev/null +++ b/internal/tables/magic.go @@ -0,0 +1,154 @@ +package tables + +import ( + "mazeratsgen/internal/data" + "mazeratsgen/internal/dice" +) + +type MagicTable struct { + Roller *dice.Roller +} + +func (t MagicTable) Generate() interface{} { + return t.Spell(t.Roller.TableRoll()) +} + +func (t MagicTable) Template() string { + return "{{ . }}" +} + +func (t MagicTable) Spell(roll [2]int) string { + switch roll[0] { + case 1: + if roll[1] <= 3 { + return t.PhysicalEffect(t.Roller.TableRoll()) + " " + t.PhysicalForm(t.Roller.TableRoll()) + } + return t.EtherealElement(t.Roller.TableRoll()) + " " + t.PhysicalForm(t.Roller.TableRoll()) + case 2: + if roll[1] <= 3 { + return t.PhysicalEffect(t.Roller.TableRoll()) + " " + t.EtherealForm(t.Roller.TableRoll()) + } + return t.EtherealElement(t.Roller.TableRoll()) + " " + t.EtherealForm(t.Roller.TableRoll()) + case 3: + if roll[1] <= 3 { + return t.EtherealEffect(t.Roller.TableRoll()) + " " + t.PhysicalForm(t.Roller.TableRoll()) + } + return t.PhysicalEffect(t.Roller.TableRoll()) + " " + t.EtherealElement(t.Roller.TableRoll()) + case 4: + if roll[1] <= 3 { + return t.EtherealEffect(t.Roller.TableRoll()) + " " + t.EtherealForm(t.Roller.TableRoll()) + } + return t.PhysicalEffect(t.Roller.TableRoll()) + " " + t.EtherealElement(t.Roller.TableRoll()) + case 5: + if roll[1] <= 3 { + return t.PhysicalElement(t.Roller.TableRoll()) + " " + t.PhysicalForm(t.Roller.TableRoll()) + } + return t.EtherealEffect(t.Roller.TableRoll()) + " " + t.PhysicalElement(t.Roller.TableRoll()) + default: + if roll[1] <= 3 { + return t.PhysicalElement(t.Roller.TableRoll()) + " " + t.EtherealForm(t.Roller.TableRoll()) + } + return t.EtherealEffect(t.Roller.TableRoll()) + " " + t.EtherealElement(t.Roller.TableRoll()) + } +} + +func (t MagicTable) Element(roll int) string { + if roll <= 3 { + return t.PhysicalElement(t.Roller.TableRoll()) + } + return t.EtherealElement(t.Roller.TableRoll()) +} + +func (t MagicTable) Effect(roll int) string { + if roll <= 3 { + return t.PhysicalEffect(t.Roller.TableRoll()) + } + return t.EtherealEffect(t.Roller.TableRoll()) +} + +func (t MagicTable) PhysicalEffect(roll [2]int) string { + return data.Tables.Magic.PhysicalEffects[roll[0]-1][roll[1]-1] +} + +func (t MagicTable) PhysicalElement(roll [2]int) string { + return data.Tables.Magic.PhysicalElements[roll[0]-1][roll[1]-1] +} + +func (t MagicTable) PhysicalForm(roll [2]int) string { + return data.Tables.Magic.PhysicalForms[roll[0]-1][roll[1]-1] +} + +func (t MagicTable) EtherealEffect(roll [2]int) string { + return data.Tables.Magic.EtherealEffects[roll[0]-1][roll[1]-1] +} + +func (t MagicTable) EtherealElement(roll [2]int) string { + return data.Tables.Magic.EtherealElements[roll[0]-1][roll[1]-1] +} + +func (t MagicTable) EtherealForm(roll [2]int) string { + return data.Tables.Magic.EtherealForms[roll[0]-1][roll[1]-1] +} + +func (t MagicTable) Mutation(roll [2]int) string { + monTable := MonsterTable{Roller: t.Roller} + baseRoll, _ := t.Roller.Roll("1d6") + switch roll { + case [2]int{1, 6}: + return monTable.Base(baseRoll[0]) + " Arms" + case [2]int{2, 1}: + return monTable.Base(baseRoll[0]) + " Eyes" + case [2]int{2, 2}: + return monTable.Base(baseRoll[0]) + " Head" + case [2]int{2, 3}: + return monTable.Base(baseRoll[0]) + " Legs" + case [2]int{2, 4}: + return monTable.Base(baseRoll[0]) + " Mouth" + case [2]int{2, 5}: + return monTable.Base(baseRoll[0]) + " Skin" + case [2]int{2, 6}: + return monTable.Base(baseRoll[0]) + " Form" + case [2]int{4, 2}: + return TreasureTable{Roller: t.Roller}.TreasureItem(t.Roller.TableRoll()) + " Form" + case [2]int{4, 6}: + return monTable.Feature(t.Roller.TableRoll()) + case [2]int{5, 1}: + return monTable.Trait(t.Roller.TableRoll()) + case [2]int{5, 4}: + return t.PhysicalElement(t.Roller.TableRoll()) + " Skin" + default: + return data.Tables.Magic.Mutations[roll[0]-1][roll[1]-1] + } +} + +func (t MagicTable) Insanity(roll [2]int) string { + monTable := MonsterTable{Roller: t.Roller} + switch roll { + case [2]int{1, 3}: + roll, _ := t.Roller.Roll("1d6") + return monTable.Base(roll[0]) + " Form" + case [2]int{5, 6}: + return monTable.Ability(t.Roller.TableRoll()) + case [2]int{6, 1}: + return monTable.Feature(t.Roller.TableRoll()) + case [2]int{6, 2}: + return monTable.Trait(t.Roller.TableRoll()) + case [2]int{6, 4}: + return NPCTable{Roller: t.Roller}.Personality(t.Roller.TableRoll()) + default: + return data.Tables.Magic.Insanities[roll[0]-1][roll[1]-1] + } +} + +func (t MagicTable) Catastrophe(roll [2]int) string { + switch roll { + case [2]int{1, 3}: + return "Animials " + t.Mutation(t.Roller.TableRoll()) + case [2]int{4, 1}: + return "Mass " + t.Insanity(t.Roller.TableRoll()) + case [2]int{4, 2}: + return "Mass " + t.Mutation(t.Roller.TableRoll()) + default: + return data.Tables.Magic.Catastrophes[roll[0]-1][roll[1]-1] + } +} diff --git a/internal/tables/magic_test.go b/internal/tables/magic_test.go new file mode 100644 index 0000000..28317cf --- /dev/null +++ b/internal/tables/magic_test.go @@ -0,0 +1,48 @@ +package tables + +import ( + "mazeratsgen/internal/dice" + . "mazeratsgen/test/helpers" + "testing" +) + +// TODO: Split out methods here +func TestGenMethods(t *testing.T) { + roller := dice.NewRoller(1) + table := MagicTable{Roller: roller} + table.PhysicalEffect(roller.TableRoll()) + table.PhysicalElement(roller.TableRoll()) + table.PhysicalForm(roller.TableRoll()) + table.Element(roller.TableRoll()[0]) // Oh no an extra dice roll (/s) + table.EtherealEffect(roller.TableRoll()) + table.EtherealElement(roller.TableRoll()) + table.EtherealForm(roller.TableRoll()) + table.Mutation(roller.TableRoll()) + table.Insanity(roller.TableRoll()) + table.Catastrophe(roller.TableRoll()) + table.Spell(roller.TableRoll()) +} + +func TestExactMethods(t *testing.T) { + roller := dice.NewRoller(1) + table := MagicTable{Roller: roller} + ExactItem(table.EtherealForm([2]int{1, 3}), "Beam", t) + RegexItem(table.Mutation([2]int{1, 6}), ".*Arms$", t) + RegexItem(table.Mutation([2]int{2, 1}), ".*Eyes$", t) + RegexItem(table.Mutation([2]int{2, 2}), ".*Head$", t) + RegexItem(table.Mutation([2]int{2, 3}), ".*Legs$", t) + RegexItem(table.Mutation([2]int{2, 4}), ".*Mouth$", t) + RegexItem(table.Mutation([2]int{2, 5}), ".*Skin$", t) + RegexItem(table.Mutation([2]int{2, 6}), ".* Form$", t) + // TODO: Finish specific items +} + +func TestGenSpell(t *testing.T) { + roller := dice.NewRoller(1) + table := MagicTable{Roller: roller} + for x := 1; x <= 5; x++ { + for y := 1; y <= 5; y++ { + table.Spell([2]int{x, y}) + } + } +} diff --git a/internal/tables/maze.go b/internal/tables/maze.go new file mode 100644 index 0000000..18ca38e --- /dev/null +++ b/internal/tables/maze.go @@ -0,0 +1,174 @@ +package tables + +import ( + "mazeratsgen/internal/data" + "mazeratsgen/internal/dice" + "mazeratsgen/internal/helpers" +) + +type MazeTable struct { + Roller *dice.Roller +} + +type Room struct { + Type string + Detail string +} + +type Maze struct { + Form string + Entrance string + Layout string + Ruination string + Reward string + Activities []string + Rooms []Room + Tricks []string + Hazards []string + TrapEffects []string + TrapTriggers []string +} + +func GenMaze(seed int64) Maze { + roller := dice.NewRoller(seed) + mazeTable := MazeTable{Roller: roller} + + total_rooms := 5 + roomTypes := helpers.GenUniqueItems(total_rooms, mazeTable.DungeonRoom, seed) + roomDetails := helpers.GenUniqueItems(total_rooms, mazeTable.DungeonRoomDetail, seed) + rooms := []Room{} + for i := 0; i < total_rooms; i++ { + room := Room{ + Type: roomTypes[i], + Detail: roomDetails[i], + } + rooms = append(rooms, room) + } + return Maze{ + Form: mazeTable.DungeonForm(roller.TableRoll()), + Entrance: mazeTable.DungeonEntrance(roller.TableRoll()), + Layout: mazeTable.DungeonLayout(roller.TableRoll()), + Ruination: mazeTable.DungeonRuination(roller.TableRoll()), + Reward: mazeTable.DungeonReward(roller.TableRoll()), + Activities: helpers.GenUniqueItems(5, mazeTable.DungeonActivity, seed), + Rooms: rooms, + Hazards: helpers.GenUniqueItems(5, mazeTable.DungeonHazard, seed), + Tricks: helpers.GenUniqueItems(5, mazeTable.DungeonTrick, seed), + TrapEffects: helpers.GenUniqueItems(5, mazeTable.TrapEffect, seed), + TrapTriggers: helpers.GenUniqueItems(5, mazeTable.TrapTrigger, seed), + } +} + +func (t MazeTable) DungeonEntrance(roll [2]int) string { + roll[0], roll[1] = roll[0]-1, roll[0]-1 + return data.Tables.Maze.DungeonEntrances[roll[0]][roll[1]] +} + +func (t MazeTable) DungeonForm(roll [2]int) string { + cityTable := CityTable{Roller: t.Roller} + switch roll { + case [2]int{2, 1}: + return cityTable.BuildingRoom(t.Roller.TableRoll()) + case [2]int{2, 6}: + return t.DungeonRoom(t.Roller.TableRoll()) + case [2]int{3, 5}: + return cityTable.LowerClassBuilding(t.Roller.TableRoll()).Type + case [2]int{6, 3}: + return cityTable.UpperClassBuilding(t.Roller.TableRoll()).Type + } + return data.Tables.Maze.DungeonForms[roll[0]-1][roll[1]-1] +} + +func (t MazeTable) DungeonLayout(roll [2]int) string { + return data.Tables.Maze.DungeonLayout[roll[0]-1][roll[1]-1] +} + +func (t MazeTable) DungeonRuination(roll [2]int) string { + magicTable := MagicTable{Roller: t.Roller} + switch roll { + case [2]int{4, 2}: + return magicTable.Insanity(t.Roller.TableRoll()) + case [2]int{5, 1}: + return magicTable.Mutation(t.Roller.TableRoll()) + } + return data.Tables.Maze.DungeonRuinations[roll[0]-1][roll[1]-1] +} + +func (t MazeTable) DungeonReward(roll [2]int) string { + treasureTable := TreasureTable{Roller: t.Roller} + switch roll { + case [2]int{3, 6}: + return "Magic " + treasureTable.TreasureItem(t.Roller.TableRoll()) + case [2]int{4, 5}: + return "Generate monster as an ally" + case [2]int{6, 2}: + return treasureTable.TreasureItem(t.Roller.TableRoll()) + case [2]int{5, 4}: + return treasureTable.ValuableMaterial(t.Roller.TableRoll()) + } + return data.Tables.Maze.DungeonRewards[roll[0]-1][roll[1]-1] +} + +func (t MazeTable) DungeonActivity(roll [2]int) string { + cityTable := CityTable{Roller: t.Roller} + monTable := MonsterTable{Roller: t.Roller} + switch roll { + case [2]int{1, 3}: + return cityTable.CityActivity(t.Roller.TableRoll()) + case [2]int{1, 3}: + return monTable.Tactic(t.Roller.TableRoll()) + case [2]int{6, 5}: + return monTable.Tactic(t.Roller.TableRoll()) + } + return data.Tables.Maze.DungeonActivities[roll[0]-1][roll[1]-1] +} + +func (t MazeTable) DungeonRoom(roll [2]int) string { + cityTable := CityTable{Roller: t.Roller} + switch roll { + case [2]int{1, 4}: + return cityTable.BuildingRoom(t.Roller.TableRoll()) + case [2]int{3, 5}: + return cityTable.LowerClassBuilding(t.Roller.TableRoll()).Type + case [2]int{6, 3}: + return cityTable.UpperClassBuilding(t.Roller.TableRoll()).Type + } + return data.Tables.Maze.DungeonRooms[roll[0]-1][roll[1]-1] +} + +func (t MazeTable) DungeonRoomDetail(roll [2]int) string { + return data.Tables.Maze.DungeonRoomDetails[roll[0]-1][roll[1]-1] +} + +func (t MazeTable) DungeonTrick(roll [2]int) string { + magicTable := MagicTable{Roller: t.Roller} + npcTable := NPCTable{Roller: t.Roller} + switch roll { + case [2]int{2, 6}: + return magicTable.EtherealEffect(t.Roller.TableRoll()) + case [2]int{3, 6}: + return npcTable.Mission(t.Roller.TableRoll()) + case [2]int{4, 3}: + return magicTable.PhysicalEffect(t.Roller.TableRoll()) + default: + return data.Tables.Maze.DungeonTricks[roll[0]-1][roll[1]-1] + } +} + +func (t MazeTable) DungeonHazard(roll [2]int) string { + return data.Tables.Maze.DungeonHazards[roll[0]-1][roll[1]-1] +} + +func (t MazeTable) TrapEffect(roll [2]int) string { + switch roll { + case [2]int{4, 5}: + roll, _ := t.Roller.Roll("1d6") + return MonsterTable{Roller: t.Roller}.Base(roll[0]) + " freed" + default: + return data.Tables.Maze.TrapEffects[roll[0]-1][roll[1]-1] + } +} + +func (t MazeTable) TrapTrigger(roll [2]int) string { + return data.Tables.Maze.TrapTriggers[roll[0]-1][roll[1]-1] +} diff --git a/internal/tables/monster.go b/internal/tables/monster.go new file mode 100644 index 0000000..2dab01f --- /dev/null +++ b/internal/tables/monster.go @@ -0,0 +1,310 @@ +package tables + +import ( + "fmt" + "mazeratsgen/internal/data" + "mazeratsgen/internal/dice" + "strings" +) + +type MonsterTable struct { + Roller *dice.Roller +} + +type MonsterStat struct { + Value int + Qualifier string +} + +type MonsterStats struct { + Health MonsterStat + Attack MonsterStat + Armor MonsterStat + STR MonsterStat + DEX MonsterStat + WIL MonsterStat +} + +type Monster struct { + Base string + Stats MonsterStats + Feature string + Trait string + Ability string + Tactics string + Personality string + Weakness string + Seed int64 +} + +func (t *MonsterTable) Generate() Monster { + baseRoll, _ := t.Roller.Roll("1d6") + return Monster{ + Base: t.Base(baseRoll[0]), + Stats: t.genStats(), + Feature: t.Feature(t.Roller.TableRoll()), + Trait: t.Trait(t.Roller.TableRoll()), + Ability: t.Ability(t.Roller.TableRoll()), + Tactics: t.Tactic(t.Roller.TableRoll()), + Personality: t.Personality(t.Roller.TableRoll()), + Weakness: t.Weakness(t.Roller.TableRoll()), + Seed: t.Roller.Seed, + } +} + +func (t *MonsterTable) Template() string { + return strings.TrimSpace(` +Type: {{.Trait}} {{.Base}} +Stats: + Health: {{.Stats.Health.Value}} ({{.Stats.Health.Qualifier}}) + Armor: {{.Stats.Armor.Value}} ({{.Stats.Armor.Qualifier}}) + Attack: +{{.Stats.Attack.Value}} ({{.Stats.Attack.Qualifier}}) + STR: +{{.Stats.STR.Value}} ({{.Stats.STR.Qualifier}}) + DEX: +{{.Stats.DEX.Value}} ({{.Stats.DEX.Qualifier}}) + WIL: +{{.Stats.WIL.Value}} ({{.Stats.WIL.Qualifier}}) +Feature: {{.Feature}} +Ability: {{.Ability}} +Tactics: {{.Tactics}} +Personality: {{.Personality}} +Weakness: {{.Weakness}} +Seed: {{.Seed}} +`) +} + +func (t MonsterTable) Weakness(roll [2]int) string { + magicTable := MagicTable{Roller: t.Roller} + treasureTable := TreasureTable{Roller: t.Roller} + switch roll { + case [2]int{3, 5}: + return magicTable.Insanity(t.Roller.TableRoll()) + case [2]int{4, 4}: + return "Pick an existing NPC" + case [2]int{4, 6}: + return magicTable.PhysicalElement(t.Roller.TableRoll()) + case [2]int{6, 2}: + return treasureTable.ValuableMaterial(t.Roller.TableRoll()) + case [2]int{6, 4}: + return treasureTable.WeaponItem(t.Roller.TableRoll()) + default: + return data.Tables.Monster.Weakness[roll[0]-1][roll[1]-1] + } +} + +func (t MonsterTable) genStats() MonsterStats { + return MonsterStats{ + Health: t.genHealth(), + Attack: t.genAttack(), + Armor: t.genArmor(), + STR: t.genSTR(), + DEX: t.genDEX(), + WIL: t.genWIL(), + } +} + +func (t MonsterTable) genHealth() MonsterStat { + typeRoll, _ := t.Roller.Roll("1d5") + mStat := MonsterStat{} + switch typeRoll[0] { + case 1: + mStat.Qualifier = "Weak" + case 2: + mStat.Qualifier = "Typical" + case 3: + mStat.Qualifier = "Tough" + case 4: + mStat.Qualifier = "Hulking" + case 5: + mStat.Qualifier = "Colossal" + } + + hpRoll, _ := t.Roller.Roll(fmt.Sprintf("%vd6", typeRoll[0])) + hp := 0 + for _, hpDie := range hpRoll { + hp += hpDie + } + mStat.Value = hp + return mStat +} + +func (t MonsterTable) genArmor() MonsterStat { + typeRoll, _ := t.Roller.Roll("1d5") + mStat := MonsterStat{} + switch typeRoll[0] { + case 1: + mStat.Qualifier = "Unarmored" + mStat.Value = 6 + case 2: + mStat.Qualifier = "Light protection" + mStat.Value = 7 + case 3: + mStat.Qualifier = "Moderate protection" + mStat.Value = 8 + case 4: + mStat.Qualifier = "Heavy protection" + mStat.Value = 9 + case 5: + mStat.Value = 10 + mStat.Qualifier = "Nigh impervious" + } + + return mStat +} + +func (t MonsterTable) genAttack() MonsterStat { + typeRoll, _ := t.Roller.Roll("1d5") + mStat := MonsterStat{} + switch typeRoll[0] { + case 1: + mStat.Qualifier = "Untrained" + mStat.Value = 0 + case 2: + mStat.Qualifier = "Trained" + mStat.Value = 1 + case 3: + mStat.Qualifier = "Dangerous" + mStat.Value = 2 + case 4: + mStat.Qualifier = "Masterful" + mStat.Value = 3 + case 5: + mStat.Value = 4 + mStat.Qualifier = "Lethal" + } + + return mStat +} + +func (t MonsterTable) genSTR() MonsterStat { + typeRoll, _ := t.Roller.Roll("1d5") + mStat := MonsterStat{} + switch typeRoll[0] { + case 1: + mStat.Qualifier = "Weak" + mStat.Value = 0 + case 2: + mStat.Qualifier = "Average" + mStat.Value = 1 + case 3: + mStat.Qualifier = "Strong" + mStat.Value = 2 + case 4: + mStat.Qualifier = "Powerful" + mStat.Value = 3 + case 5: + mStat.Value = 4 + mStat.Qualifier = "Monstrous" + } + + return mStat +} + +func (t MonsterTable) genDEX() MonsterStat { + typeRoll, _ := t.Roller.Roll("1d5") + mStat := MonsterStat{} + switch typeRoll[0] { + case 1: + mStat.Qualifier = "Slow" + mStat.Value = 0 + case 2: + mStat.Qualifier = "Average" + mStat.Value = 1 + case 3: + mStat.Qualifier = "Nimble" + mStat.Value = 2 + case 4: + mStat.Qualifier = "Swift" + mStat.Value = 3 + case 5: + mStat.Value = 4 + mStat.Qualifier = "Blurred" + } + + return mStat +} + +func (t MonsterTable) genWIL() MonsterStat { + typeRoll, _ := t.Roller.Roll("1d5") + mStat := MonsterStat{} + switch typeRoll[0] { + case 1: + mStat.Qualifier = "Dimwitted" + mStat.Value = 0 + case 2: + mStat.Qualifier = "Average" + mStat.Value = 1 + case 3: + mStat.Qualifier = "Clever" + mStat.Value = 2 + case 4: + mStat.Qualifier = "Brilliant" + mStat.Value = 3 + case 5: + mStat.Value = 4 + mStat.Qualifier = "Genius" + } + + return mStat +} + +func (t MonsterTable) Base(roll int) string { + var base string + + switch roll { + case 1, 2: + base = t.AerialAnimals(t.Roller.TableRoll()) + case 3, 4: + base = t.TerrestrialAnimals(t.Roller.TableRoll()) + case 5, 6: + base = t.AquaticAnimals(t.Roller.TableRoll()) + } + + return base +} + +func (t MonsterTable) AerialAnimals(roll [2]int) string { + return data.Tables.Monster.Aerial[roll[0]-1][roll[1]-1] +} + +func (t MonsterTable) TerrestrialAnimals(roll [2]int) string { + return data.Tables.Monster.Terrestrial[roll[0]-1][roll[1]-1] +} + +func (t MonsterTable) AquaticAnimals(roll [2]int) string { + return data.Tables.Monster.Aquatic[roll[0]-1][roll[1]-1] +} + +func (t MonsterTable) Tactic(roll [2]int) string { + return data.Tables.Monster.Tactics[roll[0]-1][roll[1]-1] +} + +func (t MonsterTable) Feature(roll [2]int) string { + return data.Tables.Monster.Features[roll[0]-1][roll[1]-1] +} + +func (t MonsterTable) Personality(roll [2]int) string { + return data.Tables.Monster.Personality[roll[0]-1][roll[1]-1] +} + +func (t MonsterTable) Ability(roll [2]int) string { + magicTable := MagicTable{Roller: t.Roller} + switch roll { + case [2]int{2, 4}: + return magicTable.EtherealElement(t.Roller.TableRoll()) + case [2]int{4, 5}: + return magicTable.PhysicalElement(t.Roller.TableRoll()) + default: + return data.Tables.Monster.Abilities[roll[0]-1][roll[1]-1] + } +} + +func (t MonsterTable) Trait(roll [2]int) string { + magicTable := MagicTable{Roller: t.Roller} + switch roll { + case [2]int{2, 3}: + return magicTable.EtherealElement(t.Roller.TableRoll()) + case [2]int{5, 1}: + return magicTable.PhysicalElement(t.Roller.TableRoll()) + default: + return data.Tables.Monster.Traits[roll[0]-1][roll[1]-1] + } +} diff --git a/internal/tables/monster_test.go b/internal/tables/monster_test.go new file mode 100644 index 0000000..79c86c0 --- /dev/null +++ b/internal/tables/monster_test.go @@ -0,0 +1,18 @@ +package tables + +import ( + "mazeratsgen/internal/dice" + "testing" +) + +func TestMonsterGenMethods(t *testing.T) { + roller := dice.NewRoller(1) + table := MonsterTable{Roller: roller} + table.Weakness(roller.TableRoll()) + table.Personality(roller.TableRoll()) + table.Tactic(roller.TableRoll()) + table.Ability(roller.TableRoll()) + table.Trait(roller.TableRoll()) + table.Feature(roller.TableRoll()) + table.Base(roller.TableRoll()[0]) // TODO: Test all 3 paths +} diff --git a/internal/tables/npc.go b/internal/tables/npc.go new file mode 100644 index 0000000..c06c1b9 --- /dev/null +++ b/internal/tables/npc.go @@ -0,0 +1,252 @@ +package tables + +import ( + "mazeratsgen/internal/data" + "mazeratsgen/internal/dice" + "mazeratsgen/internal/helpers" +) + +type NPCTable struct { + Roller *dice.Roller +} + +type NPC struct { + Name string + Class string + Occupation string + Gender string + Appearance string + PhysicalDetail string + Clothing string + Personality string + Mannerism string + Secret string + Reputation string + Relationship string + Hobby string + DivineDomain string + AfterTheParty string + Assets []string + Liabilities []string + Goals []string + Misfortunes []string + Missions []string + Methods []string +} + +func GenNPC(seed int64) NPC { + roller := dice.NewRoller(seed) + npcTable := NPCTable{Roller: roller} + var occupation, class, gender string + + occupationRoll, _ := roller.Roll("1d3") + switch occupationRoll[0] { + case 1: + occupation = npcTable.CivilizedNPC(roller.TableRoll()) + case 2: + occupation = npcTable.UnderworldNPC(roller.TableRoll()) + case 3: + occupation = npcTable.WildernessNPC(roller.TableRoll()) + } + + classRoll, _ := roller.Roll("1d2") + if classRoll[0] == 1 { + class = "Upperclass" + } else { + class = "Lowerclass" + } + + genderRoll, _ := roller.Roll("1d2") + if genderRoll[0] == 1 { + gender = "Male" + } else { + gender = "Female" + } + + return NPC{ + Name: GenName(class, gender, seed).FullName, + Occupation: occupation, + Class: class, + Gender: gender, + Appearance: npcTable.Appearance(roller.TableRoll()), + PhysicalDetail: npcTable.PhysicalDetail(roller.TableRoll()), + Clothing: npcTable.Clothing(roller.TableRoll()), + Personality: npcTable.Personality(roller.TableRoll()), + Mannerism: npcTable.Mannerism(roller.TableRoll()), + Secret: npcTable.Secret(roller.TableRoll()), + Reputation: npcTable.Reputation(roller.TableRoll()), + Relationship: npcTable.Relationship(roller.TableRoll()), + Hobby: npcTable.Hobby(roller.TableRoll()), + DivineDomain: npcTable.DivineDomain(roller.TableRoll()), + AfterTheParty: npcTable.AfterTheParty(roller.TableRoll()), + Assets: helpers.GenUniqueItems(3, npcTable.Asset, seed), + Liabilities: helpers.GenUniqueItems(3, npcTable.Liability, seed), + Goals: helpers.GenUniqueItems(3, npcTable.NPCGoal, seed), + Misfortunes: helpers.GenUniqueItems(3, npcTable.Misfortune, seed), + Missions: helpers.GenUniqueItems(3, npcTable.Mission, seed), + Methods: helpers.GenUniqueItems(3, npcTable.Method, seed), + } +} + +func (t NPCTable) CivilizedNPC(tableRole [2]int) string { + return data.Tables.NPC.CivilizedNPCs[tableRole[0]-1][tableRole[1]-1] +} + +func (t NPCTable) UnderworldNPC(tableRole [2]int) string { + return data.Tables.NPC.UnderworldNPCs[tableRole[0]-1][tableRole[1]-1] +} + +func (t NPCTable) WildernessNPC(tableRole [2]int) string { + return data.Tables.NPC.WildernessNPCs[tableRole[0]-1][tableRole[1]-1] +} + +func (t NPCTable) FemaleName(tableRole [2]int) string { + return data.Tables.NPC.FemaleNames[tableRole[0]-1][tableRole[1]-1] +} + +func (t NPCTable) MaleName(tableRole [2]int) string { + return data.Tables.NPC.MaleNames[tableRole[0]-1][tableRole[1]-1] +} + +func (t NPCTable) UpperClassSurname(tableRole [2]int) string { + return data.Tables.NPC.UpperClassSurnames[tableRole[0]-1][tableRole[1]-1] +} + +func (t NPCTable) LowerClassSurname(tableRole [2]int) string { + return data.Tables.NPC.LowerClassSurnames[tableRole[0]-1][tableRole[1]-1] +} + +func (t NPCTable) Asset(tableRole [2]int) string { + switch tableRole { + case [2]int{2, 3}: + return "Leader of existing faction" + case [2]int{2, 4}: + return "Member of existing faction" + default: + return data.Tables.NPC.Assets[tableRole[0]-1][tableRole[1]-1] + } +} + +func (t NPCTable) Liability(tableRole [2]int) string { + switch tableRole { + case [2]int{3, 1}: + return MagicTable{Roller: t.Roller}.Insanity(t.Roller.TableRoll()) + default: + return data.Tables.NPC.Liabilities[tableRole[0]-1][tableRole[1]-1] + } +} + +func (t NPCTable) NPCGoal(tableRole [2]int) string { + treasureTable := TreasureTable{Roller: t.Roller} + switch tableRole { + case [2]int{1, 3}: + return "Acquire " + treasureTable.TreasureItem(t.Roller.TableRoll()) + case [2]int{1, 4}: + return "Craft " + treasureTable.TreasureItem(t.Roller.TableRoll()) + case [2]int{1, 5}: + return "Destroy an existing faction" + case [2]int{1, 6}: + return "Destroy " + treasureTable.TreasureItem(t.Roller.TableRoll()) + case [2]int{2, 3}: + return "Found a faction" + case [2]int{2, 6}: + return "Impress an existing NPC" + case [2]int{3, 2}: + return "Infiltrate an existing faction" + case [2]int{3, 4}: + return "Kidnap an existing NPC" + case [2]int{3, 5}: + return "Lead an existing faction" + case [2]int{4, 1}: + return "Locate an existing NPC" + case [2]int{4, 6}: + return "Rescue an existing NPC" + case [2]int{5, 2}: + return "Restore an existing faction" + case [2]int{5, 5}: + return "Sabotage an existing faction" + case [2]int{6, 2}: + return "Serve an existing faction" + default: + return data.Tables.NPC.NPCGoals[tableRole[0]-1][tableRole[1]-1] + } +} + +func (t NPCTable) Misfortune(tableRole [2]int) string { + return data.Tables.NPC.Misfortunes[tableRole[0]-1][tableRole[1]-1] +} + +func (t NPCTable) Mission(tableRole [2]int) string { + return data.Tables.NPC.Missions[tableRole[0]-1][tableRole[1]-1] +} + +func (t NPCTable) Method(tableRole [2]int) string { + return data.Tables.NPC.Methods[tableRole[0]-1][tableRole[1]-1] +} + +func (t NPCTable) Appearance(tableRole [2]int) string { + return data.Tables.NPC.Appearances[tableRole[0]-1][tableRole[1]-1] +} + +func (t NPCTable) PhysicalDetail(tableRole [2]int) string { + return data.Tables.NPC.PhysicalDetails[tableRole[0]-1][tableRole[1]-1] +} + +func (t NPCTable) Clothing(tableRole [2]int) string { + return data.Tables.NPC.Clothing[tableRole[0]-1][tableRole[1]-1] +} + +func (t NPCTable) Personality(tableRole [2]int) string { + return data.Tables.NPC.Personalities[tableRole[0]-1][tableRole[1]-1] +} + +func (t NPCTable) Mannerism(tableRole [2]int) string { + return data.Tables.NPC.Mannerisms[tableRole[0]-1][tableRole[1]-1] +} + +func (t NPCTable) Secret(tableRole [2]int) string { + switch tableRole { + case [2]int{4, 5}: + return t.Misfortune(t.Roller.TableRoll()) + case [2]int{5, 2}: + return "An existing NPC" + default: + return data.Tables.NPC.Secrets[tableRole[0]-1][tableRole[1]-1] + } +} + +func (t NPCTable) Reputation(tableRole [2]int) string { + return data.Tables.NPC.Reputations[tableRole[0]-1][tableRole[1]-1] +} + +func (t NPCTable) Hobby(tableRole [2]int) string { + return data.Tables.NPC.Hobbies[tableRole[0]-1][tableRole[1]-1] +} + +func (t NPCTable) Relationship(tableRole [2]int) string { + return data.Tables.NPC.Relationships[tableRole[0]-1][tableRole[1]-1] +} + +func (t NPCTable) DivineDomain(tableRole [2]int) string { + switch tableRole { + case [2]int{1, 1}: + roll, _ := t.Roller.Roll("1d6") + return MonsterTable{Roller: t.Roller}.Base(roll[0]) + case [2]int{2, 5}: + roll, _ := t.Roller.Roll("1d6") + return MagicTable{Roller: t.Roller}.Element(roll[0]) + case [2]int{4, 1}: + return "An existing NPC" + default: + return data.Tables.NPC.DivineDomains[tableRole[0]-1][tableRole[1]-1] + } +} + +func (t NPCTable) AfterTheParty(tableRole [2]int) string { + switch tableRole { + case [2]int{3, 3}: + return "Insulted an existing faction" + default: + return data.Tables.NPC.AfterTheParty[tableRole[0]-1][tableRole[1]-1] + } +} diff --git a/internal/tables/npc_test.go b/internal/tables/npc_test.go new file mode 100644 index 0000000..808b2f8 --- /dev/null +++ b/internal/tables/npc_test.go @@ -0,0 +1,85 @@ +package tables + +import ( + "mazeratsgen/internal/dice" + "testing" +) + +func TestNPCGenMethods(t *testing.T) { + roller := dice.NewRoller(1) + table := NPCTable{Roller: roller} + table.CivilizedNPC(roller.TableRoll()) + table.UnderworldNPC(roller.TableRoll()) + table.WildernessNPC(roller.TableRoll()) + table.FemaleName(roller.TableRoll()) + table.MaleName(roller.TableRoll()) + table.UpperClassSurname(roller.TableRoll()) + table.LowerClassSurname(roller.TableRoll()) + table.Asset(roller.TableRoll()) + table.Liability(roller.TableRoll()) + table.NPCGoal(roller.TableRoll()) + table.Misfortune(roller.TableRoll()) + table.Mission(roller.TableRoll()) + table.Method(roller.TableRoll()) + table.Appearance(roller.TableRoll()) + table.PhysicalDetail(roller.TableRoll()) + table.Clothing(roller.TableRoll()) + table.Personality(roller.TableRoll()) + table.Mannerism(roller.TableRoll()) + table.Secret(roller.TableRoll()) + table.Hobby(roller.TableRoll()) + table.Reputation(roller.TableRoll()) + table.DivineDomain(roller.TableRoll()) + table.AfterTheParty(roller.TableRoll()) +} + +func TestForEXTERNALs(t *testing.T) { + t.Parallel() + + roller := dice.NewRoller(1) + table := NPCTable{Roller: roller} + + tests := []struct { + Name string + Func func([2]int) string + }{ + {Name: "Secret", Func: table.Secret}, + {Name: "CivilizedNPC", Func: table.CivilizedNPC}, + {Name: "UnderworldNPC", Func: table.UnderworldNPC}, + {Name: "WildernessNPC", Func: table.WildernessNPC}, + {Name: "FemaleName", Func: table.FemaleName}, + {Name: "MaleName", Func: table.MaleName}, + {Name: "UpperClassName", Func: table.UpperClassSurname}, + {Name: "LowerClassName", Func: table.LowerClassSurname}, + {Name: "Asset", Func: table.Asset}, + {Name: "Liability", Func: table.Liability}, + {Name: "NPCGoal", Func: table.NPCGoal}, + {Name: "Misfortune", Func: table.Misfortune}, + {Name: "Mission", Func: table.Mission}, + {Name: "Method", Func: table.Method}, + {Name: "Appearance", Func: table.Appearance}, + {Name: "PhysicalDetail", Func: table.PhysicalDetail}, + {Name: "Clothing", Func: table.Clothing}, + {Name: "Personality", Func: table.Personality}, + {Name: "Mannerism", Func: table.Mannerism}, + {Name: "Hobby", Func: table.Hobby}, + {Name: "Reputation", Func: table.Reputation}, + {Name: "DivineDomain", Func: table.DivineDomain}, + {Name: "AfterTheParty", Func: table.AfterTheParty}, + } + + t.Run("No EXTERNALs", func(t *testing.T) { + t.Parallel() + for _, fTest := range tests { + for x := 1; x <= 6; x++ { + for y := 1; y <= 6; y++ { + result := fTest.Func([2]int{x, y}) + if result == "EXTERNAL" { + t.Errorf("Expected roll %v(%v,%v) to not equal 'EXTERNAL'", + fTest.Name, x, y) + } + } + } + } + }) +} diff --git a/internal/tables/tables.go b/internal/tables/tables.go new file mode 100644 index 0000000..05b8216 --- /dev/null +++ b/internal/tables/tables.go @@ -0,0 +1,83 @@ +package tables + +import ( + "bytes" + "encoding/json" + "mazeratsgen/internal/dice" + "text/template" +) + +// TODO: Add GenRandomName + +type Name struct { + FirstName string + LastName string + FullName string + Gender string + Class string + Seed int64 +} + +func GenRandomName(seed int64) Name { + var class string + var gender string + + roller := dice.NewRoller(seed) + + classRoll, _ := roller.Roll("1d2") + if classRoll[0] == 1 { + class = "Upperclass" + } else { + class = "Lowerclass" + } + + genderRoll, _ := roller.Roll("1d2") + if genderRoll[0] == 1 { + gender = "Male" + } else { + gender = "Female" + } + + return GenName(class, gender, seed) +} + +func GenName(gender string, class string, seed int64) Name { + name := Name{Seed: seed} + roller := dice.NewRoller(seed) + npcTable := NPCTable{Roller: roller} + if gender == "Male" { + name.Gender = "Male" + name.FirstName = npcTable.MaleName(roller.TableRoll()) + } else { + name.Gender = "Female" + name.FirstName = npcTable.FemaleName(roller.TableRoll()) + } + if class == "Upper" { + name.Class = "Upper" + name.LastName = npcTable.UpperClassSurname(roller.TableRoll()) + } else { + name.Class = "Lower" + name.LastName = npcTable.LowerClassSurname(roller.TableRoll()) + } + name.FullName = name.FirstName + " " + name.LastName + return name +} + +// ConvertToJSON takes a interface and unmarshals it +func ConvertToJSON(o interface{}) ([]byte, error) { + json, err := json.MarshalIndent(o, "", " ") + if err != nil { + return []byte{}, err + } + return json, nil +} + +func ConvertToText(o interface{}, t string) (string, error) { + tmpl, _ := template.New("textTemplate").Parse(t) + var d bytes.Buffer + err := tmpl.Execute(&d, &o) + if err != nil { + return "", err + } + return d.String(), nil +} diff --git a/internal/tables/treasure.go b/internal/tables/treasure.go new file mode 100644 index 0000000..de865e9 --- /dev/null +++ b/internal/tables/treasure.go @@ -0,0 +1,149 @@ +package tables + +import ( + "mazeratsgen/internal/data" + "mazeratsgen/internal/dice" + "mazeratsgen/internal/helpers" +) + +type TreasureTable struct { + Roller *dice.Roller +} + +type Potion struct { + Effect string + Ingredients []string + OnFailure string +} + +func GenTreasure(seed int64) string { + roller := dice.NewRoller(seed) + treasureTable := TreasureTable{Roller: roller} + trait := treasureTable.TreasureTrait(roller.TableRoll()) + item := treasureTable.TreasureItem(roller.TableRoll()) + return trait + " " + item +} + +func GenPotion(seed int64) Potion { + roller := dice.NewRoller(seed) + magicTable := MagicTable{Roller: roller} + treasureTable := TreasureTable{Roller: roller} + var onFailure string + onFailRoll, _ := roller.Roll("1d2") + if onFailRoll[0] == 1 { + onFailure = magicTable.Mutation(roller.TableRoll()) + } else { + onFailure = magicTable.Insanity(roller.TableRoll()) + } + + ingredientRoll, _ := roller.Roll("1d3") + + return Potion{ + Effect: treasureTable.PotionBase(roller.TableRoll()), + OnFailure: onFailure, + Ingredients: helpers.GenUniqueItems(ingredientRoll[0], treasureTable.MagicalIngredient, seed), + } +} + +func (t TreasureTable) PotionBase(roll [2]int) string { + monTable := MonsterTable{Roller: t.Roller} + magicTable := MagicTable{Roller: t.Roller} + + switch roll { + case [2]int{1, 1}: + roll, _ := t.Roller.Roll("1d6") + return monTable.Base(roll[0]) + " Form" + case [2]int{1, 5}: + roll, _ := t.Roller.Roll("1d6") + return "Control " + magicTable.Element(roll[0]) + case [2]int{2, 5}: + roll, _ := t.Roller.Roll("1d6") + return magicTable.Element(roll[0]) + " Form" + case [2]int{3, 5}: + return magicTable.Insanity(t.Roller.TableRoll()) + case [2]int{4, 1}: + return t.TreasureItem(t.Roller.TableRoll()) + " Form" + case [2]int{4, 4}: + return monTable.Ability(t.Roller.TableRoll()) + case [2]int{4, 5}: + return monTable.Feature(t.Roller.TableRoll()) + case [2]int{4, 6}: + return monTable.Trait(t.Roller.TableRoll()) + case [2]int{5, 1}: + return magicTable.Mutation(t.Roller.TableRoll()) + case [2]int{5, 3}: + return magicTable.Spell(t.Roller.TableRoll()) + default: + return data.Tables.Treasure.Potions[roll[0]-1][roll[1]-1] + } +} + +func (t TreasureTable) MiscItem(roll [2]int) string { + return data.Tables.Treasure.MiscItems[roll[0]-1][roll[1]-1] +} + +func (t TreasureTable) WornItem(roll [2]int) string { + return data.Tables.Treasure.WornItems[roll[0]-1][roll[1]-1] +} + +func (t TreasureTable) WeaponItem(roll [2]int) string { + return data.Tables.Treasure.WeaponItems[roll[0]-1][roll[1]-1] +} + +func (t TreasureTable) BookSubject(roll [2]int) string { + return data.Tables.Treasure.BookSubjects[roll[0]-1][roll[1]-1] +} + +func (t TreasureTable) ToolItem(roll [2]int) string { + return data.Tables.Treasure.ToolItems[roll[0]-1][roll[1]-1] +} + +func (t TreasureTable) MagicalIngredient(roll [2]int) string { + monTable := MonsterTable{Roller: t.Roller} + wildTable := WildTable{Roller: t.Roller} + magicTable := MagicTable{Roller: t.Roller} + treasureTable := TreasureTable{Roller: t.Roller} + switch roll { + case [2]int{1, 2}: + baseRoll, _ := t.Roller.Roll("1d6") + return monTable.Base(baseRoll[0]) + case [2]int{1, 5}: + return t.BookSubject(t.Roller.TableRoll()) + " page" + case [2]int{2, 5}: + return wildTable.EdiblePlant(t.Roller.TableRoll()) + case [2]int{4, 2}: + return monTable.Feature(t.Roller.TableRoll()) + case [2]int{4, 5}: + return magicTable.PhysicalElement(t.Roller.TableRoll()) + case [2]int{4, 6}: + return wildTable.PoisonousPlant(t.Roller.TableRoll()) + case [2]int{5, 1}: + return treasureTable.PotionBase(t.Roller.TableRoll()) + case [2]int{6, 3}: + return treasureTable.ValuableMaterial(t.Roller.TableRoll()) + default: + return data.Tables.Treasure.MagicalIngredients[roll[0]-1][roll[1]-1] + } +} + +func (t TreasureTable) TreasureItem(roll [2]int) string { + return data.Tables.Treasure.TreasureItems[roll[0]-1][roll[1]-1] +} + +func (t TreasureTable) TreasureTrait(roll [2]int) string { + magicTable := MagicTable{Roller: t.Roller} + switch roll { + case [2]int{2, 6}: + effectRoll, _ := t.Roller.Roll("1d6") + return magicTable.Effect(effectRoll[0]) + case [2]int{3, 1}: + effectRoll, _ := t.Roller.Roll("1d6") + return magicTable.Effect(effectRoll[0]) + default: + return data.Tables.Treasure.TreasureItems[roll[0]-1][roll[1]-1] + } +} + +func (t TreasureTable) ValuableMaterial(roll [2]int) string { + return data.Tables.Treasure.ValuableMaterials[roll[0]-1][roll[1]-1] +} diff --git a/internal/tables/wild.go b/internal/tables/wild.go new file mode 100644 index 0000000..0526ec0 --- /dev/null +++ b/internal/tables/wild.go @@ -0,0 +1,183 @@ +package tables + +import ( + "mazeratsgen/internal/data" + "mazeratsgen/internal/dice" + "mazeratsgen/internal/helpers" +) + +type WildTable struct { + Roller *dice.Roller +} + +type Inn struct { + Name string + Quirk string +} + +type Wild struct { + Region string + Landmark string + Trait string + Structures []string + Discoveries []string + Activities []string + Hazards []string + WildernessHazards []string + EdiblePlants []string + PoisonousPlants []string + Inns []Inn +} + +// TODO: Support two nouns +func GenInn(seed int64) Inn { + roller := dice.NewRoller(seed) + wildTable := WildTable{Roller: roller} + adjective := wildTable.InnAdjective(roller.TableRoll()) + noun := wildTable.InnNoun(roller.TableRoll()) + quirk := wildTable.InnQuirk(roller.TableRoll()) + return Inn{ + Name: adjective + " " + noun, + Quirk: quirk, + } +} + +func GenInnName(seed int64) string { + inn := GenInn(seed) + return inn.Name + " (" + inn.Quirk + ")" +} + +func GenWild(seed int64) Wild { + roller := dice.NewRoller(seed) + wildTable := WildTable{Roller: roller} + + // TODO: Shouldn't this be genUnique + var inns []Inn + for i := 0; i < 4; i++ { + inns = append(inns, GenInn(seed)) + } + + return Wild{ + Region: wildTable.WildernessRegion(roller.TableRoll()), + Landmark: wildTable.WildernessLandmark(roller.TableRoll()), + Trait: wildTable.WildernessRegionTrait(roller.TableRoll()), + Structures: helpers.GenUniqueItems(5, wildTable.WildernessStructure, seed), + Discoveries: helpers.GenUniqueItems(5, wildTable.WildernessDiscovery, seed), + Activities: helpers.GenUniqueItems(5, wildTable.WildernessActivity, seed), + Hazards: helpers.GenUniqueItems(5, wildTable.WildernessHazard, seed), + EdiblePlants: helpers.GenUniqueItems(5, wildTable.EdiblePlant, seed), + PoisonousPlants: helpers.GenUniqueItems(5, wildTable.PoisonousPlant, seed), + Inns: inns, + } +} + +func (t WildTable) WildernessRegion(roll [2]int) string { + return data.Tables.Wild.WildernessRegions[roll[0]-1][roll[1]-1] +} + +func (t WildTable) WildernessLandmark(roll [2]int) string { + return data.Tables.Wild.WildernessLandmarks[roll[0]-1][roll[1]-1] +} + +func (t WildTable) WildernessStructure(roll [2]int) string { + return data.Tables.Wild.WildernessStructures[roll[0]-1][roll[1]-1] +} + +func (t WildTable) WildernessRegionTrait(roll [2]int) string { + mazeTable := MazeTable{Roller: t.Roller} + magicTable := MagicTable{Roller: t.Roller} + switch roll { + case [2]int{2, 3}: + return mazeTable.DungeonForm(t.Roller.TableRoll()) + case [2]int{2, 4}: + return magicTable.EtherealEffect(t.Roller.TableRoll()) + case [2]int{6, 4}: + return magicTable.PhysicalEffect(t.Roller.TableRoll()) + default: + return data.Tables.Wild.WildernessRegionTraits[roll[0]-1][roll[1]-1] + } +} + +func (t WildTable) WildernessDiscovery(roll [2]int) string { + switch roll { + case [2]int{1, 5}: + return CityTable{Roller: t.Roller}.CityActivity(t.Roller.TableRoll()) + case [2]int{1, 6}: + return NPCTable{Roller: t.Roller}.CivilizedNPC(t.Roller.TableRoll()) + case [2]int{2, 3}: + return MazeTable{Roller: t.Roller}.DungeonActivity(t.Roller.TableRoll()) + case [2]int{3, 1}: + return TreasureTable{Roller: t.Roller}.TreasureItem(t.Roller.TableRoll()) + case [2]int{1, 3}: + return "Lost an existing NPC" + case [2]int{4, 1}: + return MagicTable{Roller: t.Roller}.Mutation(t.Roller.TableRoll()) + case [2]int{5, 1}: + return "Lost an existing NPC" + case [2]int{6, 1}: + return NPCTable{Roller: t.Roller}.UnderworldNPC(t.Roller.TableRoll()) + case [2]int{6, 2}: + return WildTable{Roller: t.Roller}.WildernessActivity(t.Roller.TableRoll()) + case [2]int{6, 3}: + return WildTable{Roller: t.Roller}.WildernessLandmark(t.Roller.TableRoll()) + case [2]int{6, 4}: + return WildTable{Roller: t.Roller}.WildernessStructure(t.Roller.TableRoll()) + case [2]int{6, 5}: + return NPCTable{Roller: t.Roller}.WildernessNPC(t.Roller.TableRoll()) + default: + return data.Tables.Wild.WildernessDiscoveries[roll[0]-1][roll[1]-1] + } +} + +func (t WildTable) WildernessActivity(roll [2]int) string { + switch roll { + case [2]int{2, 1}: + return CityTable{Roller: t.Roller}.CityActivity(t.Roller.TableRoll()) + case [2]int{2, 6}: + return MazeTable{Roller: t.Roller}.DungeonActivity(t.Roller.TableRoll()) + default: + return data.Tables.Wild.WildernessActivities[roll[0]-1][roll[1]-1] + } +} + +func (t WildTable) WildernessHazard(roll [2]int) string { + return data.Tables.Wild.WildernessHazards[roll[0]-1][roll[1]-1] +} + +func (t WildTable) EdiblePlant(roll [2]int) string { + return data.Tables.Wild.EdiblePlants[roll[0]-1][roll[1]-1] +} + +func (t WildTable) PoisonousPlant(roll [2]int) string { + return data.Tables.Wild.PoisonousPlants[roll[0]-1][roll[1]-1] +} + +func (t WildTable) InnAdjective(roll [2]int) string { + return data.Tables.Wild.InnAdjectives[roll[0]-1][roll[1]-1] +} + +func (t WildTable) InnNoun(roll [2]int) string { + return data.Tables.Wild.InnNouns[roll[0]-1][roll[1]-1] +} + +func (t WildTable) InnQuirk(roll [2]int) string { + cityTable := CityTable{Roller: t.Roller} + mazeTable := MazeTable{Roller: t.Roller} + switch roll { + case [2]int{2, 3}: + return cityTable.CityActivity(t.Roller.TableRoll()) + case [2]int{3, 1}: + return mazeTable.DungeonForm(t.Roller.TableRoll()) + case [2]int{3, 3}: + return "An existing faction hangout" + case [2]int{3, 4}: + return cityTable.FactionTrait(t.Roller.TableRoll()) + case [2]int{4, 6}: + buildingRoll, _ := t.Roller.Roll("1d6") + return "Inn/" + cityTable.GenBuilding(buildingRoll[0]).Type + case [2]int{5, 4}: + return "Existing NPC hangout" + default: + return data.Tables.Wild.InnQuirks[roll[0]-1][roll[1]-1] + } +} diff --git a/internal/tables/wild_test.go b/internal/tables/wild_test.go new file mode 100644 index 0000000..700823e --- /dev/null +++ b/internal/tables/wild_test.go @@ -0,0 +1,17 @@ +package tables + +import ( + "mazeratsgen/internal/dice" + . "mazeratsgen/test/helpers" + "testing" +) + +func TestWildMethods(t *testing.T) { + roller := dice.NewRoller(1) + WildTable{Roller: roller}.WildernessRegion(roller.TableRoll()) +} + +func TestMethods(t *testing.T) { + roller := dice.NewRoller(1) + ExactItem(WildTable{Roller: roller}.WildernessRegion([2]int{5, 2}), "Rainforest", t) +} diff --git a/main.go b/main.go new file mode 100644 index 0000000..f0710a0 --- /dev/null +++ b/main.go @@ -0,0 +1,12 @@ +package main + +import ( + "mazeratsgen/cmd" +) + +// @title Maze Rats API +// @BasePath / +// @query.collection.format multi +func main() { + cmd.Execute() +} diff --git a/test/helpers/helpers.go b/test/helpers/helpers.go new file mode 100644 index 0000000..7d7bd2e --- /dev/null +++ b/test/helpers/helpers.go @@ -0,0 +1,19 @@ +package helpers + +import ( + "testing" + "regexp" +) + +func ExactItem(actualResult string, expectedResult string, t *testing.T) { + if actualResult != expectedResult { + t.Errorf("Expected '%v' to equal '%v'", actualResult, expectedResult) + } +} + +func RegexItem(actual string, regex string, t *testing.T) { + re := regexp.MustCompile(regex) + if re.MatchString(actual) != true { + t.Errorf("Expected '%v' to match '%v'", actual, re) + } +} diff --git a/web/swagger/README.md b/web/swagger/README.md new file mode 100644 index 0000000..9607af8 --- /dev/null +++ b/web/swagger/README.md @@ -0,0 +1,4 @@ +# Swagger UI + +Contains static assets and `swagger.json` + diff --git a/web/swagger/custom.css b/web/swagger/custom.css new file mode 100644 index 0000000..95526f7 --- /dev/null +++ b/web/swagger/custom.css @@ -0,0 +1,212 @@ +/* Forgive me for these awful hacks. */ + +body { + background: #000000; +} + +.swagger-ui { + color: #000000; +} + +.swagger-ui a { + color: #00FF00; +} + +.swagger-ui .model, +.swagger-ui .model-title { + color: #00FF00; +} + +.swagger-ui .prop-type { + color: #00FF00; +} + +.swagger-ui section.models, +.swagger-ui section.models.is-open h4, +.swagger-ui section.models h4 { + border-color: #00FF00; + color: #00FF00; +} + +.swagger-ui section.models .model-container:first-of-type { + margin: 0 0 0 20px; +} + +.swagger-ui section.models .model-container { + margin: 0 0 0 20px; +} + +.swagger-ui section.models .model-box { + padding: 2px; +} + +.swagger-ui .info { + margin: 0; +} + +.swagger-ui .info .title { + color: #00FF00; +} + +.swagger-ui .info .base-url { + color: #00FF00; +} + +.swagger-ui .info a { + display: none; +} + +.swagger-ui .info .title small { + background: #005007; +} + +.swagger-ui .info .title small pre { + color: #00FF00; +} + +.swagger-ui .info .title small pre { + color: #00FF00; +} + +.swagger-ui .info p { + color: #00FF00; +} + + +.swagger-ui a.nostyle, +.swagger-ui a.nostyle:active, +.swagger-ui a.nostyle:hover, +.swagger-ui a.nostyle:visited +{ + color: #00FF00; +} + +.swagger-ui .opblock.opblock-get, +.swagger-ui .opblock.opblock-get .opblock-summary { + border-color: #00FF00; + background: #000000; +} + +.swagger-ui .opblock.opblock-get .opblock-summary-method { + background: #007000; + color: #00FF00; +} + +.swagger-ui .opblock-description-wrapper p { + color: #00FF00; +} + +.swagger-ui .opblock .opblock-section-header { + background: #000000; +} + +.swagger-ui .opblock .opblock-summary-description { + color: #00FF00; +} + +.swagger-ui .opblock .opblock-section-header h4 { + color: #00FF00; +} + +.swagger-ui .opblock .opblock-section-header>label { + color: #00FF00; +} + +.swagger-ui .btn { + border-color: #00FF00; + color: #00FF00; +} + +.swagger-ui .btn.cancel { + border-color: #00FF00; + color: #00FF00; +} + +.swagger-ui .btn.execute { + border-color: #00FF00; + background: #000000; + color: #00FF00; +} + +.swagger-ui select, +.swagger-ui select[disabled] { + background: #000000; + border-color: #00FF00; + color: #00FF00; +} + +.swagger-ui .response-col_status, +.swagger-ui .response-col_status .response-undocumented, +.swagger-ui .response-col_description { + color: #00FF00; +} + +.swagger-ui .responses-inner h4, +.swagger-ui .responses-inner h5 { + color: #00FF00; +} + +.swagger-ui textarea.curl { + background: #000000; + border: 1px solid #00FF00; + color: #00FF00; +} + +.swagger-ui .opblock-body pre.microlight { + background: #000000; + border: 1px solid #00FF00; + color: #00FF00; +} + +.swagger-ui .opblock-body pre.microlight span { + color: #00FF00!important; +} + +.swagger-ui .download-contents { + background: #000000; + color: #00FF00; +} + +.swagger-ui .copy-to-clipboard { + background: #000000; + color: #00FF00; +} + +.swagger-ui .copy-to-clipboard button { + background: url('data:image/svg+xml;charset=utf-8,') 50% no-repeat; + color: #00FF00; + margin-right: 10px; +} + +.swagger-ui table thead tr td, +.swagger-ui table thead tr th { + color: #00FF00; +} + +.swagger-ui .parameter__name, +.swagger-ui .parameter__type, +.swagger-ui .parameter__in, +.swagger-ui .markdown p { + color: #00FF00; +} + +.swagger-ui .parameters-col_description input[type=text], +.swagger-ui .parameters-col_description input[type=text]:focus { + outline: 0; + color: #00FF00; + border-color: #00FF00; + background: #000000; +} + +.swagger-ui .parameters-col_description input[type=text]::placeholder, +.swagger-ui .parameter__name.required span, +.swagger-ui .parameter__name.required:after { + color: #00AA00; +} + +.swagger-ui .loading-container .loading::before, +.swagger-ui .loading-container .loading::after { + color: #00FF00; + border-color: #001100; + border-top-color: #00FF00; +} diff --git a/web/swagger/docs.go b/web/swagger/docs.go new file mode 100644 index 0000000..49ed01a --- /dev/null +++ b/web/swagger/docs.go @@ -0,0 +1,504 @@ +// GENERATED BY THE COMMAND ABOVE; DO NOT EDIT +// This file was generated by swaggo/swag + +package swagger + +import ( + "bytes" + "encoding/json" + "strings" + + "github.com/alecthomas/template" + "github.com/swaggo/swag" +) + +var doc = `{ + "schemes": {{ marshal .Schemes }}, + "swagger": "2.0", + "info": { + "description": "{{.Description}}", + "title": "{{.Title}}", + "contact": {}, + "license": {}, + "version": "{{.Version}}" + }, + "host": "{{.Host}}", + "basePath": "{{.BasePath}}", + "paths": { + "/api/character/{seed}": { + "get": { + "produces": [ + "application/json", + " text/plain" + ], + "tags": [ + "character" + ], + "summary": "Generate a specific player character using a seed", + "parameters": [ + { + "type": "integer", + "description": "Int64", + "name": "seed", + "in": "path", + "required": true + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/tables.Character" + } + } + } + } + }, + "/api/city/{seed}": { + "get": { + "produces": [ + "application/json", + " text/plain" + ], + "tags": [ + "city" + ], + "summary": "Generate a specific city using a seed", + "parameters": [ + { + "type": "integer", + "description": "Int64", + "name": "seed", + "in": "path", + "required": true + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/tables.City" + } + } + } + } + }, + "/api/generate/character": { + "get": { + "produces": [ + "application/json", + " text/plain" + ], + "tags": [ + "character" + ], + "summary": "Generate a player character", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/tables.Character" + } + } + } + } + }, + "/api/generate/city": { + "get": { + "produces": [ + "application/json", + " text/plain" + ], + "tags": [ + "city" + ], + "summary": "Generate a city", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/tables.City" + } + } + } + } + }, + "/api/generate/monster": { + "get": { + "produces": [ + "application/json", + " text/plain" + ], + "tags": [ + "monster" + ], + "summary": "Generate a monster", + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/tables.Monster" + } + } + } + } + }, + "/api/generate/name": { + "get": { + "produces": [ + "application/json", + " text/plain" + ], + "tags": [ + "character" + ], + "summary": "Generate a character name", + "responses": { + "200": {} + } + } + }, + "/api/generate/spell": { + "get": { + "produces": [ + "application/json", + " text/plain" + ], + "tags": [ + "magic" + ], + "summary": "Generate a spell", + "responses": { + "200": {} + } + } + }, + "/api/monster/{seed}": { + "get": { + "produces": [ + "application/json", + " text/plain" + ], + "tags": [ + "monster" + ], + "summary": "Generate a specific monster using a seed", + "parameters": [ + { + "type": "integer", + "description": "Int64", + "name": "seed", + "in": "path", + "required": true + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/tables.Monster" + } + } + } + } + }, + "/api/roll/{xdy}": { + "get": { + "produces": [ + "application/json", + " text/plain" + ], + "tags": [ + "dice" + ], + "summary": "Roll some dice", + "parameters": [ + { + "type": "string", + "description": "Roll in xdy format (e.g. 1d6)", + "name": "xdy", + "in": "path", + "required": true + } + ], + "responses": { + "200": {} + } + } + } + }, + "definitions": { + "tables.Building": { + "type": "object", + "properties": { + "rooms": { + "type": "array", + "items": { + "type": "string" + } + }, + "tacticalFeature": { + "type": "string" + }, + "type": { + "type": "string" + } + } + }, + "tables.Character": { + "type": "object", + "properties": { + "appearance": { + "type": "string" + }, + "background": { + "type": "string" + }, + "clothing": { + "type": "string" + }, + "feature": { + "type": "string" + }, + "items": { + "type": "array", + "items": { + "type": "string" + } + }, + "mannerism": { + "type": "string" + }, + "name": { + "type": "string" + }, + "personality": { + "type": "string" + }, + "physical_detail": { + "type": "string" + }, + "seed": { + "type": "integer" + }, + "stats": { + "type": "object", + "$ref": "#/definitions/tables.CharacterStats" + }, + "weapons": { + "type": "array", + "items": { + "type": "string" + } + } + } + }, + "tables.CharacterStats": { + "type": "object", + "properties": { + "armor": { + "type": "integer" + }, + "dex": { + "type": "integer" + }, + "max_health": { + "type": "integer" + }, + "str": { + "type": "integer" + }, + "wil": { + "type": "integer" + } + } + }, + "tables.City": { + "type": "object", + "properties": { + "activities": { + "type": "array", + "items": { + "type": "string" + } + }, + "districtThemes": { + "type": "array", + "items": { + "type": "string" + } + }, + "events": { + "type": "array", + "items": { + "type": "string" + } + }, + "factions": { + "type": "array", + "items": { + "$ref": "#/definitions/tables.Faction" + } + }, + "lowerClassBuildings": { + "type": "array", + "items": { + "$ref": "#/definitions/tables.Building" + } + }, + "seed": { + "type": "integer" + }, + "tacticalStreetFeatures": { + "type": "array", + "items": { + "type": "string" + } + }, + "theme": { + "type": "string" + }, + "upperClassBuildings": { + "type": "array", + "items": { + "$ref": "#/definitions/tables.Building" + } + } + } + }, + "tables.Faction": { + "type": "object", + "properties": { + "goal": { + "type": "string" + }, + "trait": { + "type": "string" + }, + "type": { + "type": "string" + } + } + }, + "tables.Monster": { + "type": "object", + "properties": { + "ability": { + "type": "string" + }, + "base": { + "type": "string" + }, + "feature": { + "type": "string" + }, + "personality": { + "type": "string" + }, + "seed": { + "type": "integer" + }, + "stats": { + "type": "object", + "$ref": "#/definitions/tables.MonsterStats" + }, + "tactics": { + "type": "string" + }, + "trait": { + "type": "string" + }, + "weakness": { + "type": "string" + } + } + }, + "tables.MonsterStat": { + "type": "object", + "properties": { + "qualifier": { + "type": "string" + }, + "value": { + "type": "integer" + } + } + }, + "tables.MonsterStats": { + "type": "object", + "properties": { + "armor": { + "type": "object", + "$ref": "#/definitions/tables.MonsterStat" + }, + "attack": { + "type": "object", + "$ref": "#/definitions/tables.MonsterStat" + }, + "dex": { + "type": "object", + "$ref": "#/definitions/tables.MonsterStat" + }, + "health": { + "type": "object", + "$ref": "#/definitions/tables.MonsterStat" + }, + "str": { + "type": "object", + "$ref": "#/definitions/tables.MonsterStat" + }, + "wil": { + "type": "object", + "$ref": "#/definitions/tables.MonsterStat" + } + } + } + } +}` + +type swaggerInfo struct { + Version string + Host string + BasePath string + Schemes []string + Title string + Description string +} + +// SwaggerInfo holds exported Swagger Info so clients can modify it +var SwaggerInfo = swaggerInfo{ + Version: "", + Host: "", + BasePath: "/", + Schemes: []string{}, + Title: "Maze Rats API", + Description: "", +} + +type s struct{} + +func (s *s) ReadDoc() string { + sInfo := SwaggerInfo + sInfo.Description = strings.Replace(sInfo.Description, "\n", "\\n", -1) + + t, err := template.New("swagger_info").Funcs(template.FuncMap{ + "marshal": func(v interface{}) string { + a, _ := json.Marshal(v) + return string(a) + }, + }).Parse(doc) + if err != nil { + return doc + } + + var tpl bytes.Buffer + if err := t.Execute(&tpl, sInfo); err != nil { + return doc + } + + return tpl.String() +} + +func init() { + swag.Register(swag.Name, &s{}) +} diff --git a/web/swagger/favicon-16x16.png b/web/swagger/favicon-16x16.png new file mode 100644 index 0000000..8b194e6 Binary files /dev/null and b/web/swagger/favicon-16x16.png differ diff --git a/web/swagger/favicon-32x32.png b/web/swagger/favicon-32x32.png new file mode 100644 index 0000000..249737f Binary files /dev/null and b/web/swagger/favicon-32x32.png differ diff --git a/web/swagger/index.html b/web/swagger/index.html new file mode 100644 index 0000000..e71a50e --- /dev/null +++ b/web/swagger/index.html @@ -0,0 +1,61 @@ + + + + + + Maze Rats API + + + + + + + + +
+ + + + + + diff --git a/web/swagger/oauth2-redirect.html b/web/swagger/oauth2-redirect.html new file mode 100644 index 0000000..a013fc8 --- /dev/null +++ b/web/swagger/oauth2-redirect.html @@ -0,0 +1,68 @@ + + +Swagger UI: OAuth2 Redirect + + + + diff --git a/web/swagger/swagger-ui-bundle.js b/web/swagger/swagger-ui-bundle.js new file mode 100644 index 0000000..f735496 --- /dev/null +++ b/web/swagger/swagger-ui-bundle.js @@ -0,0 +1,92 @@ +!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(function(){try{return require("esprima")}catch(e){}}()):"function"==typeof define&&define.amd?define(["esprima"],t):"object"==typeof exports?exports.SwaggerUIBundle=t(function(){try{return require("esprima")}catch(e){}}()):e.SwaggerUIBundle=t(e.esprima)}(window,(function(e){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="/dist",n(n.s=485)}([function(e,t,n){"use strict";e.exports=n(106)},function(e,t,n){e.exports=n(799)},function(e,t,n){e.exports=function(){"use strict";var e=Array.prototype.slice;function t(e,t){t&&(e.prototype=Object.create(t.prototype)),e.prototype.constructor=e}function n(e){return a(e)?e:z(e)}function r(e){return u(e)?e:V(e)}function o(e){return s(e)?e:W(e)}function i(e){return a(e)&&!c(e)?e:H(e)}function a(e){return!(!e||!e[f])}function u(e){return!(!e||!e[p])}function s(e){return!(!e||!e[h])}function c(e){return u(e)||s(e)}function l(e){return!(!e||!e[d])}t(r,n),t(o,n),t(i,n),n.isIterable=a,n.isKeyed=u,n.isIndexed=s,n.isAssociative=c,n.isOrdered=l,n.Keyed=r,n.Indexed=o,n.Set=i;var f="@@__IMMUTABLE_ITERABLE__@@",p="@@__IMMUTABLE_KEYED__@@",h="@@__IMMUTABLE_INDEXED__@@",d="@@__IMMUTABLE_ORDERED__@@",v={},m={value:!1},y={value:!1};function g(e){return e.value=!1,e}function b(e){e&&(e.value=!0)}function _(){}function x(e,t){t=t||0;for(var n=Math.max(0,e.length-t),r=new Array(n),o=0;o>>0;if(""+n!==t||4294967295===n)return NaN;t=n}return t<0?w(e)+t:t}function C(){return!0}function S(e,t,n){return(0===e||void 0!==n&&e<=-n)&&(void 0===t||void 0!==n&&t>=n)}function A(e,t){return O(e,t,0)}function k(e,t){return O(e,t,t)}function O(e,t,n){return void 0===e?n:e<0?Math.max(0,t+e):void 0===t?e:Math.min(t,e)}var j,T,P,I="function"==typeof Symbol&&Symbol.iterator,M=I||"@@iterator";function D(e){this.next=e}function N(e,t,n,r){var o=0===e?t:1===e?n:[t,n];return r?r.value=o:r={value:o,done:!1},r}function R(){return{value:void 0,done:!0}}function L(e){return!!U(e)}function F(e){return e&&"function"==typeof e.next}function B(e){var t=U(e);return t&&t.call(e)}function U(e){var t=e&&(I&&e[I]||e["@@iterator"]);if("function"==typeof t)return t}function q(e){return e&&"number"==typeof e.length}function z(e){return null==e?Z():a(e)?e.toSeq():function(e){var t=ee(e)||"object"==typeof e&&new K(e);if(!t)throw new TypeError("Expected Array or iterable object of values, or keyed object: "+e);return t}(e)}function V(e){return null==e?Z().toKeyedSeq():a(e)?u(e)?e.toSeq():e.fromEntrySeq():X(e)}function W(e){return null==e?Z():a(e)?u(e)?e.entrySeq():e.toIndexedSeq():Q(e)}function H(e){return(null==e?Z():a(e)?u(e)?e.entrySeq():e:Q(e)).toSetSeq()}function J(e){this._array=e,this.size=e.length}function K(e){var t=Object.keys(e);this._object=e,this._keys=t,this.size=t.length}function $(e){this._iterable=e,this.size=e.length||e.size}function Y(e){this._iterator=e,this._iteratorCache=[]}function G(e){return!(!e||!e["@@__IMMUTABLE_SEQ__@@"])}function Z(){return j||(j=new J([]))}function X(e){var t=Array.isArray(e)?new J(e).fromEntrySeq():F(e)?new Y(e).fromEntrySeq():L(e)?new $(e).fromEntrySeq():"object"==typeof e?new K(e):void 0;if(!t)throw new TypeError("Expected Array or iterable object of [k, v] entries, or keyed object: "+e);return t}function Q(e){var t=ee(e);if(!t)throw new TypeError("Expected Array or iterable object of values: "+e);return t}function ee(e){return q(e)?new J(e):F(e)?new Y(e):L(e)?new $(e):void 0}function te(e,t,n,r){var o=e._cache;if(o){for(var i=o.length-1,a=0;a<=i;a++){var u=o[n?i-a:a];if(!1===t(u[1],r?u[0]:a,e))return a+1}return a}return e.__iterateUncached(t,n)}function ne(e,t,n,r){var o=e._cache;if(o){var i=o.length-1,a=0;return new D((function(){var e=o[n?i-a:a];return a++>i?{value:void 0,done:!0}:N(t,r?e[0]:a-1,e[1])}))}return e.__iteratorUncached(t,n)}function re(e,t){return t?function e(t,n,r,o){return Array.isArray(n)?t.call(o,r,W(n).map((function(r,o){return e(t,r,o,n)}))):ie(n)?t.call(o,r,V(n).map((function(r,o){return e(t,r,o,n)}))):n}(t,e,"",{"":e}):oe(e)}function oe(e){return Array.isArray(e)?W(e).map(oe).toList():ie(e)?V(e).map(oe).toMap():e}function ie(e){return e&&(e.constructor===Object||void 0===e.constructor)}function ae(e,t){if(e===t||e!=e&&t!=t)return!0;if(!e||!t)return!1;if("function"==typeof e.valueOf&&"function"==typeof t.valueOf){if((e=e.valueOf())===(t=t.valueOf())||e!=e&&t!=t)return!0;if(!e||!t)return!1}return!("function"!=typeof e.equals||"function"!=typeof t.equals||!e.equals(t))}function ue(e,t){if(e===t)return!0;if(!a(t)||void 0!==e.size&&void 0!==t.size&&e.size!==t.size||void 0!==e.__hash&&void 0!==t.__hash&&e.__hash!==t.__hash||u(e)!==u(t)||s(e)!==s(t)||l(e)!==l(t))return!1;if(0===e.size&&0===t.size)return!0;var n=!c(e);if(l(e)){var r=e.entries();return t.every((function(e,t){var o=r.next().value;return o&&ae(o[1],e)&&(n||ae(o[0],t))}))&&r.next().done}var o=!1;if(void 0===e.size)if(void 0===t.size)"function"==typeof e.cacheResult&&e.cacheResult();else{o=!0;var i=e;e=t,t=i}var f=!0,p=t.__iterate((function(t,r){if(n?!e.has(t):o?!ae(t,e.get(r,v)):!ae(e.get(r,v),t))return f=!1,!1}));return f&&e.size===p}function se(e,t){if(!(this instanceof se))return new se(e,t);if(this._value=e,this.size=void 0===t?1/0:Math.max(0,t),0===this.size){if(T)return T;T=this}}function ce(e,t){if(!e)throw new Error(t)}function le(e,t,n){if(!(this instanceof le))return new le(e,t,n);if(ce(0!==n,"Cannot step a Range by 0"),e=e||0,void 0===t&&(t=1/0),n=void 0===n?1:Math.abs(n),tr?{value:void 0,done:!0}:N(e,o,n[t?r-o++:o++])}))},t(K,V),K.prototype.get=function(e,t){return void 0===t||this.has(e)?this._object[e]:t},K.prototype.has=function(e){return this._object.hasOwnProperty(e)},K.prototype.__iterate=function(e,t){for(var n=this._object,r=this._keys,o=r.length-1,i=0;i<=o;i++){var a=r[t?o-i:i];if(!1===e(n[a],a,this))return i+1}return i},K.prototype.__iterator=function(e,t){var n=this._object,r=this._keys,o=r.length-1,i=0;return new D((function(){var a=r[t?o-i:i];return i++>o?{value:void 0,done:!0}:N(e,a,n[a])}))},K.prototype[d]=!0,t($,W),$.prototype.__iterateUncached=function(e,t){if(t)return this.cacheResult().__iterate(e,t);var n=B(this._iterable),r=0;if(F(n))for(var o;!(o=n.next()).done&&!1!==e(o.value,r++,this););return r},$.prototype.__iteratorUncached=function(e,t){if(t)return this.cacheResult().__iterator(e,t);var n=B(this._iterable);if(!F(n))return new D(R);var r=0;return new D((function(){var t=n.next();return t.done?t:N(e,r++,t.value)}))},t(Y,W),Y.prototype.__iterateUncached=function(e,t){if(t)return this.cacheResult().__iterate(e,t);for(var n,r=this._iterator,o=this._iteratorCache,i=0;i=r.length){var t=n.next();if(t.done)return t;r[o]=t.value}return N(e,o,r[o++])}))},t(se,W),se.prototype.toString=function(){return 0===this.size?"Repeat []":"Repeat [ "+this._value+" "+this.size+" times ]"},se.prototype.get=function(e,t){return this.has(e)?this._value:t},se.prototype.includes=function(e){return ae(this._value,e)},se.prototype.slice=function(e,t){var n=this.size;return S(e,t,n)?this:new se(this._value,k(t,n)-A(e,n))},se.prototype.reverse=function(){return this},se.prototype.indexOf=function(e){return ae(this._value,e)?0:-1},se.prototype.lastIndexOf=function(e){return ae(this._value,e)?this.size:-1},se.prototype.__iterate=function(e,t){for(var n=0;n=0&&t=0&&nn?{value:void 0,done:!0}:N(e,i++,a)}))},le.prototype.equals=function(e){return e instanceof le?this._start===e._start&&this._end===e._end&&this._step===e._step:ue(this,e)},t(fe,n),t(pe,fe),t(he,fe),t(de,fe),fe.Keyed=pe,fe.Indexed=he,fe.Set=de;var ve="function"==typeof Math.imul&&-2===Math.imul(4294967295,2)?Math.imul:function(e,t){var n=65535&(e|=0),r=65535&(t|=0);return n*r+((e>>>16)*r+n*(t>>>16)<<16>>>0)|0};function me(e){return e>>>1&1073741824|3221225471&e}function ye(e){if(!1===e||null==e)return 0;if("function"==typeof e.valueOf&&(!1===(e=e.valueOf())||null==e))return 0;if(!0===e)return 1;var t=typeof e;if("number"===t){if(e!=e||e===1/0)return 0;var n=0|e;for(n!==e&&(n^=4294967295*e);e>4294967295;)n^=e/=4294967295;return me(n)}if("string"===t)return e.length>Se?function(e){var t=Oe[e];return void 0===t&&(t=ge(e),ke===Ae&&(ke=0,Oe={}),ke++,Oe[e]=t),t}(e):ge(e);if("function"==typeof e.hashCode)return e.hashCode();if("object"===t)return function(e){var t;if(we&&void 0!==(t=be.get(e)))return t;if(void 0!==(t=e[Ce]))return t;if(!xe){if(void 0!==(t=e.propertyIsEnumerable&&e.propertyIsEnumerable[Ce]))return t;if(void 0!==(t=function(e){if(e&&e.nodeType>0)switch(e.nodeType){case 1:return e.uniqueID;case 9:return e.documentElement&&e.documentElement.uniqueID}}(e)))return t}if(t=++Ee,1073741824&Ee&&(Ee=0),we)be.set(e,t);else{if(void 0!==_e&&!1===_e(e))throw new Error("Non-extensible objects are not allowed as keys.");if(xe)Object.defineProperty(e,Ce,{enumerable:!1,configurable:!1,writable:!1,value:t});else if(void 0!==e.propertyIsEnumerable&&e.propertyIsEnumerable===e.constructor.prototype.propertyIsEnumerable)e.propertyIsEnumerable=function(){return this.constructor.prototype.propertyIsEnumerable.apply(this,arguments)},e.propertyIsEnumerable[Ce]=t;else{if(void 0===e.nodeType)throw new Error("Unable to set a non-enumerable property on object.");e[Ce]=t}}return t}(e);if("function"==typeof e.toString)return ge(e.toString());throw new Error("Value type "+t+" cannot be hashed.")}function ge(e){for(var t=0,n=0;n=t.length)throw new Error("Missing value for key: "+t[n]);e.set(t[n],t[n+1])}}))},Te.prototype.toString=function(){return this.__toString("Map {","}")},Te.prototype.get=function(e,t){return this._root?this._root.get(0,void 0,e,t):t},Te.prototype.set=function(e,t){return He(this,e,t)},Te.prototype.setIn=function(e,t){return this.updateIn(e,v,(function(){return t}))},Te.prototype.remove=function(e){return He(this,e,v)},Te.prototype.deleteIn=function(e){return this.updateIn(e,(function(){return v}))},Te.prototype.update=function(e,t,n){return 1===arguments.length?e(this):this.updateIn([e],t,n)},Te.prototype.updateIn=function(e,t,n){n||(n=t,t=void 0);var r=function e(t,n,r,o){var i=t===v,a=n.next();if(a.done){var u=i?r:t,s=o(u);return s===u?t:s}ce(i||t&&t.set,"invalid keyPath");var c=a.value,l=i?v:t.get(c,v),f=e(l,n,r,o);return f===l?t:f===v?t.remove(c):(i?We():t).set(c,f)}(this,Yt(e),t,n);return r===v?void 0:r},Te.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=0,this._root=null,this.__hash=void 0,this.__altered=!0,this):We()},Te.prototype.merge=function(){return Ye(this,void 0,arguments)},Te.prototype.mergeWith=function(t){var n=e.call(arguments,1);return Ye(this,t,n)},Te.prototype.mergeIn=function(t){var n=e.call(arguments,1);return this.updateIn(t,We(),(function(e){return"function"==typeof e.merge?e.merge.apply(e,n):n[n.length-1]}))},Te.prototype.mergeDeep=function(){return Ye(this,Ge,arguments)},Te.prototype.mergeDeepWith=function(t){var n=e.call(arguments,1);return Ye(this,Ze(t),n)},Te.prototype.mergeDeepIn=function(t){var n=e.call(arguments,1);return this.updateIn(t,We(),(function(e){return"function"==typeof e.mergeDeep?e.mergeDeep.apply(e,n):n[n.length-1]}))},Te.prototype.sort=function(e){return xt(Ft(this,e))},Te.prototype.sortBy=function(e,t){return xt(Ft(this,t,e))},Te.prototype.withMutations=function(e){var t=this.asMutable();return e(t),t.wasAltered()?t.__ensureOwner(this.__ownerID):this},Te.prototype.asMutable=function(){return this.__ownerID?this:this.__ensureOwner(new _)},Te.prototype.asImmutable=function(){return this.__ensureOwner()},Te.prototype.wasAltered=function(){return this.__altered},Te.prototype.__iterator=function(e,t){return new Ue(this,e,t)},Te.prototype.__iterate=function(e,t){var n=this,r=0;return this._root&&this._root.iterate((function(t){return r++,e(t[1],t[0],n)}),t),r},Te.prototype.__ensureOwner=function(e){return e===this.__ownerID?this:e?Ve(this.size,this._root,e,this.__hash):(this.__ownerID=e,this.__altered=!1,this)},Te.isMap=Pe;var Ie,Me="@@__IMMUTABLE_MAP__@@",De=Te.prototype;function Ne(e,t){this.ownerID=e,this.entries=t}function Re(e,t,n){this.ownerID=e,this.bitmap=t,this.nodes=n}function Le(e,t,n){this.ownerID=e,this.count=t,this.nodes=n}function Fe(e,t,n){this.ownerID=e,this.keyHash=t,this.entries=n}function Be(e,t,n){this.ownerID=e,this.keyHash=t,this.entry=n}function Ue(e,t,n){this._type=t,this._reverse=n,this._stack=e._root&&ze(e._root)}function qe(e,t){return N(e,t[0],t[1])}function ze(e,t){return{node:e,index:0,__prev:t}}function Ve(e,t,n,r){var o=Object.create(De);return o.size=e,o._root=t,o.__ownerID=n,o.__hash=r,o.__altered=!1,o}function We(){return Ie||(Ie=Ve(0))}function He(e,t,n){var r,o;if(e._root){var i=g(m),a=g(y);if(r=Je(e._root,e.__ownerID,0,void 0,t,n,i,a),!a.value)return e;o=e.size+(i.value?n===v?-1:1:0)}else{if(n===v)return e;o=1,r=new Ne(e.__ownerID,[[t,n]])}return e.__ownerID?(e.size=o,e._root=r,e.__hash=void 0,e.__altered=!0,e):r?Ve(o,r):We()}function Je(e,t,n,r,o,i,a,u){return e?e.update(t,n,r,o,i,a,u):i===v?e:(b(u),b(a),new Be(t,r,[o,i]))}function Ke(e){return e.constructor===Be||e.constructor===Fe}function $e(e,t,n,r,o){if(e.keyHash===r)return new Fe(t,r,[e.entry,o]);var i,a=31&(0===n?e.keyHash:e.keyHash>>>n),u=31&(0===n?r:r>>>n);return new Re(t,1<>1&1431655765))+(e>>2&858993459))+(e>>4)&252645135,e+=e>>8,127&(e+=e>>16)}function et(e,t,n,r){var o=r?e:x(e);return o[t]=n,o}De[Me]=!0,De.delete=De.remove,De.removeIn=De.deleteIn,Ne.prototype.get=function(e,t,n,r){for(var o=this.entries,i=0,a=o.length;i=tt)return function(e,t,n,r){e||(e=new _);for(var o=new Be(e,ye(n),[n,r]),i=0;i>>e)),i=this.bitmap;return 0==(i&o)?r:this.nodes[Qe(i&o-1)].get(e+5,t,n,r)},Re.prototype.update=function(e,t,n,r,o,i,a){void 0===n&&(n=ye(r));var u=31&(0===t?n:n>>>t),s=1<=nt)return function(e,t,n,r,o){for(var i=0,a=new Array(32),u=0;0!==n;u++,n>>>=1)a[u]=1&n?t[i++]:void 0;return a[r]=o,new Le(e,i+1,a)}(e,p,c,u,d);if(l&&!d&&2===p.length&&Ke(p[1^f]))return p[1^f];if(l&&d&&1===p.length&&Ke(d))return d;var m=e&&e===this.ownerID,y=l?d?c:c^s:c|s,g=l?d?et(p,f,d,m):function(e,t,n){var r=e.length-1;if(n&&t===r)return e.pop(),e;for(var o=new Array(r),i=0,a=0;a>>e),i=this.nodes[o];return i?i.get(e+5,t,n,r):r},Le.prototype.update=function(e,t,n,r,o,i,a){void 0===n&&(n=ye(r));var u=31&(0===t?n:n>>>t),s=o===v,c=this.nodes,l=c[u];if(s&&!l)return this;var f=Je(l,e,t+5,n,r,o,i,a);if(f===l)return this;var p=this.count;if(l){if(!f&&--p0&&r<32?ht(0,r,5,null,new st(n.toArray())):t.withMutations((function(e){e.setSize(r),n.forEach((function(t,n){return e.set(n,t)}))})))}function it(e){return!(!e||!e[at])}t(ot,he),ot.of=function(){return this(arguments)},ot.prototype.toString=function(){return this.__toString("List [","]")},ot.prototype.get=function(e,t){if((e=E(this,e))>=0&&e=e.size||t<0)return e.withMutations((function(e){t<0?gt(e,t).set(0,n):gt(e,0,t+1).set(t,n)}));t+=e._origin;var r=e._tail,o=e._root,i=g(y);return t>=_t(e._capacity)?r=vt(r,e.__ownerID,0,t,n,i):o=vt(o,e.__ownerID,e._level,t,n,i),i.value?e.__ownerID?(e._root=o,e._tail=r,e.__hash=void 0,e.__altered=!0,e):ht(e._origin,e._capacity,e._level,o,r):e}(this,e,t)},ot.prototype.remove=function(e){return this.has(e)?0===e?this.shift():e===this.size-1?this.pop():this.splice(e,1):this},ot.prototype.insert=function(e,t){return this.splice(e,0,t)},ot.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=this._origin=this._capacity=0,this._level=5,this._root=this._tail=null,this.__hash=void 0,this.__altered=!0,this):dt()},ot.prototype.push=function(){var e=arguments,t=this.size;return this.withMutations((function(n){gt(n,0,t+e.length);for(var r=0;r>>t&31;if(r>=this.array.length)return new st([],e);var o,i=0===r;if(t>0){var a=this.array[r];if((o=a&&a.removeBefore(e,t-5,n))===a&&i)return this}if(i&&!o)return this;var u=mt(this,e);if(!i)for(var s=0;s>>t&31;if(o>=this.array.length)return this;if(t>0){var i=this.array[o];if((r=i&&i.removeAfter(e,t-5,n))===i&&o===this.array.length-1)return this}var a=mt(this,e);return a.array.splice(o+1),r&&(a.array[o]=r),a};var ct,lt,ft={};function pt(e,t){var n=e._origin,r=e._capacity,o=_t(r),i=e._tail;return a(e._root,e._level,0);function a(e,u,s){return 0===u?function(e,a){var u=a===o?i&&i.array:e&&e.array,s=a>n?0:n-a,c=r-a;return c>32&&(c=32),function(){if(s===c)return ft;var e=t?--c:s++;return u&&u[e]}}(e,s):function(e,o,i){var u,s=e&&e.array,c=i>n?0:n-i>>o,l=1+(r-i>>o);return l>32&&(l=32),function(){for(;;){if(u){var e=u();if(e!==ft)return e;u=null}if(c===l)return ft;var n=t?--l:c++;u=a(s&&s[n],o-5,i+(n<>>n&31,s=e&&u0){var c=e&&e.array[u],l=vt(c,t,n-5,r,o,i);return l===c?e:((a=mt(e,t)).array[u]=l,a)}return s&&e.array[u]===o?e:(b(i),a=mt(e,t),void 0===o&&u===a.array.length-1?a.array.pop():a.array[u]=o,a)}function mt(e,t){return t&&e&&t===e.ownerID?e:new st(e?e.array.slice():[],t)}function yt(e,t){if(t>=_t(e._capacity))return e._tail;if(t<1<0;)n=n.array[t>>>r&31],r-=5;return n}}function gt(e,t,n){void 0!==t&&(t|=0),void 0!==n&&(n|=0);var r=e.__ownerID||new _,o=e._origin,i=e._capacity,a=o+t,u=void 0===n?i:n<0?i+n:o+n;if(a===o&&u===i)return e;if(a>=u)return e.clear();for(var s=e._level,c=e._root,l=0;a+l<0;)c=new st(c&&c.array.length?[void 0,c]:[],r),l+=1<<(s+=5);l&&(a+=l,o+=l,u+=l,i+=l);for(var f=_t(i),p=_t(u);p>=1<f?new st([],r):h;if(h&&p>f&&a5;m-=5){var y=f>>>m&31;v=v.array[y]=mt(v.array[y],r)}v.array[f>>>5&31]=h}if(u=p)a-=p,u-=p,s=5,c=null,d=d&&d.removeBefore(r,0,a);else if(a>o||p>>s&31;if(g!==p>>>s&31)break;g&&(l+=(1<o&&(c=c.removeBefore(r,s,a-l)),c&&pi&&(i=c.size),a(s)||(c=c.map((function(e){return re(e)}))),r.push(c)}return i>e.size&&(e=e.setSize(i)),Xe(e,t,r)}function _t(e){return e<32?0:e-1>>>5<<5}function xt(e){return null==e?Ct():wt(e)?e:Ct().withMutations((function(t){var n=r(e);je(n.size),n.forEach((function(e,n){return t.set(n,e)}))}))}function wt(e){return Pe(e)&&l(e)}function Et(e,t,n,r){var o=Object.create(xt.prototype);return o.size=e?e.size:0,o._map=e,o._list=t,o.__ownerID=n,o.__hash=r,o}function Ct(){return lt||(lt=Et(We(),dt()))}function St(e,t,n){var r,o,i=e._map,a=e._list,u=i.get(t),s=void 0!==u;if(n===v){if(!s)return e;a.size>=32&&a.size>=2*i.size?(r=(o=a.filter((function(e,t){return void 0!==e&&u!==t}))).toKeyedSeq().map((function(e){return e[0]})).flip().toMap(),e.__ownerID&&(r.__ownerID=o.__ownerID=e.__ownerID)):(r=i.remove(t),o=u===a.size-1?a.pop():a.set(u,void 0))}else if(s){if(n===a.get(u)[1])return e;r=i,o=a.set(u,[t,n])}else r=i.set(t,a.size),o=a.set(a.size,[t,n]);return e.__ownerID?(e.size=r.size,e._map=r,e._list=o,e.__hash=void 0,e):Et(r,o)}function At(e,t){this._iter=e,this._useKeys=t,this.size=e.size}function kt(e){this._iter=e,this.size=e.size}function Ot(e){this._iter=e,this.size=e.size}function jt(e){this._iter=e,this.size=e.size}function Tt(e){var t=Jt(e);return t._iter=e,t.size=e.size,t.flip=function(){return e},t.reverse=function(){var t=e.reverse.apply(this);return t.flip=function(){return e.reverse()},t},t.has=function(t){return e.includes(t)},t.includes=function(t){return e.has(t)},t.cacheResult=Kt,t.__iterateUncached=function(t,n){var r=this;return e.__iterate((function(e,n){return!1!==t(n,e,r)}),n)},t.__iteratorUncached=function(t,n){if(2===t){var r=e.__iterator(t,n);return new D((function(){var e=r.next();if(!e.done){var t=e.value[0];e.value[0]=e.value[1],e.value[1]=t}return e}))}return e.__iterator(1===t?0:1,n)},t}function Pt(e,t,n){var r=Jt(e);return r.size=e.size,r.has=function(t){return e.has(t)},r.get=function(r,o){var i=e.get(r,v);return i===v?o:t.call(n,i,r,e)},r.__iterateUncached=function(r,o){var i=this;return e.__iterate((function(e,o,a){return!1!==r(t.call(n,e,o,a),o,i)}),o)},r.__iteratorUncached=function(r,o){var i=e.__iterator(2,o);return new D((function(){var o=i.next();if(o.done)return o;var a=o.value,u=a[0];return N(r,u,t.call(n,a[1],u,e),o)}))},r}function It(e,t){var n=Jt(e);return n._iter=e,n.size=e.size,n.reverse=function(){return e},e.flip&&(n.flip=function(){var t=Tt(e);return t.reverse=function(){return e.flip()},t}),n.get=function(n,r){return e.get(t?n:-1-n,r)},n.has=function(n){return e.has(t?n:-1-n)},n.includes=function(t){return e.includes(t)},n.cacheResult=Kt,n.__iterate=function(t,n){var r=this;return e.__iterate((function(e,n){return t(e,n,r)}),!n)},n.__iterator=function(t,n){return e.__iterator(t,!n)},n}function Mt(e,t,n,r){var o=Jt(e);return r&&(o.has=function(r){var o=e.get(r,v);return o!==v&&!!t.call(n,o,r,e)},o.get=function(r,o){var i=e.get(r,v);return i!==v&&t.call(n,i,r,e)?i:o}),o.__iterateUncached=function(o,i){var a=this,u=0;return e.__iterate((function(e,i,s){if(t.call(n,e,i,s))return u++,o(e,r?i:u-1,a)}),i),u},o.__iteratorUncached=function(o,i){var a=e.__iterator(2,i),u=0;return new D((function(){for(;;){var i=a.next();if(i.done)return i;var s=i.value,c=s[0],l=s[1];if(t.call(n,l,c,e))return N(o,r?c:u++,l,i)}}))},o}function Dt(e,t,n,r){var o=e.size;if(void 0!==t&&(t|=0),void 0!==n&&(n===1/0?n=o:n|=0),S(t,n,o))return e;var i=A(t,o),a=k(n,o);if(i!=i||a!=a)return Dt(e.toSeq().cacheResult(),t,n,r);var u,s=a-i;s==s&&(u=s<0?0:s);var c=Jt(e);return c.size=0===u?u:e.size&&u||void 0,!r&&G(e)&&u>=0&&(c.get=function(t,n){return(t=E(this,t))>=0&&tu)return{value:void 0,done:!0};var e=o.next();return r||1===t?e:N(t,s-1,0===t?void 0:e.value[1],e)}))},c}function Nt(e,t,n,r){var o=Jt(e);return o.__iterateUncached=function(o,i){var a=this;if(i)return this.cacheResult().__iterate(o,i);var u=!0,s=0;return e.__iterate((function(e,i,c){if(!u||!(u=t.call(n,e,i,c)))return s++,o(e,r?i:s-1,a)})),s},o.__iteratorUncached=function(o,i){var a=this;if(i)return this.cacheResult().__iterator(o,i);var u=e.__iterator(2,i),s=!0,c=0;return new D((function(){var e,i,l;do{if((e=u.next()).done)return r||1===o?e:N(o,c++,0===o?void 0:e.value[1],e);var f=e.value;i=f[0],l=f[1],s&&(s=t.call(n,l,i,a))}while(s);return 2===o?e:N(o,i,l,e)}))},o}function Rt(e,t){var n=u(e),o=[e].concat(t).map((function(e){return a(e)?n&&(e=r(e)):e=n?X(e):Q(Array.isArray(e)?e:[e]),e})).filter((function(e){return 0!==e.size}));if(0===o.length)return e;if(1===o.length){var i=o[0];if(i===e||n&&u(i)||s(e)&&s(i))return i}var c=new J(o);return n?c=c.toKeyedSeq():s(e)||(c=c.toSetSeq()),(c=c.flatten(!0)).size=o.reduce((function(e,t){if(void 0!==e){var n=t.size;if(void 0!==n)return e+n}}),0),c}function Lt(e,t,n){var r=Jt(e);return r.__iterateUncached=function(r,o){var i=0,u=!1;return function e(s,c){var l=this;s.__iterate((function(o,s){return(!t||c0}function qt(e,t,r){var o=Jt(e);return o.size=new J(r).map((function(e){return e.size})).min(),o.__iterate=function(e,t){for(var n,r=this.__iterator(1,t),o=0;!(n=r.next()).done&&!1!==e(n.value,o++,this););return o},o.__iteratorUncached=function(e,o){var i=r.map((function(e){return e=n(e),B(o?e.reverse():e)})),a=0,u=!1;return new D((function(){var n;return u||(n=i.map((function(e){return e.next()})),u=n.some((function(e){return e.done}))),u?{value:void 0,done:!0}:N(e,a++,t.apply(null,n.map((function(e){return e.value}))))}))},o}function zt(e,t){return G(e)?t:e.constructor(t)}function Vt(e){if(e!==Object(e))throw new TypeError("Expected [K, V] tuple: "+e)}function Wt(e){return je(e.size),w(e)}function Ht(e){return u(e)?r:s(e)?o:i}function Jt(e){return Object.create((u(e)?V:s(e)?W:H).prototype)}function Kt(){return this._iter.cacheResult?(this._iter.cacheResult(),this.size=this._iter.size,this):z.prototype.cacheResult.call(this)}function $t(e,t){return e>t?1:e=0;n--)t={value:arguments[n],next:t};return this.__ownerID?(this.size=e,this._head=t,this.__hash=void 0,this.__altered=!0,this):xn(e,t)},mn.prototype.pushAll=function(e){if(0===(e=o(e)).size)return this;je(e.size);var t=this.size,n=this._head;return e.reverse().forEach((function(e){t++,n={value:e,next:n}})),this.__ownerID?(this.size=t,this._head=n,this.__hash=void 0,this.__altered=!0,this):xn(t,n)},mn.prototype.pop=function(){return this.slice(1)},mn.prototype.unshift=function(){return this.push.apply(this,arguments)},mn.prototype.unshiftAll=function(e){return this.pushAll(e)},mn.prototype.shift=function(){return this.pop.apply(this,arguments)},mn.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=0,this._head=void 0,this.__hash=void 0,this.__altered=!0,this):wn()},mn.prototype.slice=function(e,t){if(S(e,t,this.size))return this;var n=A(e,this.size);if(k(t,this.size)!==this.size)return he.prototype.slice.call(this,e,t);for(var r=this.size-n,o=this._head;n--;)o=o.next;return this.__ownerID?(this.size=r,this._head=o,this.__hash=void 0,this.__altered=!0,this):xn(r,o)},mn.prototype.__ensureOwner=function(e){return e===this.__ownerID?this:e?xn(this.size,this._head,e,this.__hash):(this.__ownerID=e,this.__altered=!1,this)},mn.prototype.__iterate=function(e,t){if(t)return this.reverse().__iterate(e);for(var n=0,r=this._head;r&&!1!==e(r.value,n++,this);)r=r.next;return n},mn.prototype.__iterator=function(e,t){if(t)return this.reverse().__iterator(e);var n=0,r=this._head;return new D((function(){if(r){var t=r.value;return r=r.next,N(e,n++,t)}return{value:void 0,done:!0}}))},mn.isStack=yn;var gn,bn="@@__IMMUTABLE_STACK__@@",_n=mn.prototype;function xn(e,t,n,r){var o=Object.create(_n);return o.size=e,o._head=t,o.__ownerID=n,o.__hash=r,o.__altered=!1,o}function wn(){return gn||(gn=xn(0))}function En(e,t){var n=function(n){e.prototype[n]=t[n]};return Object.keys(t).forEach(n),Object.getOwnPropertySymbols&&Object.getOwnPropertySymbols(t).forEach(n),e}_n[bn]=!0,_n.withMutations=De.withMutations,_n.asMutable=De.asMutable,_n.asImmutable=De.asImmutable,_n.wasAltered=De.wasAltered,n.Iterator=D,En(n,{toArray:function(){je(this.size);var e=new Array(this.size||0);return this.valueSeq().__iterate((function(t,n){e[n]=t})),e},toIndexedSeq:function(){return new kt(this)},toJS:function(){return this.toSeq().map((function(e){return e&&"function"==typeof e.toJS?e.toJS():e})).__toJS()},toJSON:function(){return this.toSeq().map((function(e){return e&&"function"==typeof e.toJSON?e.toJSON():e})).__toJS()},toKeyedSeq:function(){return new At(this,!0)},toMap:function(){return Te(this.toKeyedSeq())},toObject:function(){je(this.size);var e={};return this.__iterate((function(t,n){e[n]=t})),e},toOrderedMap:function(){return xt(this.toKeyedSeq())},toOrderedSet:function(){return ln(u(this)?this.valueSeq():this)},toSet:function(){return tn(u(this)?this.valueSeq():this)},toSetSeq:function(){return new Ot(this)},toSeq:function(){return s(this)?this.toIndexedSeq():u(this)?this.toKeyedSeq():this.toSetSeq()},toStack:function(){return mn(u(this)?this.valueSeq():this)},toList:function(){return ot(u(this)?this.valueSeq():this)},toString:function(){return"[Iterable]"},__toString:function(e,t){return 0===this.size?e+t:e+" "+this.toSeq().map(this.__toStringMapper).join(", ")+" "+t},concat:function(){var t=e.call(arguments,0);return zt(this,Rt(this,t))},includes:function(e){return this.some((function(t){return ae(t,e)}))},entries:function(){return this.__iterator(2)},every:function(e,t){je(this.size);var n=!0;return this.__iterate((function(r,o,i){if(!e.call(t,r,o,i))return n=!1,!1})),n},filter:function(e,t){return zt(this,Mt(this,e,t,!0))},find:function(e,t,n){var r=this.findEntry(e,t);return r?r[1]:n},forEach:function(e,t){return je(this.size),this.__iterate(t?e.bind(t):e)},join:function(e){je(this.size),e=void 0!==e?""+e:",";var t="",n=!0;return this.__iterate((function(r){n?n=!1:t+=e,t+=null!=r?r.toString():""})),t},keys:function(){return this.__iterator(0)},map:function(e,t){return zt(this,Pt(this,e,t))},reduce:function(e,t,n){var r,o;return je(this.size),arguments.length<2?o=!0:r=t,this.__iterate((function(t,i,a){o?(o=!1,r=t):r=e.call(n,r,t,i,a)})),r},reduceRight:function(e,t,n){var r=this.toKeyedSeq().reverse();return r.reduce.apply(r,arguments)},reverse:function(){return zt(this,It(this,!0))},slice:function(e,t){return zt(this,Dt(this,e,t,!0))},some:function(e,t){return!this.every(On(e),t)},sort:function(e){return zt(this,Ft(this,e))},values:function(){return this.__iterator(1)},butLast:function(){return this.slice(0,-1)},isEmpty:function(){return void 0!==this.size?0===this.size:!this.some((function(){return!0}))},count:function(e,t){return w(e?this.toSeq().filter(e,t):this)},countBy:function(e,t){return function(e,t,n){var r=Te().asMutable();return e.__iterate((function(o,i){r.update(t.call(n,o,i,e),0,(function(e){return e+1}))})),r.asImmutable()}(this,e,t)},equals:function(e){return ue(this,e)},entrySeq:function(){var e=this;if(e._cache)return new J(e._cache);var t=e.toSeq().map(kn).toIndexedSeq();return t.fromEntrySeq=function(){return e.toSeq()},t},filterNot:function(e,t){return this.filter(On(e),t)},findEntry:function(e,t,n){var r=n;return this.__iterate((function(n,o,i){if(e.call(t,n,o,i))return r=[o,n],!1})),r},findKey:function(e,t){var n=this.findEntry(e,t);return n&&n[0]},findLast:function(e,t,n){return this.toKeyedSeq().reverse().find(e,t,n)},findLastEntry:function(e,t,n){return this.toKeyedSeq().reverse().findEntry(e,t,n)},findLastKey:function(e,t){return this.toKeyedSeq().reverse().findKey(e,t)},first:function(){return this.find(C)},flatMap:function(e,t){return zt(this,function(e,t,n){var r=Ht(e);return e.toSeq().map((function(o,i){return r(t.call(n,o,i,e))})).flatten(!0)}(this,e,t))},flatten:function(e){return zt(this,Lt(this,e,!0))},fromEntrySeq:function(){return new jt(this)},get:function(e,t){return this.find((function(t,n){return ae(n,e)}),void 0,t)},getIn:function(e,t){for(var n,r=this,o=Yt(e);!(n=o.next()).done;){var i=n.value;if((r=r&&r.get?r.get(i,v):v)===v)return t}return r},groupBy:function(e,t){return function(e,t,n){var r=u(e),o=(l(e)?xt():Te()).asMutable();e.__iterate((function(i,a){o.update(t.call(n,i,a,e),(function(e){return(e=e||[]).push(r?[a,i]:i),e}))}));var i=Ht(e);return o.map((function(t){return zt(e,i(t))}))}(this,e,t)},has:function(e){return this.get(e,v)!==v},hasIn:function(e){return this.getIn(e,v)!==v},isSubset:function(e){return e="function"==typeof e.includes?e:n(e),this.every((function(t){return e.includes(t)}))},isSuperset:function(e){return(e="function"==typeof e.isSubset?e:n(e)).isSubset(this)},keyOf:function(e){return this.findKey((function(t){return ae(t,e)}))},keySeq:function(){return this.toSeq().map(An).toIndexedSeq()},last:function(){return this.toSeq().reverse().first()},lastKeyOf:function(e){return this.toKeyedSeq().reverse().keyOf(e)},max:function(e){return Bt(this,e)},maxBy:function(e,t){return Bt(this,t,e)},min:function(e){return Bt(this,e?jn(e):In)},minBy:function(e,t){return Bt(this,t?jn(t):In,e)},rest:function(){return this.slice(1)},skip:function(e){return this.slice(Math.max(0,e))},skipLast:function(e){return zt(this,this.toSeq().reverse().skip(e).reverse())},skipWhile:function(e,t){return zt(this,Nt(this,e,t,!0))},skipUntil:function(e,t){return this.skipWhile(On(e),t)},sortBy:function(e,t){return zt(this,Ft(this,t,e))},take:function(e){return this.slice(0,Math.max(0,e))},takeLast:function(e){return zt(this,this.toSeq().reverse().take(e).reverse())},takeWhile:function(e,t){return zt(this,function(e,t,n){var r=Jt(e);return r.__iterateUncached=function(r,o){var i=this;if(o)return this.cacheResult().__iterate(r,o);var a=0;return e.__iterate((function(e,o,u){return t.call(n,e,o,u)&&++a&&r(e,o,i)})),a},r.__iteratorUncached=function(r,o){var i=this;if(o)return this.cacheResult().__iterator(r,o);var a=e.__iterator(2,o),u=!0;return new D((function(){if(!u)return{value:void 0,done:!0};var e=a.next();if(e.done)return e;var o=e.value,s=o[0],c=o[1];return t.call(n,c,s,i)?2===r?e:N(r,s,c,e):(u=!1,{value:void 0,done:!0})}))},r}(this,e,t))},takeUntil:function(e,t){return this.takeWhile(On(e),t)},valueSeq:function(){return this.toIndexedSeq()},hashCode:function(){return this.__hash||(this.__hash=function(e){if(e.size===1/0)return 0;var t=l(e),n=u(e),r=t?1:0;return function(e,t){return t=ve(t,3432918353),t=ve(t<<15|t>>>-15,461845907),t=ve(t<<13|t>>>-13,5),t=ve((t=(t+3864292196|0)^e)^t>>>16,2246822507),t=me((t=ve(t^t>>>13,3266489909))^t>>>16)}(e.__iterate(n?t?function(e,t){r=31*r+Mn(ye(e),ye(t))|0}:function(e,t){r=r+Mn(ye(e),ye(t))|0}:t?function(e){r=31*r+ye(e)|0}:function(e){r=r+ye(e)|0}),r)}(this))}});var Cn=n.prototype;Cn[f]=!0,Cn[M]=Cn.values,Cn.__toJS=Cn.toArray,Cn.__toStringMapper=Tn,Cn.inspect=Cn.toSource=function(){return this.toString()},Cn.chain=Cn.flatMap,Cn.contains=Cn.includes,En(r,{flip:function(){return zt(this,Tt(this))},mapEntries:function(e,t){var n=this,r=0;return zt(this,this.toSeq().map((function(o,i){return e.call(t,[i,o],r++,n)})).fromEntrySeq())},mapKeys:function(e,t){var n=this;return zt(this,this.toSeq().flip().map((function(r,o){return e.call(t,r,o,n)})).flip())}});var Sn=r.prototype;function An(e,t){return t}function kn(e,t){return[t,e]}function On(e){return function(){return!e.apply(this,arguments)}}function jn(e){return function(){return-e.apply(this,arguments)}}function Tn(e){return"string"==typeof e?JSON.stringify(e):String(e)}function Pn(){return x(arguments)}function In(e,t){return et?-1:0}function Mn(e,t){return e^t+2654435769+(e<<6)+(e>>2)|0}return Sn[p]=!0,Sn[M]=Cn.entries,Sn.__toJS=Cn.toObject,Sn.__toStringMapper=function(e,t){return JSON.stringify(t)+": "+Tn(e)},En(o,{toKeyedSeq:function(){return new At(this,!1)},filter:function(e,t){return zt(this,Mt(this,e,t,!1))},findIndex:function(e,t){var n=this.findEntry(e,t);return n?n[0]:-1},indexOf:function(e){var t=this.keyOf(e);return void 0===t?-1:t},lastIndexOf:function(e){var t=this.lastKeyOf(e);return void 0===t?-1:t},reverse:function(){return zt(this,It(this,!1))},slice:function(e,t){return zt(this,Dt(this,e,t,!1))},splice:function(e,t){var n=arguments.length;if(t=Math.max(0|t,0),0===n||2===n&&!t)return this;e=A(e,e<0?this.count():this.size);var r=this.slice(0,e);return zt(this,1===n?r:r.concat(x(arguments,2),this.slice(e+t)))},findLastIndex:function(e,t){var n=this.findLastEntry(e,t);return n?n[0]:-1},first:function(){return this.get(0)},flatten:function(e){return zt(this,Lt(this,e,!1))},get:function(e,t){return(e=E(this,e))<0||this.size===1/0||void 0!==this.size&&e>this.size?t:this.find((function(t,n){return n===e}),void 0,t)},has:function(e){return(e=E(this,e))>=0&&(void 0!==this.size?this.size===1/0||e=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var u,c=!0,f=!1;return{s:function(){n=o()(e)},n:function(){var e=n.next();return c=e.done,e},e:function(e){f=!0,u=e},f:function(){try{c||null==n.return||n.return()}finally{if(f)throw u}}}}function K(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n5e3)return e.textContent;return function(e){for(var n,r,o,i,a,u=e.textContent,s=0,c=u[0],l=1,f=e.innerHTML="",p=0;r=n,n=p<7&&"\\"==n?1:l;){if(l=c,c=u[++s],i=f.length>1,!l||p>8&&"\n"==l||[/\S/.test(l),1,1,!/[$\w]/.test(l),("/"==n||"\n"==n)&&i,'"'==n&&i,"'"==n&&i,u[s-4]+r+n=="--\x3e",r+n=="*/"][p])for(f&&(e.appendChild(a=t.createElement("span")).setAttribute("class",["token-not-formatted","","","token-string",""][p?p<3?2:p>6?4:p>3?3:+/^(a(bstract|lias|nd|rguments|rray|s(m|sert)?|uto)|b(ase|egin|ool(ean)?|reak|yte)|c(ase|atch|har|hecked|lass|lone|ompl|onst|ontinue)|de(bugger|cimal|clare|f(ault|er)?|init|l(egate|ete)?)|do|double|e(cho|ls?if|lse(if)?|nd|nsure|num|vent|x(cept|ec|p(licit|ort)|te(nds|nsion|rn)))|f(allthrough|alse|inal(ly)?|ixed|loat|or(each)?|riend|rom|unc(tion)?)|global|goto|guard|i(f|mp(lements|licit|ort)|n(it|clude(_once)?|line|out|stanceof|t(erface|ernal)?)?|s)|l(ambda|et|ock|ong)|m(icrolight|odule|utable)|NaN|n(amespace|ative|ext|ew|il|ot|ull)|o(bject|perator|r|ut|verride)|p(ackage|arams|rivate|rotected|rotocol|ublic)|r(aise|e(adonly|do|f|gister|peat|quire(_once)?|scue|strict|try|turn))|s(byte|ealed|elf|hort|igned|izeof|tatic|tring|truct|ubscript|uper|ynchronized|witch)|t(emplate|hen|his|hrows?|ransient|rue|ry|ype(alias|def|id|name|of))|u(n(checked|def(ined)?|ion|less|signed|til)|se|sing)|v(ar|irtual|oid|olatile)|w(char_t|hen|here|hile|ith)|xor|yield)$/.test(f):0]),a.appendChild(t.createTextNode(f))),o=p&&p<7?p:o,f="",p=11;![1,/[\/{}[(\-+*=<>:;|\\.,?!&@~]/.test(l),/[\])]/.test(l),/[$\w]/.test(l),"/"==l&&o<2&&"<"!=n,'"'==l,"'"==l,l+c+u[s+1]+u[s+2]=="\x3c!--",l+c=="/*",l+c=="//","#"==l][--p];);f+=l}}(e)}function le(e){var t;if([/filename\*=[^']+'\w*'"([^"]+)";?/i,/filename\*=[^']+'\w*'([^;]+);?/i,/filename="([^;]*);?"/i,/filename=([^;]*);?/i].some((function(n){return null!==(t=n.exec(e))})),null!==t&&t.length>1)try{return decodeURIComponent(t[1])}catch(e){console.error(e)}return null}function fe(e){return t=e.replace(/\.[^./]*$/,""),k()(S()(t));var t}var pe=function(e,t){if(e>t)return"Value must be less than Maximum"},he=function(e,t){if(et)return"Value must be less than MaxLength"},we=function(e,t){if(e.length2&&void 0!==arguments[2]?arguments[2]:{},r=n.isOAS3,o=void 0!==r&&r,i=n.bypassRequiredCheck,a=void 0!==i&&i,u=[],s=e.get("required"),c=Object(q.a)(e,{isOAS3:o}),l=c.schema,f=c.parameterContentMediaType;if(!l)return u;var p=l.get("required"),h=l.get("maximum"),d=l.get("minimum"),v=l.get("type"),m=l.get("format"),y=l.get("maxLength"),b=l.get("minLength"),x=l.get("pattern");if(v&&(s||p||t)){var E="string"===v&&t,C="array"===v&&g()(t)&&t.length,S="array"===v&&w.a.List.isList(t)&&t.count(),A="array"===v&&"string"==typeof t&&t,k="file"===v&&t instanceof F.a.File,O="boolean"===v&&(t||!1===t),j="number"===v&&(t||0===t),T="integer"===v&&(t||0===t),P="object"===v&&"object"===_()(t)&&null!==t,I="object"===v&&"string"==typeof t&&t,M=[E,C,S,A,k,O,j,T,P,I],D=M.some((function(e){return!!e}));if((s||p)&&!D&&!a)return u.push("Required field is not provided"),u;if("object"===v&&"string"==typeof t&&(null===f||"application/json"===f))try{JSON.parse(t)}catch(e){return u.push("Parameter string value must be valid JSON"),u}if(x){var N=Ee(t,x);N&&u.push(N)}if(y||0===y){var R=xe(t,y);R&&u.push(R)}if(b){var L=we(t,b);L&&u.push(L)}if(h||0===h){var B=pe(t,h);B&&u.push(B)}if(d||0===d){var U=he(t,d);U&&u.push(U)}if("string"===v){var z;if(!(z="date-time"===m?be(t):"uuid"===m?_e(t):ge(t)))return u;u.push(z)}else if("boolean"===v){var V=ye(t);if(!V)return u;u.push(V)}else if("number"===v){var W=de(t);if(!W)return u;u.push(W)}else if("integer"===v){var H=ve(t);if(!H)return u;u.push(H)}else if("array"===v){var J;if(!S||!t.count())return u;J=l.getIn(["items","type"]),t.forEach((function(e,t){var n;"number"===J?n=de(e):"integer"===J?n=ve(e):"string"===J&&(n=ge(e)),n&&u.push({index:t,error:n})}))}else if("file"===v){var K=me(t);if(!K)return u;u.push(K)}}return u},Se=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(/xml/.test(t)){if(!e.xml||!e.xml.name){if(e.xml=e.xml||{},!e.$$ref)return e.type||e.items||e.properties||e.additionalProperties?'\n\x3c!-- XML example cannot be generated; root element name is undefined --\x3e':null;var r=e.$$ref.match(/\S*\/(\S+)$/);e.xml.name=r[1]}return Object(R.memoizedCreateXMLExample)(e,n)}var o=Object(R.memoizedSampleFromSchema)(e,n);return"object"===_()(o)?p()(o,null,2):o},Ae=function(){var e={},t=F.a.location.search;if(!t)return{};if(""!=t){var n=t.substr(1).split("&");for(var r in n)n.hasOwnProperty(r)&&(r=n[r].split("="),e[decodeURIComponent(r[0])]=r[1]&&decodeURIComponent(r[1])||"")}return e},ke=function(t){return(t instanceof e?t:new e(t.toString(),"utf-8")).toString("base64")},Oe={operationsSorter:{alpha:function(e,t){return e.get("path").localeCompare(t.get("path"))},method:function(e,t){return e.get("method").localeCompare(t.get("method"))}},tagsSorter:{alpha:function(e,t){return e.localeCompare(t)}}},je=function(e){var t=[];for(var n in e){var r=e[n];void 0!==r&&""!==r&&t.push([n,"=",encodeURIComponent(r).replace(/%20/g,"+")].join(""))}return t.join("&")},Te=function(e,t,n){return!!P()(n,(function(n){return M()(e[n],t[n])}))};function Pe(e){return"string"!=typeof e||""===e?"":Object(E.sanitizeUrl)(e)}function Ie(e){return!(!e||e.indexOf("localhost")>=0||e.indexOf("127.0.0.1")>=0||"none"===e)}function Me(e){if(!w.a.OrderedMap.isOrderedMap(e))return null;if(!e.size)return null;var t=e.find((function(e,t){return t.startsWith("2")&&m()(e.get("content")||{}).length>0})),n=e.get("default")||w.a.OrderedMap(),r=(n.get("content")||w.a.OrderedMap()).keySeq().toJS().length?n:null;return t||r}var De=function(e){return"string"==typeof e||e instanceof String?e.trim().replace(/\s/g,"%20"):""},Ne=function(e){return U()(De(e).replace(/%20/g,"_"))},Re=function(e){return e.filter((function(e,t){return/^x-/.test(t)}))},Le=function(e){return e.filter((function(e,t){return/^pattern|maxLength|minLength|maximum|minimum/.test(t)}))};function Fe(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){return!0};if("object"!==_()(e)||g()(e)||null===e||!t)return e;var r=d()({},e);return m()(r).forEach((function(e){e===t&&n(r[e],e)?delete r[e]:r[e]=Fe(r[e],t,n)})),r}function Be(e){if("string"==typeof e)return e;if(e&&e.toJS&&(e=e.toJS()),"object"===_()(e)&&null!==e)try{return p()(e,null,2)}catch(t){return String(e)}return null==e?"":e.toString()}function Ue(e){return"number"==typeof e?e.toString():e}function qe(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.returnAll,r=void 0!==n&&n,o=t.allowHashes,i=void 0===o||o;if(!w.a.Map.isMap(e))throw new Error("paramToIdentifier: received a non-Im.Map parameter as input");var a=e.get("name"),u=e.get("in"),s=[];return e&&e.hashCode&&u&&a&&i&&s.push("".concat(u,".").concat(a,".hash-").concat(e.hashCode())),u&&a&&s.push("".concat(u,".").concat(a)),s.push(a),r?s:s[0]||""}function ze(e,t){return qe(e,{returnAll:!0}).map((function(e){return t[e]})).filter((function(e){return void 0!==e}))[0]}function Ve(){return He(V()(32).toString("base64"))}function We(e){return He(H()("sha256").update(e).digest("base64"))}function He(e){return e.replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}var Je=function(e){return!e||!(!$(e)||!e.isEmpty())}}).call(this,n(79).Buffer)},function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}},function(e,t,n){var r=n(54);function o(e,t){for(var n=0;n1?t-1:0),r=1;r1&&void 0!==arguments[1]?arguments[1]:r,n=null,i=null;return function(){return o(t,n,arguments)||(i=e.apply(null,arguments)),n=arguments,i}}))},function(e,t,n){var r=n(751),o=n(752),i=n(756);e.exports=function(e){return r(e)||o(e)||i()}},function(e,t,n){var r=n(596),o=n(597),i=n(598);e.exports=function(e,t){return r(e)||o(e,t)||i()}},function(e,t,n){e.exports=n(566)},function(e,t,n){"use strict";e.exports=function(e,t,n,r,o,i,a,u){if(!e){var s;if(void 0===t)s=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var c=[n,r,o,i,a,u],l=0;(s=new Error(t.replace(/%s/g,(function(){return c[l++]})))).name="Invariant Violation"}throw s.framesToPop=1,s}}},function(e,t,n){e.exports=n(550)},function(e,t,n){e.exports=n(570)},function(e,t){e.exports=function(){var e={location:{},history:{},open:function(){},close:function(){},File:function(){}};if("undefined"==typeof window)return e;try{e=window;for(var t=0,n=["File","Blob","FormData"];t5?s-5:0),l=5;l6?u-6:0),c=6;c>",null!=n[r])return e.apply(void 0,[n,r,o,i,a].concat(s));var l=i;return t?new Error("Required "+l+" `"+a+"` was not specified in `"+o+"`."):void 0}var n=t.bind(null,!1);return n.isRequired=t.bind(null,!0),n}function u(e,t){return a((function(n,r,o,a,u){var s=n[r];if(!t(s)){var c=i(s);return new Error("Invalid "+a+" `"+u+"` of type `"+c+"` supplied to `"+o+"`, expected `"+e+"`.")}return null}))}function s(e,t,n){return a((function(r,o,a,u,s){for(var c=arguments.length,l=Array(c>5?c-5:0),f=5;f5?a-5:0),s=5;s key("+l[f]+")"].concat(u));if(h instanceof Error)return h}}))}function l(e,t,n,r){return a((function(){for(var o=arguments.length,i=Array(o),a=0;a5?c-5:0),f=5;f4)}function s(e){var t=e.get("swagger");return"string"==typeof t&&t.startsWith("2.0")}function c(e){return function(t,n){return function(r){return n&&n.specSelectors&&n.specSelectors.specJson?u(n.specSelectors.specJson())?a.a.createElement(e,o()({},r,n,{Ori:t})):a.a.createElement(t,r):(console.warn("OAS3 wrapper: couldn't get spec"),null)}}}},function(e,t,n){"use strict"; +/* +object-assign +(c) Sindre Sorhus +@license MIT +*/var r=Object.getOwnPropertySymbols,o=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable;function a(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(e){r[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var n,u,s=a(e),c=1;c0){var o=n.map((function(e){return console.error(e),e.line=e.fullPath?y(g,e.fullPath):null,e.path=e.fullPath?e.fullPath.join("."):null,e.level="error",e.type="thrown",e.source="resolver",O()(e,"message",{enumerable:!0,value:e.message}),e}));i.newThrownErrBatch(o)}return r.updateResolved(t)}))}},be=[],_e=V()(A()(C.a.mark((function e(){var t,n,r,o,i,a,u,s,c,l,f,p,h,d,v,m,y;return C.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t=be.system){e.next=4;break}return console.error("debResolveSubtrees: don't have a system to operate on, aborting."),e.abrupt("return");case 4:if(n=t.errActions,r=t.errSelectors,o=t.fn,i=o.resolveSubtree,a=o.AST,u=void 0===a?{}:a,s=t.specSelectors,c=t.specActions,i){e.next=8;break}return console.error("Error: Swagger-Client did not provide a `resolveSubtree` method, doing nothing."),e.abrupt("return");case 8:return l=u.getLineNumberForPath?u.getLineNumberForPath:function(){},f=s.specStr(),p=t.getConfigs(),h=p.modelPropertyMacro,d=p.parameterMacro,v=p.requestInterceptor,m=p.responseInterceptor,e.prev=11,e.next=14,be.reduce(function(){var e=A()(C.a.mark((function e(t,o){var a,u,c,p,y,g,b;return C.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t;case 2:return a=e.sent,u=a.resultMap,c=a.specWithCurrentSubtrees,e.next=7,i(c,o,{baseDoc:s.url(),modelPropertyMacro:h,parameterMacro:d,requestInterceptor:v,responseInterceptor:m});case 7:return p=e.sent,y=p.errors,g=p.spec,r.allErrors().size&&n.clearBy((function(e){return"thrown"!==e.get("type")||"resolver"!==e.get("source")||!e.get("fullPath").every((function(e,t){return e===o[t]||void 0===o[t]}))})),T()(y)&&y.length>0&&(b=y.map((function(e){return e.line=e.fullPath?l(f,e.fullPath):null,e.path=e.fullPath?e.fullPath.join("."):null,e.level="error",e.type="thrown",e.source="resolver",O()(e,"message",{enumerable:!0,value:e.message}),e})),n.newThrownErrBatch(b)),H()(u,o,g),H()(c,o,g),e.abrupt("return",{resultMap:u,specWithCurrentSubtrees:c});case 15:case"end":return e.stop()}}),e)})));return function(t,n){return e.apply(this,arguments)}}(),w.a.resolve({resultMap:(s.specResolvedSubtree([])||Object(N.Map)()).toJS(),specWithCurrentSubtrees:s.specJson().toJS()}));case 14:y=e.sent,delete be.system,be=[],e.next=22;break;case 19:e.prev=19,e.t0=e.catch(11),console.error(e.t0);case 22:c.updateResolvedSubtree([],y.resultMap);case 23:case"end":return e.stop()}}),e,null,[[11,19]])}))),35),xe=function(e){return function(t){be.map((function(e){return e.join("@@")})).indexOf(e.join("@@"))>-1||(be.push(e),be.system=t,_e())}};function we(e,t,n,r,o){return{type:X,payload:{path:e,value:r,paramName:t,paramIn:n,isXml:o}}}function Ee(e,t,n,r){return{type:X,payload:{path:e,param:t,value:n,isXml:r}}}var Ce=function(e,t){return{type:le,payload:{path:e,value:t}}},Se=function(){return{type:le,payload:{path:[],value:Object(N.Map)()}}},Ae=function(e,t){return{type:ee,payload:{pathMethod:e,isOAS3:t}}},ke=function(e,t,n,r){return{type:Q,payload:{pathMethod:e,paramName:t,paramIn:n,includeEmptyValue:r}}};function Oe(e){return{type:ue,payload:{pathMethod:e}}}function je(e,t){return{type:se,payload:{path:e,value:t,key:"consumes_value"}}}function Te(e,t){return{type:se,payload:{path:e,value:t,key:"produces_value"}}}var Pe=function(e,t,n){return{payload:{path:e,method:t,res:n},type:te}},Ie=function(e,t,n){return{payload:{path:e,method:t,req:n},type:ne}},Me=function(e,t,n){return{payload:{path:e,method:t,req:n},type:re}},De=function(e){return{payload:e,type:oe}},Ne=function(e){return function(t){var n=t.fn,r=t.specActions,o=t.specSelectors,i=t.getConfigs,a=t.oas3Selectors,u=e.pathName,s=e.method,c=e.operation,l=i(),f=l.requestInterceptor,p=l.responseInterceptor,h=c.toJS();if(c&&c.get("parameters")&&c.get("parameters").filter((function(e){return e&&!0===e.get("allowEmptyValue")})).forEach((function(t){if(o.parameterInclusionSettingFor([u,s],t.get("name"),t.get("in"))){e.parameters=e.parameters||{};var n=Object(J.D)(t,e.parameters);(!n||n&&0===n.size)&&(e.parameters[t.get("name")]="")}})),e.contextUrl=L()(o.url()).toString(),h&&h.operationId?e.operationId=h.operationId:h&&u&&s&&(e.operationId=n.opId(h,u,s)),o.isOAS3()){var d="".concat(u,":").concat(s);e.server=a.selectedServer(d)||a.selectedServer();var v=a.serverVariables({server:e.server,namespace:d}).toJS(),y=a.serverVariables({server:e.server}).toJS();e.serverVariables=_()(v).length?v:y,e.requestContentType=a.requestContentType(u,s),e.responseContentType=a.responseContentType(u,s)||"*/*";var b=a.requestBodyValue(u,s),x=a.requestBodyInclusionSetting(u,s);Object(J.u)(b)?e.requestBody=JSON.parse(b):b&&b.toJS?e.requestBody=b.filter((function(e,t){return!Object(J.r)(e)||x.get(t)})).toJS():e.requestBody=b}var w=g()({},e);w=n.buildRequest(w),r.setRequest(e.pathName,e.method,w);e.requestInterceptor=function(t){var n=f.apply(this,[t]),o=g()({},n);return r.setMutatedRequest(e.pathName,e.method,o),n},e.responseInterceptor=p;var E=m()();return n.execute(e).then((function(t){t.duration=m()()-E,r.setResponse(e.pathName,e.method,t)})).catch((function(t){console.error(t),r.setResponse(e.pathName,e.method,{error:!0,err:B()(t)})}))}},Re=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.path,n=e.method,r=d()(e,["path","method"]);return function(e){var o=e.fn.fetch,i=e.specSelectors,a=e.specActions,u=i.specJsonWithResolvedSubtrees().toJS(),s=i.operationScheme(t,n),c=i.contentTypeValues([t,n]).toJS(),l=c.requestContentType,f=c.responseContentType,p=/xml/i.test(l),h=i.parameterValues([t,n],p).toJS();return a.executeRequest($($({},r),{},{fetch:o,spec:u,pathName:t,method:n,parameters:h,requestContentType:l,scheme:s,responseContentType:f}))}};function Le(e,t){return{type:ie,payload:{path:e,method:t}}}function Fe(e,t){return{type:ae,payload:{path:e,method:t}}}function Be(e,t,n){return{type:fe,payload:{scheme:e,path:t,method:n}}}},function(e,t){var n=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(e,t,n){"use strict";var r=n(145),o=["kind","resolve","construct","instanceOf","predicate","represent","defaultStyle","styleAliases"],i=["scalar","sequence","mapping"];e.exports=function(e,t){var n,a;if(t=t||{},Object.keys(t).forEach((function(t){if(-1===o.indexOf(t))throw new r('Unknown option "'+t+'" is met in definition of "'+e+'" YAML type.')})),this.tag=e,this.kind=t.kind||null,this.resolve=t.resolve||function(){return!0},this.construct=t.construct||function(e){return e},this.instanceOf=t.instanceOf||null,this.predicate=t.predicate||null,this.represent=t.represent||null,this.defaultStyle=t.defaultStyle||null,this.styleAliases=(n=t.styleAliases||null,a={},null!==n&&Object.keys(n).forEach((function(e){n[e].forEach((function(t){a[String(t)]=e}))})),a),-1===i.indexOf(this.kind))throw new r('Unknown kind "'+this.kind+'" is specified for "'+e+'" YAML type.')}},function(e,t,n){var r=n(201)("wks"),o=n(203),i=n(43).Symbol,a="function"==typeof i;(e.exports=function(e){return r[e]||(r[e]=a&&i[e]||(a?i:o)("Symbol."+e))}).store=r},function(e,t){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},function(e,t,n){var r=n(218)("wks"),o=n(166),i=n(32).Symbol,a="function"==typeof i;(e.exports=function(e){return r[e]||(r[e]=a&&i[e]||(a?i:o)("Symbol."+e))}).store=r},function(e,t,n){var r=n(43),o=n(74),i=n(83),a=n(99),u=n(160),s=function(e,t,n){var c,l,f,p,h=e&s.F,d=e&s.G,v=e&s.S,m=e&s.P,y=e&s.B,g=d?r:v?r[t]||(r[t]={}):(r[t]||{}).prototype,b=d?o:o[t]||(o[t]={}),_=b.prototype||(b.prototype={});for(c in d&&(n=t),n)f=((l=!h&&g&&void 0!==g[c])?g:n)[c],p=y&&l?u(f,r):m&&"function"==typeof f?u(Function.call,f):f,g&&a(g,c,f,e&s.U),b[c]!=f&&i(b,c,p),m&&_[c]!=f&&(_[c]=f)};r.core=o,s.F=1,s.G=2,s.S=4,s.P=8,s.B=16,s.W=32,s.U=64,s.R=128,e.exports=s},function(e,t,n){var r=n(35);e.exports=function(e){if(!r(e))throw TypeError(e+" is not an object!");return e}},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t){var n=Array.isArray;e.exports=n},function(e,t,n){"use strict";var r=!("undefined"==typeof window||!window.document||!window.document.createElement),o={canUseDOM:r,canUseWorkers:"undefined"!=typeof Worker,canUseEventListeners:r&&!(!window.addEventListener&&!window.attachEvent),canUseViewport:r&&!!window.screen,isInWorker:!r};e.exports=o},function(e,t,n){var r=n(56),o=n(765);e.exports=function(e,t){if(null==e)return{};var n,i,a=o(e,t);if(r){var u=r(e);for(i=0;i=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}},function(e,t){var n=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(e,t,n){var r=n(37),o=n(101),i=n(75),a=/"/g,u=function(e,t,n,r){var o=String(i(e)),u="<"+t;return""!==n&&(u+=" "+n+'="'+String(r).replace(a,""")+'"'),u+">"+o+""};e.exports=function(e,t){var n={};n[e]=t(u),r(r.P+r.F*o((function(){var t=""[e]('"');return t!==t.toLowerCase()||t.split('"').length>3})),"String",n)}},function(e,t,n){e.exports=!n(78)((function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a}))},function(e,t,n){"use strict";n.r(t),n.d(t,"NEW_THROWN_ERR",(function(){return i})),n.d(t,"NEW_THROWN_ERR_BATCH",(function(){return a})),n.d(t,"NEW_SPEC_ERR",(function(){return u})),n.d(t,"NEW_SPEC_ERR_BATCH",(function(){return s})),n.d(t,"NEW_AUTH_ERR",(function(){return c})),n.d(t,"CLEAR",(function(){return l})),n.d(t,"CLEAR_BY",(function(){return f})),n.d(t,"newThrownErr",(function(){return p})),n.d(t,"newThrownErrBatch",(function(){return h})),n.d(t,"newSpecErr",(function(){return d})),n.d(t,"newSpecErrBatch",(function(){return v})),n.d(t,"newAuthErr",(function(){return m})),n.d(t,"clear",(function(){return y})),n.d(t,"clearBy",(function(){return g}));var r=n(125),o=n.n(r),i="err_new_thrown_err",a="err_new_thrown_err_batch",u="err_new_spec_err",s="err_new_spec_err_batch",c="err_new_auth_err",l="err_clear",f="err_clear_by";function p(e){return{type:i,payload:o()(e)}}function h(e){return{type:a,payload:e}}function d(e){return{type:u,payload:e}}function v(e){return{type:s,payload:e}}function m(e){return{type:c,payload:e}}function y(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return{type:l,payload:e}}function g(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:function(){return!0};return{type:f,payload:e}}},function(e,t,n){var r=n(100);e.exports=function(e){if(!r(e))throw TypeError(e+" is not an object!");return e}},function(e,t){"function"==typeof Object.create?e.exports=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:e.exports=function(e,t){e.super_=t;var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}},function(e,t,n){var r=n(79),o=r.Buffer;function i(e,t){for(var n in e)t[n]=e[n]}function a(e,t,n){return o(e,t,n)}o.from&&o.alloc&&o.allocUnsafe&&o.allocUnsafeSlow?e.exports=r:(i(r,t),t.Buffer=a),i(o,a),a.from=function(e,t,n){if("number"==typeof e)throw new TypeError("Argument must not be a number");return o(e,t,n)},a.alloc=function(e,t,n){if("number"!=typeof e)throw new TypeError("Argument must be a number");var r=o(e);return void 0!==t?"string"==typeof n?r.fill(t,n):r.fill(t):r.fill(0),r},a.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return o(e)},a.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return r.SlowBuffer(e)}},function(e,t,n){var r=n(38),o=n(352),i=n(222),a=Object.defineProperty;t.f=n(45)?Object.defineProperty:function(e,t,n){if(r(e),t=i(t,!0),r(n),o)try{return a(e,t,n)}catch(e){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(e[t]=n.value),e}},function(e,t,n){var r=n(372),o="object"==typeof self&&self&&self.Object===Object&&self,i=r||o||Function("return this")();e.exports=i},function(e,t){e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},function(e,t,n){"use strict";e.exports={debugTool:null}},function(e,t,n){e.exports=n(568)},function(e,t,n){e.exports=n(762)},function(e,t,n){e.exports=n(764)},function(e,t,n){"use strict";n.r(t),n.d(t,"UPDATE_SELECTED_SERVER",(function(){return r})),n.d(t,"UPDATE_REQUEST_BODY_VALUE",(function(){return o})),n.d(t,"UPDATE_REQUEST_BODY_INCLUSION",(function(){return i})),n.d(t,"UPDATE_ACTIVE_EXAMPLES_MEMBER",(function(){return a})),n.d(t,"UPDATE_REQUEST_CONTENT_TYPE",(function(){return u})),n.d(t,"UPDATE_RESPONSE_CONTENT_TYPE",(function(){return s})),n.d(t,"UPDATE_SERVER_VARIABLE_VALUE",(function(){return c})),n.d(t,"setSelectedServer",(function(){return l})),n.d(t,"setRequestBodyValue",(function(){return f})),n.d(t,"setRequestBodyInclusion",(function(){return p})),n.d(t,"setActiveExamplesMember",(function(){return h})),n.d(t,"setRequestContentType",(function(){return d})),n.d(t,"setResponseContentType",(function(){return v})),n.d(t,"setServerVariableValue",(function(){return m}));var r="oas3_set_servers",o="oas3_set_request_body_value",i="oas3_set_request_body_inclusion",a="oas3_set_active_examples_member",u="oas3_set_request_content_type",s="oas3_set_response_content_type",c="oas3_set_server_variable_value";function l(e,t){return{type:r,payload:{selectedServerUrl:e,namespace:t}}}function f(e){var t=e.value,n=e.pathMethod;return{type:o,payload:{value:t,pathMethod:n}}}function p(e){var t=e.value,n=e.pathMethod,r=e.name;return{type:i,payload:{value:t,pathMethod:n,name:r}}}function h(e){var t=e.name,n=e.pathMethod,r=e.contextType,o=e.contextName;return{type:a,payload:{name:t,pathMethod:n,contextType:r,contextName:o}}}function d(e){var t=e.value,n=e.pathMethod;return{type:u,payload:{value:t,pathMethod:n}}}function v(e){var t=e.value,n=e.path,r=e.method;return{type:s,payload:{value:t,path:n,method:r}}}function m(e){var t=e.server,n=e.namespace,r=e.key,o=e.val;return{type:c,payload:{server:t,namespace:n,key:r,val:o}}}},function(e,t,n){e.exports=function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=56)}([function(e,t){e.exports=n(17)},function(e,t){e.exports=n(15)},function(e,t){e.exports=n(28)},function(e,t){e.exports=n(18)},function(e,t){e.exports=n(129)},function(e,t){e.exports=n(62)},function(e,t){e.exports=n(55)},function(e,t){e.exports=n(56)},function(e,t){e.exports=n(3)},function(e,t){e.exports=n(54)},function(e,t){e.exports=n(96)},function(e,t){e.exports=n(927)},function(e,t){e.exports=n(30)},function(e,t){e.exports=n(13)},function(e,t){e.exports=n(194)},function(e,t){e.exports=n(933)},function(e,t){e.exports=n(95)},function(e,t){e.exports=n(14)},function(e,t){e.exports=n(81)},function(e,t){e.exports=n(124)},function(e,t){e.exports=n(123)},function(e,t){e.exports=n(121)},function(e,t){e.exports=n(122)},function(e,t){e.exports=n(195)},function(e,t){e.exports=n(936)},function(e,t){e.exports=n(6)},function(e,t){e.exports=n(7)},function(e,t){e.exports=n(939)},function(e,t){e.exports=n(943)},function(e,t){e.exports=n(944)},function(e,t){e.exports=n(1)},function(e,t){e.exports=n(153)},function(e,t){e.exports=n(946)},function(e,t){e.exports=n(4)},function(e,t){e.exports=n(79)},function(e,t){e.exports=n(422)},function(e,t){e.exports=n(949)},function(e,t){e.exports=n(950)},function(e,t){e.exports=n(52)},function(e,t){e.exports=n(951)},function(e,t){e.exports=n(955)},function(e,t){e.exports=n(8)},function(e,t){e.exports=n(10)},function(e,t){e.exports=n(960)},function(e,t){e.exports=n(961)},function(e,t){e.exports=n(962)},function(e,t){e.exports=n(276)},function(e,t){e.exports=n(72)},function(e,t){e.exports=n(152)},function(e,t){e.exports=n(963)},function(e,t){e.exports=n(971)},function(e,t){e.exports=n(972)},function(e,t){e.exports=n(42)},function(e,t){e.exports=n(269)},function(e,t){e.exports=n(40)},function(e,t){e.exports=n(973)},function(e,t,n){e.exports=n(59)},function(e,t){e.exports=n(974)},function(e,t){e.exports=n(975)},function(e,t,n){"use strict";n.r(t);var r={};n.r(r),n.d(r,"path",(function(){return Zn})),n.d(r,"query",(function(){return Xn})),n.d(r,"header",(function(){return er})),n.d(r,"cookie",(function(){return tr}));var o=n(9),i=n.n(o),a=n(10),u=n.n(a),s=n(5),c=n.n(s),l=n(6),f=n.n(l),p=n(7),h=n.n(p),d=n(0),v=n.n(d),m=n(8),y=n.n(m),g=n(15),b=n.n(g),_=n(29),x=n.n(_),w=n(11),E=n.n(w),C=n(20),S=n.n(C),A=n(21),k=n.n(A),O=n(22),j=n.n(O),T=n(4),P=n.n(T),I=n(39),M=n.n(I),D=n(12),N=n.n(D),R=n(1),L=n.n(R),F=n(2),B=n.n(F),U=n(17),q=n.n(U),z=n(18),V=n.n(z),W=n(23),H=n.n(W),J=(n(57),n(32)),K=n.n(J),$=n(31),Y=n.n($),G=n(24),Z=n.n(G),X=n(19),Q=n.n(X),ee=n(34),te=n(30),ne=n.n(te),re=n(25),oe=n.n(re),ie=n(26),ae=n.n(ie),ue=n(40),se=n.n(ue),ce=n(41),le=n.n(ce),fe=n(42),pe=n.n(fe),he=n(33),de=n.n(he),ve=n(43);function me(e){var t=function(){if("undefined"==typeof Reflect||!ne.a)return!1;if(ne.a.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(ne()(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=de()(e);if(t){var o=de()(this).constructor;n=ne()(r,arguments,o)}else n=r.apply(this,arguments);return pe()(this,n)}}var ye=function(e){var t=function(e,t){return{name:e,value:t}};return Q()(e.prototype.set)||Q()(e.prototype.get)||Q()(e.prototype.getAll)||Q()(e.prototype.has)?e:function(e){le()(r,e);var n=me(r);function r(e){var t;return oe()(this,r),(t=n.call(this,e))._entryList=[],t}return ae()(r,[{key:"append",value:function(e,n,o){return this._entryList.push(t(e,n)),se()(de()(r.prototype),"append",this).call(this,e,n,o)}},{key:"set",value:function(e,n){var r=t(e,n);this._entryList=this._entryList.filter((function(t){return t.name!==e})),this._entryList.push(r)}},{key:"get",value:function(e){var t=this._entryList.find((function(t){return t.name===e}));return void 0===t?null:t}},{key:"getAll",value:function(e){return this._entryList.filter((function(t){return t.name===e})).map((function(e){return e.value}))}},{key:"has",value:function(e){return this._entryList.some((function(t){return t.name===e}))}}]),r}(e)}(n.n(ve).a),ge=(n(58),n(44)),be=n.n(ge),_e=n(45),xe=function(e){return":/?#[]@!$&'()*+,;=".indexOf(e)>-1},we=function(e){return/^[a-z0-9\-._~]+$/i.test(e)};function Ee(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.escape,r=arguments.length>2?arguments[2]:void 0;return"number"==typeof e&&(e=e.toString()),"string"==typeof e&&e.length&&n?r?JSON.parse(e):Object(_e.stringToCharArray)(e).map((function(e){return we(e)||xe(e)&&"unsafe"===n?e:(be()(e)||[]).map((function(e){return"0".concat(e.toString(16).toUpperCase()).slice(-2)})).map((function(e){return"%".concat(e)})).join("")})).join(""):e}function Ce(e){var t=e.value;return L()(t)?function(e){var t=e.key,n=e.value,r=e.style,o=e.explode,i=e.escape,a=function(e){return Ee(e,{escape:i})};if("simple"===r)return n.map((function(e){return a(e)})).join(",");if("label"===r)return".".concat(n.map((function(e){return a(e)})).join("."));if("matrix"===r)return n.map((function(e){return a(e)})).reduce((function(e,n){return!e||o?"".concat(e||"",";").concat(t,"=").concat(n):"".concat(e,",").concat(n)}),"");if("form"===r){var u=o?"&".concat(t,"="):",";return n.map((function(e){return a(e)})).join(u)}if("spaceDelimited"===r){var s=o?"".concat(t,"="):"";return n.map((function(e){return a(e)})).join(" ".concat(s))}if("pipeDelimited"===r){var c=o?"".concat(t,"="):"";return n.map((function(e){return a(e)})).join("|".concat(c))}}(e):"object"===B()(t)?function(e){var t=e.key,n=e.value,r=e.style,o=e.explode,i=e.escape,a=function(e){return Ee(e,{escape:i})},u=v()(n);if("simple"===r)return u.reduce((function(e,t){var r=a(n[t]),i=o?"=":",",u=e?"".concat(e,","):"";return"".concat(u).concat(t).concat(i).concat(r)}),"");if("label"===r)return u.reduce((function(e,t){var r=a(n[t]),i=o?"=":".",u=e?"".concat(e,"."):".";return"".concat(u).concat(t).concat(i).concat(r)}),"");if("matrix"===r&&o)return u.reduce((function(e,t){var r=a(n[t]),o=e?"".concat(e,";"):";";return"".concat(o).concat(t,"=").concat(r)}),"");if("matrix"===r)return u.reduce((function(e,r){var o=a(n[r]),i=e?"".concat(e,","):";".concat(t,"=");return"".concat(i).concat(r,",").concat(o)}),"");if("form"===r)return u.reduce((function(e,t){var r=a(n[t]),i=e?"".concat(e).concat(o?"&":","):"",u=o?"=":",";return"".concat(i).concat(t).concat(u).concat(r)}),"")}(e):function(e){var t=e.key,n=e.value,r=e.style,o=e.escape,i=function(e){return Ee(e,{escape:o})};if("simple"===r)return i(n);if("label"===r)return".".concat(i(n));if("matrix"===r)return";".concat(t,"=").concat(i(n));if("form"===r)return i(n);if("deepObject"===r)return i(n)}(e)}function Se(e,t){var n;if(void 0===j.a||null==e[k.a]){if(L()(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return Ae(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return V()(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Ae(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,u=!1;return{s:function(){n=S()(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){u=!0,i=e},f:function(){try{a||null==n.return||n.return()}finally{if(u)throw i}}}}function Ae(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n1&&void 0!==u[1]?u[1]:{},"object"===B()(t)&&(t=(n=t).url),n.headers=n.headers||{},ke.mergeInQueryOrForm(n),n.headers&&v()(n.headers).forEach((function(e){var t=n.headers[e];"string"==typeof t&&(n.headers[e]=t.replace(/\n+/g," "))})),!n.requestInterceptor){e.next=12;break}return e.next=8,n.requestInterceptor(n);case 8:if(e.t0=e.sent,e.t0){e.next=11;break}e.t0=n;case 11:n=e.t0;case 12:return r=n.headers["content-type"]||n.headers["Content-Type"],/multipart\/form-data/i.test(r)&&(delete n.headers["content-type"],delete n.headers["Content-Type"]),e.prev=14,e.next=17,(n.userFetch||fetch)(n.url,n);case 17:return o=e.sent,e.next=20,ke.serializeRes(o,t,n);case 20:if(o=e.sent,!n.responseInterceptor){e.next=28;break}return e.next=24,n.responseInterceptor(o);case 24:if(e.t1=e.sent,e.t1){e.next=27;break}e.t1=o;case 27:o=e.t1;case 28:e.next=38;break;case 30:if(e.prev=30,e.t2=e.catch(14),o){e.next=34;break}throw e.t2;case 34:throw(i=new Error(o.statusText)).statusCode=i.status=o.status,i.responseError=e.t2,i;case 38:if(o.ok){e.next=43;break}throw(a=new Error(o.statusText)).statusCode=a.status=o.status,a.response=o,a;case 43:return e.abrupt("return",o);case 44:case"end":return e.stop()}}),e,null,[[14,30]])})))).apply(this,arguments)}var Te=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return/(json|xml|yaml|text)\b/.test(e)};function Pe(e,t){return t&&(0===t.indexOf("application/json")||t.indexOf("+json")>0)?JSON.parse(e):Y.a.safeLoad(e)}function Ie(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=n.loadSpec,o=void 0!==r&&r,i={ok:e.ok,url:e.url||t,status:e.status,statusText:e.statusText,headers:De(e.headers)},a=i.headers["content-type"],u=o||Te(a),s=u?e.text:e.blob||e.buffer;return s.call(e).then((function(e){if(i.text=e,i.data=e,u)try{var t=Pe(e,a);i.body=t,i.obj=t}catch(e){i.parseError=e}return i}))}function Me(e){return e.includes(", ")?e.split(", "):e}function De(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return Q()(e.entries)?V()(e.entries()).reduce((function(e,t){var n=q()(t,2),r=n[0],o=n[1];return e[r]=Me(o),e}),{}):{}}function Ne(e,t){return t||"undefined"==typeof navigator||(t=navigator),t&&"ReactNative"===t.product?!(!e||"object"!==B()(e)||"string"!=typeof e.uri):"undefined"!=typeof File&&e instanceof File||("undefined"!=typeof Blob&&e instanceof Blob||(void 0!==ee.Buffer&&e instanceof ee.Buffer||null!==e&&"object"===B()(e)&&"function"==typeof e.pipe))}function Re(e,t){return L()(e)&&e.some((function(e){return Ne(e,t)}))}var Le={form:",",spaceDelimited:"%20",pipeDelimited:"|"},Fe={csv:",",ssv:"%20",tsv:"%09",pipes:"|"};function Be(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=t.collectionFormat,o=t.allowEmptyValue,i=t.serializationOption,a=t.encoding,u="object"!==B()(t)||L()(t)?t:t.value,s=n?function(e){return e.toString()}:function(e){return encodeURIComponent(e)},c=s(e);if(void 0===u&&o)return[[c,""]];if(Ne(u)||Re(u))return[[c,u]];if(i)return Ue(e,u,n,i);if(a){if([B()(a.style),B()(a.explode),B()(a.allowReserved)].some((function(e){return"undefined"!==e})))return Ue(e,u,n,Z()(a,["style","explode","allowReserved"]));if(a.contentType){if("application/json"===a.contentType){var l="string"==typeof u?u:N()(u);return[[c,s(l)]]}return[[c,s(u.toString())]]}return"object"!==B()(u)?[[c,s(u)]]:L()(u)&&u.every((function(e){return"object"!==B()(e)}))?[[c,u.map(s).join(",")]]:[[c,s(N()(u))]]}return"object"!==B()(u)?[[c,s(u)]]:L()(u)?"multi"===r?[[c,u.map(s)]]:[[c,u.map(s).join(Fe[r||"csv"])]]:[[c,""]]}function Ue(e,t,n,r){var o=r.style||"form",i=void 0===r.explode?"form"===o:r.explode,a=!n&&(r&&r.allowReserved?"unsafe":"reserved"),u=function(e){return Ee(e,{escape:a})},s=n?function(e){return e}:function(e){return Ee(e,{escape:a})};return"object"!==B()(t)?[[s(e),u(t)]]:L()(t)?i?[[s(e),t.map(u)]]:[[s(e),t.map(u).join(Le[o])]]:"deepObject"===o?v()(t).map((function(n){return[s("".concat(e,"[").concat(n,"]")),u(t[n])]})):i?v()(t).map((function(e){return[s(e),u(t[e])]})):[[s(e),v()(t).map((function(e){return["".concat(s(e),",").concat(u(t[e]))]})).join(",")]]}function qe(e){return M()(e).reduce((function(e,t){var n,r=q()(t,2),o=Se(Be(r[0],r[1],!0));try{for(o.s();!(n=o.n()).done;){var i=n.value,a=q()(i,2),u=a[0],s=a[1];if(L()(s)){var c,l=Se(s);try{for(l.s();!(c=l.n()).done;){var f=c.value;e.append(u,f)}}catch(e){l.e(e)}finally{l.f()}}else e.append(u,s)}}catch(e){o.e(e)}finally{o.f()}return e}),new ye)}function ze(e){var t=v()(e).reduce((function(t,n){var r,o=Se(Be(n,e[n]));try{for(o.s();!(r=o.n()).done;){var i=r.value,a=q()(i,2),u=a[0],s=a[1];t[u]=s}}catch(e){o.e(e)}finally{o.f()}return t}),{});return K.a.stringify(t,{encode:!1,indices:!1})||""}function Ve(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.url,n=void 0===t?"":t,r=e.query,o=e.form,i=function(){for(var e=arguments.length,t=new Array(e),n=0;n0){var o=t(e,n[n.length-1],n);o&&(r=r.concat(o))}if(L()(e)){var i=e.map((function(e,r){return ht(e,t,n.concat(r))}));i&&(r=r.concat(i))}else if(yt(e)){var a=v()(e).map((function(r){return ht(e[r],t,n.concat(r))}));a&&(r=r.concat(a))}return r=vt(r)}function dt(e){return L()(e)?e:[e]}function vt(e){var t;return(t=[]).concat.apply(t,tt()(e.map((function(e){return L()(e)?vt(e):e}))))}function mt(e){return e.filter((function(e){return void 0!==e}))}function yt(e){return e&&"object"===B()(e)}function gt(e){return e&&"function"==typeof e}function bt(e){if(wt(e)){var t=e.op;return"add"===t||"remove"===t||"replace"===t}return!1}function _t(e){return bt(e)||wt(e)&&"mutation"===e.type}function xt(e){return _t(e)&&("add"===e.op||"replace"===e.op||"merge"===e.op||"mergeDeep"===e.op)}function wt(e){return e&&"object"===B()(e)}function Et(e,t){try{return rt.a.getValueByPointer(e,t)}catch(e){return console.error(e),{}}}var Ct=n(49),St=n.n(Ct),At=n(50),kt=n(37),Ot=n.n(kt);function jt(e,t){function n(){Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=(new Error).stack;for(var e=arguments.length,n=new Array(e),r=0;r-1&&-1===Mt.indexOf(n)||Dt.indexOf(r)>-1||Nt.some((function(e){return r.indexOf(e)>-1}))}function Lt(e,t){var n=e.split("#"),r=q()(n,2),o=r[0],i=r[1],a=E.a.resolve(o||"",t||"");return i?"".concat(a,"#").concat(i):a}var Ft=new RegExp("^([a-z]+://|//)","i"),Bt=jt("JSONRefError",(function(e,t,n){this.originalError=n,Ye()(this,t||{})})),Ut={},qt=new St.a,zt=[function(e){return"paths"===e[0]&&"responses"===e[3]&&"content"===e[5]&&"example"===e[7]},function(e){return"paths"===e[0]&&"requestBody"===e[3]&&"content"===e[4]&&"example"===e[6]}],Vt={key:"$ref",plugin:function(e,t,n,r){var o=r.getInstance(),i=n.slice(0,-1);if(!Rt(i)&&(a=i,!zt.some((function(e){return e(a)})))){var a,u=r.getContext(n).baseDoc;if("string"!=typeof e)return new Bt("$ref: must be a string (JSON-Ref)",{$ref:e,baseDoc:u,fullPath:n});var s,c,l,f=$t(e),p=f[0],h=f[1]||"";try{s=u||p?Jt(p,u):null}catch(t){return Kt(t,{pointer:h,$ref:e,basePath:s,fullPath:n})}if(function(e,t,n,r){var o=qt.get(r);o||(o={},qt.set(r,o));var i=function(e){if(0===e.length)return"";return"/".concat(e.map(en).join("/"))}(n),a="".concat(t||"","#").concat(e),u=i.replace(/allOf\/\d+\/?/g,""),s=r.contextTree.get([]).baseDoc;if(t==s&&tn(u,e))return!0;var c="";if(n.some((function(e){return c="".concat(c,"/").concat(en(e)),o[c]&&o[c].some((function(e){return tn(e,a)||tn(a,e)}))})))return!0;o[u]=(o[u]||[]).concat(a)}(h,s,i,r)&&!o.useCircularStructures){var d=Lt(e,s);return e===d?null:st.replace(n,d)}if(null==s?(l=Xt(h),void 0===(c=r.get(l))&&(c=new Bt("Could not resolve reference: ".concat(e),{pointer:h,$ref:e,baseDoc:u,fullPath:n}))):c=null!=(c=Yt(s,h)).__value?c.__value:c.catch((function(t){throw Kt(t,{pointer:h,$ref:e,baseDoc:u,fullPath:n})})),c instanceof Error)return[st.remove(n),c];var m=Lt(e,s),y=st.replace(i,c,{$$ref:m});if(s&&s!==u)return[y,st.context(i,{baseDoc:s})];try{if(!function(e,t){var n=[e];return t.path.reduce((function(e,t){return n.push(e[t]),e[t]}),e),function e(t){return st.isObject(t)&&(n.indexOf(t)>=0||v()(t).some((function(n){return e(t[n])})))}(t.value)}(r.state,y)||o.useCircularStructures)return y}catch(e){return null}}}},Wt=Ye()(Vt,{docCache:Ut,absoluteify:Jt,clearCache:function(e){void 0!==e?delete Ut[e]:v()(Ut).forEach((function(e){delete Ut[e]}))},JSONRefError:Bt,wrapError:Kt,getDoc:Gt,split:$t,extractFromDoc:Yt,fetchJSON:function(e){return Object(At.fetch)(e,{headers:{Accept:"application/json, application/yaml"},loadSpec:!0}).then((function(e){return e.text()})).then((function(e){return Y.a.safeLoad(e)}))},extract:Zt,jsonPointerToArray:Xt,unescapeJsonPointerToken:Qt}),Ht=Wt;function Jt(e,t){if(!Ft.test(e)){if(!t)throw new Bt("Tried to resolve a relative URL, without having a basePath. path: '".concat(e,"' basePath: '").concat(t,"'"));return E.a.resolve(t,e)}return e}function Kt(e,t){var n;return n=e&&e.response&&e.response.body?"".concat(e.response.body.code," ").concat(e.response.body.message):e.message,new Bt("Could not resolve reference: ".concat(n),t,e)}function $t(e){return(e+"").split("#")}function Yt(e,t){var n=Ut[e];if(n&&!st.isPromise(n))try{var r=Zt(t,n);return Ye()(He.a.resolve(r),{__value:r})}catch(e){return He.a.reject(e)}return Gt(e).then((function(e){return Zt(t,e)}))}function Gt(e){var t=Ut[e];return t?st.isPromise(t)?t:He.a.resolve(t):(Ut[e]=Wt.fetchJSON(e).then((function(t){return Ut[e]=t,t})),Ut[e])}function Zt(e,t){var n=Xt(e);if(n.length<1)return t;var r=st.getIn(t,n);if(void 0===r)throw new Bt("Could not resolve pointer: ".concat(e," does not exist in document"),{pointer:e});return r}function Xt(e){if("string"!=typeof e)throw new TypeError("Expected a string, got a ".concat(B()(e)));return"/"===e[0]&&(e=e.substr(1)),""===e?[]:e.split("/").map(Qt)}function Qt(e){return"string"!=typeof e?e:Ot.a.unescape(e.replace(/~1/g,"/").replace(/~0/g,"~"))}function en(e){return Ot.a.escape(e.replace(/~/g,"~0").replace(/\//g,"~1"))}function tn(e,t){if(!(n=t)||"/"===n||"#"===n)return!0;var n,r=e.charAt(t.length),o=t.slice(-1);return 0===e.indexOf(t)&&(!r||"/"===r||"#"===r)&&"#"!==o}var nn={key:"allOf",plugin:function(e,t,n,r,o){if(!o.meta||!o.meta.$$ref){var i=n.slice(0,-1);if(!Rt(i)){if(!L()(e)){var a=new TypeError("allOf must be an array");return a.fullPath=n,a}var u=!1,s=o.value;i.forEach((function(e){s&&(s=s[e])})),delete(s=Ye()({},s)).allOf;var c=[];return c.push(r.replace(i,{})),e.forEach((function(e,t){if(!r.isObject(e)){if(u)return null;u=!0;var o=new TypeError("Elements in allOf must be objects");return o.fullPath=n,c.push(o)}c.push(r.mergeDeep(i,e));var a=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=n.specmap,o=n.getBaseUrlForNodePath,i=void 0===o?function(e){return r.getContext([].concat(tt()(t),tt()(e))).baseDoc}:o,a=n.targetKeys,u=void 0===a?["$ref","$$ref"]:a,s=[];return Pt()(e).forEach((function(){if(u.indexOf(this.key)>-1){var e=this.path,n=t.concat(this.path),o=Lt(this.node,i(e));s.push(r.replace(n,o))}})),s}(e,n.slice(0,-1),{getBaseUrlForNodePath:function(e){return r.getContext([].concat(tt()(n),[t],tt()(e))).baseDoc},specmap:r});c.push.apply(c,tt()(a))})),c.push(r.mergeDeep(i,s)),s.$$ref||c.push(r.remove([].concat(i,"$$ref"))),c}}}},rn={key:"parameters",plugin:function(e,t,n,r,o){if(L()(e)&&e.length){var i=Ye()([],e),a=n.slice(0,-1),u=Ye()({},st.getIn(r.spec,a));return e.forEach((function(e,t){try{i[t].default=r.parameterMacro(u,e)}catch(e){var o=new Error(e);return o.fullPath=n,o}})),st.replace(n,i)}return st.replace(n,e)}},on={key:"properties",plugin:function(e,t,n,r){var o=Ye()({},e);for(var i in e)try{o[i].default=r.modelPropertyMacro(o[i])}catch(e){var a=new Error(e);return a.fullPath=n,a}return st.replace(n,o)}};function an(e,t){var n=v()(e);if(h.a){var r=h()(e);t&&(r=r.filter((function(t){return f()(e,t).enumerable}))),n.push.apply(n,r)}return n}function un(e){for(var t=1;t=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,u=!1;return{s:function(){n=S()(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){u=!0,i=e},f:function(){try{a||null==n.return||n.return()}finally{if(u)throw i}}}}function pn(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n1?n-1:0),o=1;o1?n-1:0),o=1;o0}))}},{key:"nextPromisedPatch",value:function(){if(this.promisedPatches.length>0)return He.a.race(this.promisedPatches.map((function(e){return e.value})))}},{key:"getPluginHistory",value:function(e){var t=this.getPluginName(e);return this.pluginHistory[t]||[]}},{key:"getPluginRunCount",value:function(e){return this.getPluginHistory(e).length}},{key:"getPluginHistoryTip",value:function(e){var t=this.getPluginHistory(e);return t&&t[t.length-1]||{}}},{key:"getPluginMutationIndex",value:function(e){var t=this.getPluginHistoryTip(e).mutationIndex;return"number"!=typeof t?-1:t}},{key:"getPluginName",value:function(e){return e.pluginName}},{key:"updatePluginHistory",value:function(e,t){var n=this.getPluginName(e);(this.pluginHistory[n]=this.pluginHistory[n]||[]).push(t)}},{key:"updatePatches",value:function(e,t){var n=this;st.normalizeArray(e).forEach((function(e){if(e instanceof Error)n.errors.push(e);else try{if(!st.isObject(e))return void n.debug("updatePatches","Got a non-object patch",e);if(n.showDebug&&n.allPatches.push(e),st.isPromise(e.value))return n.promisedPatches.push(e),void n.promisedPatchThen(e);if(st.isContextPatch(e))return void n.setContext(e.path,e.value);if(st.isMutation(e))return void n.updateMutations(e)}catch(e){console.error(e),n.errors.push(e)}}))}},{key:"updateMutations",value:function(e){"object"===B()(e.value)&&!L()(e.value)&&this.allowMetaPatches&&(e.value=Ye()({},e.value));var t=st.applyPatch(this.state,e,{allowMetaPatches:this.allowMetaPatches});t&&(this.mutations.push(e),this.state=t)}},{key:"removePromisedPatch",value:function(e){var t=this.promisedPatches.indexOf(e);t<0?this.debug("Tried to remove a promisedPatch that isn't there!"):this.promisedPatches.splice(t,1)}},{key:"promisedPatchThen",value:function(e){var t=this;return e.value=e.value.then((function(n){var r=Ye()({},e,{value:n});t.removePromisedPatch(e),t.updatePatches(r)})).catch((function(n){t.removePromisedPatch(e),t.updatePatches(n)}))}},{key:"getMutations",value:function(e,t){return e=e||0,"number"!=typeof t&&(t=this.mutations.length),this.mutations.slice(e,t)}},{key:"getCurrentMutations",value:function(){return this.getMutationsForPlugin(this.getCurrentPlugin())}},{key:"getMutationsForPlugin",value:function(e){var t=this.getPluginMutationIndex(e);return this.getMutations(t+1)}},{key:"getCurrentPlugin",value:function(){return this.currentPlugin}},{key:"getPatchesOfType",value:function(e,t){return e.filter(t)}},{key:"getLib",value:function(){return this.libMethods}},{key:"_get",value:function(e){return st.getIn(this.state,e)}},{key:"_getContext",value:function(e){return this.contextTree.get(e)}},{key:"setContext",value:function(e,t){return this.contextTree.set(e,t)}},{key:"_hasRun",value:function(e){return this.getPluginRunCount(this.getCurrentPlugin())>(e||0)}},{key:"_clone",value:function(e){return JSON.parse(N()(e))}},{key:"dispatch",value:function(){var e=this,t=this,n=this.nextPlugin();if(!n){var r=this.nextPromisedPatch();if(r)return r.then((function(){return e.dispatch()})).catch((function(){return e.dispatch()}));var o={spec:this.state,errors:this.errors};return this.showDebug&&(o.patches=this.allPatches),He.a.resolve(o)}if(t.pluginCount=t.pluginCount||{},t.pluginCount[n]=(t.pluginCount[n]||0)+1,t.pluginCount[n]>100)return He.a.resolve({spec:t.state,errors:t.errors.concat(new Error("We've reached a hard limit of ".concat(100," plugin runs")))});if(n!==this.currentPlugin&&this.promisedPatches.length){var i=this.promisedPatches.map((function(e){return e.value}));return He.a.all(i.map((function(e){return e.then(Qe.a,Qe.a)}))).then((function(){return e.dispatch()}))}return function(){t.currentPlugin=n;var e=t.getCurrentMutations(),r=t.mutations.length-1;try{if(n.isGenerator){var o,i=fn(n(e,t.getLib()));try{for(i.s();!(o=i.n()).done;){a(o.value)}}catch(e){i.e(e)}finally{i.f()}}else{a(n(e,t.getLib()))}}catch(e){console.error(e),a([Ye()(Ke()(e),{plugin:n})])}finally{t.updatePluginHistory(n,{mutationIndex:r})}return t.dispatch()}();function a(e){e&&(e=st.fullyNormalizeArray(e),t.updatePatches(e,n))}}}]),e}();var dn={refs:Ht,allOf:nn,parameters:rn,properties:on},vn=n(38),mn=n.n(vn);function yn(e,t){var n;if(void 0===j.a||null==e[k.a]){if(L()(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return gn(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return V()(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return gn(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,u=!1;return{s:function(){n=S()(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){u=!0,i=e},f:function(){try{a||null==n.return||n.return()}finally{if(u)throw i}}}}function gn(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n2&&void 0!==arguments[2]?arguments[2]:"",r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},o=r.v2OperationIdCompatibilityMode;if(!e||"object"!==B()(e))return null;var i=(e.operationId||"").replace(/\s/g,"");return i.length?_n(e.operationId):En(t,n,{v2OperationIdCompatibilityMode:o})}function En(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=n.v2OperationIdCompatibilityMode;if(r){var o="".concat(t.toLowerCase(),"_").concat(e).replace(/[\s!@#$%^&*()_+=[{\]};:<>|./?,\\'""-]/g,"_");return(o=o||"".concat(e.substring(1),"_").concat(t)).replace(/((_){2,})/g,"_").replace(/^(_)*/g,"").replace(/([_])*$/g,"")}return"".concat(bn(t)).concat(_n(e))}function Cn(e,t){return"".concat(bn(t),"-").concat(e)}function Sn(e,t){return e&&e.paths?function(e,t){return An(e,t,!0)||null}(e,(function(e){var n=e.pathName,r=e.method,o=e.operation;if(!o||"object"!==B()(o))return!1;var i=o.operationId;return[wn(o,n,r),Cn(n,r),i].some((function(e){return e&&e===t}))})):null}function An(e,t,n){if(!e||"object"!==B()(e)||!e.paths||"object"!==B()(e.paths))return null;var r=e.paths;for(var o in r)for(var i in r[o])if("PARAMETERS"!==i.toUpperCase()){var a=r[o][i];if(a&&"object"===B()(a)){var u={spec:e,pathName:o,method:i.toUpperCase(),operation:a},s=t(u);if(n&&s)return u}}}function kn(e){var t=e.spec,n=t.paths,r={};if(!n||t.$$normalized)return e;for(var o in n){var i=n[o];if(mn()(i)){var a=i.parameters,u=function(e){var n=i[e];if(!mn()(n))return"continue";var u=wn(n,o,e);if(u){r[u]?r[u].push(n):r[u]=[n];var s=r[u];if(s.length>1)s.forEach((function(e,t){e.__originalOperationId=e.__originalOperationId||e.operationId,e.operationId="".concat(u).concat(t+1)}));else if(void 0!==n.operationId){var c=s[0];c.__originalOperationId=c.__originalOperationId||n.operationId,c.operationId=u}}if("parameters"!==e){var l=[],f={};for(var p in t)"produces"!==p&&"consumes"!==p&&"security"!==p||(f[p]=t[p],l.push(f));if(a&&(f.parameters=a,l.push(f)),l.length){var h,d=yn(l);try{for(d.s();!(h=d.n()).done;){var v=h.value;for(var m in v)if(n[m]){if("parameters"===m){var y,g=yn(v[m]);try{var b=function(){var e=y.value;n[m].some((function(t){return t.name&&t.name===e.name||t.$ref&&t.$ref===e.$ref||t.$$ref&&t.$$ref===e.$$ref||t===e}))||n[m].push(e)};for(g.s();!(y=g.n()).done;)b()}catch(e){g.e(e)}finally{g.f()}}}else n[m]=v[m]}}catch(e){d.e(e)}finally{d.f()}}}};for(var s in i)u(s)}}return t.$$normalized=!0,e}function On(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.requestInterceptor,r=t.responseInterceptor,o=e.withCredentials?"include":"same-origin";return function(t){return e({url:t,loadSpec:!0,requestInterceptor:n,responseInterceptor:r,headers:{Accept:"application/json, application/yaml"},credentials:o}).then((function(e){return e.body}))}}function jn(e){var t=e.fetch,n=e.spec,r=e.url,o=e.mode,i=e.allowMetaPatches,a=void 0===i||i,u=e.pathDiscriminator,s=e.modelPropertyMacro,c=e.parameterMacro,l=e.requestInterceptor,f=e.responseInterceptor,p=e.skipNormalization,h=e.useCircularStructures,d=e.http,v=e.baseDoc;return v=v||r,d=t||d||Oe,n?m(n):On(d,{requestInterceptor:l,responseInterceptor:f})(v).then(m);function m(e){v&&(dn.refs.docCache[v]=e),dn.refs.fetchJSON=On(d,{requestInterceptor:l,responseInterceptor:f});var t,n=[dn.refs];return"function"==typeof c&&n.push(dn.parameters),"function"==typeof s&&n.push(dn.properties),"strict"!==o&&n.push(dn.allOf),(t={spec:e,context:{baseDoc:v},plugins:n,allowMetaPatches:a,pathDiscriminator:u,parameterMacro:c,modelPropertyMacro:s,useCircularStructures:h},new hn(t).dispatch()).then(p?function(){var e=H()(P.a.mark((function e(t){return P.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",t);case 1:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}():kn)}}var Tn=n(16),Pn=n.n(Tn);function In(e,t){var n=v()(e);if(h.a){var r=h()(e);t&&(r=r.filter((function(t){return f()(e,t).enumerable}))),n.push.apply(n,r)}return n}function Mn(e){for(var t=1;t2&&void 0!==v[2]?v[2]:{},o=r.returnEntireTree,i=r.baseDoc,a=r.requestInterceptor,u=r.responseInterceptor,s=r.parameterMacro,c=r.modelPropertyMacro,l=r.useCircularStructures,f={pathDiscriminator:n,baseDoc:i,requestInterceptor:a,responseInterceptor:u,parameterMacro:s,modelPropertyMacro:c,useCircularStructures:l},p=kn({spec:t}),h=p.spec,e.next=6,jn(Mn(Mn({},f),{},{spec:h,allowMetaPatches:!0,skipNormalization:!0}));case 6:return d=e.sent,!o&&L()(n)&&n.length&&(d.spec=Pn()(d.spec,n)||null),e.abrupt("return",d);case 9:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function Nn(e,t){var n=v()(e);if(h.a){var r=h()(e);t&&(r=r.filter((function(t){return f()(e,t).enumerable}))),n.push.apply(n,r)}return n}function Rn(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:{};return function(t){var n=t.pathName,r=t.method,o=t.operationId;return function(t){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e.execute(Rn(Rn({spec:e.spec},Z()(e,"requestInterceptor","responseInterceptor","userFetch")),{},{pathName:n,method:r,parameters:t,operationId:o},i))}}}};var Bn=n(52),Un=n.n(Bn),qn=n(53),zn=n.n(qn),Vn=n(54),Wn=n.n(Vn),Hn=n(28),Jn=n.n(Hn),Kn=n(55),$n=n.n(Kn),Yn={body:function(e){var t=e.req,n=e.value;t.body=n},header:function(e){var t=e.req,n=e.parameter,r=e.value;t.headers=t.headers||{},void 0!==r&&(t.headers[n.name]=r)},query:function(e){var t=e.req,n=e.value,r=e.parameter;t.query=t.query||{},!1===n&&"boolean"===r.type&&(n="false");0===n&&["number","integer"].indexOf(r.type)>-1&&(n="0");if(n)t.query[r.name]={collectionFormat:r.collectionFormat,value:n};else if(r.allowEmptyValue&&void 0!==n){var o=r.name;t.query[o]=t.query[o]||{},t.query[o].allowEmptyValue=!0}},path:function(e){var t=e.req,n=e.value,r=e.parameter;t.url=t.url.split("{".concat(r.name,"}")).join(encodeURIComponent(n))},formData:function(e){var t=e.req,n=e.value,r=e.parameter;(n||r.allowEmptyValue)&&(t.form=t.form||{},t.form[r.name]={value:n,allowEmptyValue:r.allowEmptyValue,collectionFormat:r.collectionFormat})}};function Gn(e,t){return t.includes("application/json")?"string"==typeof e?e:N()(e):e.toString()}function Zn(e){var t=e.req,n=e.value,r=e.parameter,o=r.name,i=r.style,a=r.explode,u=r.content;if(u){var s=v()(u)[0];t.url=t.url.split("{".concat(o,"}")).join(Ee(Gn(n,s),{escape:!0}))}else{var c=Ce({key:r.name,value:n,style:i||"simple",explode:a||!1,escape:!0});t.url=t.url.split("{".concat(o,"}")).join(c)}}function Xn(e){var t=e.req,n=e.value,r=e.parameter;if(t.query=t.query||{},r.content){var o=v()(r.content)[0];t.query[r.name]=Gn(n,o)}else if(!1===n&&(n="false"),0===n&&(n="0"),n)t.query[r.name]={value:n,serializationOption:Z()(r,["style","explode","allowReserved"])};else if(r.allowEmptyValue&&void 0!==n){var i=r.name;t.query[i]=t.query[i]||{},t.query[i].allowEmptyValue=!0}}var Qn=["accept","authorization","content-type"];function er(e){var t=e.req,n=e.parameter,r=e.value;if(t.headers=t.headers||{},!(Qn.indexOf(n.name.toLowerCase())>-1))if(n.content){var o=v()(n.content)[0];t.headers[n.name]=Gn(r,o)}else void 0!==r&&(t.headers[n.name]=Ce({key:n.name,value:r,style:n.style||"simple",explode:void 0!==n.explode&&n.explode,escape:!1}))}function tr(e){var t=e.req,n=e.parameter,r=e.value;t.headers=t.headers||{};var o=B()(r);if(n.content){var i=v()(n.content)[0];t.headers.Cookie="".concat(n.name,"=").concat(Gn(r,i))}else if("undefined"!==o){var a="object"===o&&!L()(r)&&n.explode?"":"".concat(n.name,"=");t.headers.Cookie=a+Ce({key:n.name,value:r,escape:!1,style:n.style||"form",explode:void 0!==n.explode&&n.explode})}}var nr=function(e,t){var n=e.operation,r=e.requestBody,o=e.securities,i=e.spec,a=e.attachContentTypeForEmptyPayload,u=e.requestContentType;t=function(e){var t=e.request,n=e.securities,r=void 0===n?{}:n,o=e.operation,i=void 0===o?{}:o,a=e.spec,u=b()({},t),s=r.authorized,c=void 0===s?{}:s,l=i.security||a.security||[],f=c&&!!v()(c).length,p=Pn()(a,["components","securitySchemes"])||{};if(u.headers=u.headers||{},u.query=u.query||{},!v()(r).length||!f||!l||L()(i.security)&&!i.security.length)return t;return l.forEach((function(e,t){for(var n in e){var r=c[n],o=p[n];if(r){var i=r.value||r,a=o.type;if(r)if("apiKey"===a)"query"===o.in&&(u.query[o.name]=i),"header"===o.in&&(u.headers[o.name]=i),"cookie"===o.in&&(u.cookies[o.name]=i);else if("http"===a){if(/^basic$/i.test(o.scheme)){var s=i.username||"",l=i.password||"",f=Jn()("".concat(s,":").concat(l));u.headers.Authorization="Basic ".concat(f)}/^bearer$/i.test(o.scheme)&&(u.headers.Authorization="Bearer ".concat(i))}else if("oauth2"===a){var h=r.token||{},d=h[o["x-tokenName"]||"access_token"],v=h.token_type;v&&"bearer"!==v.toLowerCase()||(v="Bearer"),u.headers.Authorization="".concat(v," ").concat(d)}}}})),u}({request:t,securities:o,operation:n,spec:i});var s=n.requestBody||{},c=v()(s.content||{}),l=u&&c.indexOf(u)>-1;if(r||a){if(u&&l)t.headers["Content-Type"]=u;else if(!u){var f=c[0];f&&(t.headers["Content-Type"]=f,u=f)}}else u&&l&&(t.headers["Content-Type"]=u);if(r)if(u){if(c.indexOf(u)>-1)if("application/x-www-form-urlencoded"===u||"multipart/form-data"===u)if("object"===B()(r)){var p=(s.content[u]||{}).encoding||{};t.form={},v()(r).forEach((function(e){t.form[e]={value:r[e],encoding:p[e]||{}}}))}else t.form=r;else t.body=r}else t.body=r;return t};var rr=function(e,t){var n=e.spec,r=e.operation,o=e.securities,i=e.requestContentType,a=e.attachContentTypeForEmptyPayload;if((t=function(e){var t=e.request,n=e.securities,r=void 0===n?{}:n,o=e.operation,i=void 0===o?{}:o,a=e.spec,u=b()({},t),s=r.authorized,c=void 0===s?{}:s,l=r.specSecurity,f=void 0===l?[]:l,p=i.security||f,h=c&&!!v()(c).length,d=a.securityDefinitions;if(u.headers=u.headers||{},u.query=u.query||{},!v()(r).length||!h||!p||L()(i.security)&&!i.security.length)return t;return p.forEach((function(e,t){for(var n in e){var r=c[n];if(r){var o=r.token,i=r.value||r,a=d[n],s=a.type,l=a["x-tokenName"]||"access_token",f=o&&o[l],p=o&&o.token_type;if(r)if("apiKey"===s){var h="query"===a.in?"query":"headers";u[h]=u[h]||{},u[h][a.name]=i}else if("basic"===s)if(i.header)u.headers.authorization=i.header;else{var v=i.username||"",m=i.password||"";i.base64=Jn()("".concat(v,":").concat(m)),u.headers.authorization="Basic ".concat(i.base64)}else"oauth2"===s&&f&&(p=p&&"bearer"!==p.toLowerCase()?p:"Bearer",u.headers.authorization="".concat(p," ").concat(f))}}})),u}({request:t,securities:o,operation:r,spec:n})).body||t.form||a)i?t.headers["Content-Type"]=i:L()(r.consumes)?t.headers["Content-Type"]=r.consumes[0]:L()(n.consumes)?t.headers["Content-Type"]=n.consumes[0]:r.parameters&&r.parameters.filter((function(e){return"file"===e.type})).length?t.headers["Content-Type"]="multipart/form-data":r.parameters&&r.parameters.filter((function(e){return"formData"===e.in})).length&&(t.headers["Content-Type"]="application/x-www-form-urlencoded");else if(i){var u=r.parameters&&r.parameters.filter((function(e){return"body"===e.in})).length>0,s=r.parameters&&r.parameters.filter((function(e){return"formData"===e.in})).length>0;(u||s)&&(t.headers["Content-Type"]=i)}return t};function or(e,t){var n=v()(e);if(h.a){var r=h()(e);t&&(r=r.filter((function(t){return f()(e,t).enumerable}))),n.push.apply(n,r)}return n}function ir(e){for(var t=1;t1&&console.warn("Parameter '".concat(e.name,"' is ambiguous because the defined spec has more than one parameter with the name: '").concat(e.name,"' and the passed-in parameter values did not define an 'in' value.")),null!==n){if(void 0!==e.default&&void 0===n&&(n=e.default),void 0===n&&e.required&&!e.allowEmptyValue)throw new Error("Required parameter ".concat(e.name," is not provided"));if(m&&e.schema&&"object"===e.schema.type&&"string"==typeof n)try{n=JSON.parse(n)}catch(e){throw new Error("Could not parse object parameter value string as JSON")}r&&r({req:y,parameter:e,value:n,operation:_,spec:t})}}));var S=ir(ir({},e),{},{operation:_});if((y=m?nr(S,y):rr(S,y)).cookies&&v()(y.cookies).length){var A=v()(y.cookies).reduce((function(e,t){var n=y.cookies[t];return e+(e?"&":"")+$n.a.serialize(t,n)}),"");y.headers.Cookie=A}return y.cookies&&delete y.cookies,Ve(y),y}var lr=function(e){return e?e.replace(/\W/g,""):null};function fr(e){return xn(e.spec)?function(e){var t=e.spec,n=e.pathName,r=e.method,o=e.server,i=e.contextUrl,a=e.serverVariables,u=void 0===a?{}:a,s=Pn()(t,["paths",n,(r||"").toLowerCase(),"servers"])||Pn()(t,["paths",n,"servers"])||Pn()(t,["servers"]),c="",l=null;if(o&&s&&s.length){var f=s.map((function(e){return e.url}));f.indexOf(o)>-1&&(c=o,l=s[f.indexOf(o)])}!c&&s&&s.length&&(c=s[0].url,l=s[0]);if(c.indexOf("{")>-1){(function(e){var t,n=[],r=/{([^}]+)}/g;for(;t=r.exec(e);)n.push(t[1]);return n})(c).forEach((function(e){if(l.variables&&l.variables[e]){var t=l.variables[e],n=u[e]||t.default,r=new RegExp("{".concat(e,"}"),"g");c=c.replace(r,n)}}))}return function(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",r=E.a.parse(t),o=E.a.parse(n),i=lr(r.protocol)||lr(o.protocol)||"",a=r.host||o.host,u=r.pathname||"";e=i&&a?"".concat(i,"://").concat(a+u):u;return"/"===e[e.length-1]?e.slice(0,-1):e}(c,i)}(e):function(e){var t,n=e.spec,r=e.scheme,o=e.contextUrl,i=void 0===o?"":o,a=E.a.parse(i),u=L()(n.schemes)?n.schemes[0]:null,s=r||u||lr(a.protocol)||"http",c=n.host||a.host||"",l=n.basePath||"";t=s&&c?"".concat(s,"://").concat(c+l):l;return"/"===t[t.length-1]?t.slice(0,-1):t}(e)}function pr(e,t){var n=v()(e);if(h.a){var r=h()(e);t&&(r=r.filter((function(t){return f()(e,t).enumerable}))),n.push.apply(n,r)}return n}function hr(e){for(var t=1;t1&&void 0!==arguments[1]?arguments[1]:{};if("string"==typeof e?n.url=e:n=e,!(this instanceof dr))return new dr(n);b()(this,n);var r=this.resolve().then((function(){return t.disableInterfaces||b()(t,dr.makeApisTagOperation(t)),t}));return r.client=this,r}dr.http=Oe,dr.makeHttp=function(e,t,n){return n=n||function(e){return e},t=t||function(e){return e},function(r){return"string"==typeof r&&(r={url:r}),ke.mergeInQueryOrForm(r),r=t(r),n(e(r))}}.bind(null,dr.http),dr.resolve=jn,dr.resolveSubtree=function(e,t){return Dn.apply(this,arguments)},dr.execute=function(e){var t=e.http,n=e.fetch,r=e.spec,o=e.operationId,i=e.pathName,a=e.method,u=e.parameters,s=e.securities,c=Un()(e,["http","fetch","spec","operationId","pathName","method","parameters","securities"]),l=t||n||Oe;i&&a&&!o&&(o=Cn(i,a));var f=sr.buildRequest(ir({spec:r,operationId:o,parameters:u,securities:s,http:l},c));return f.body&&(zn()(f.body)||Wn()(f.body))&&(f.body=N()(f.body)),l(f)},dr.serializeRes=Ie,dr.serializeHeaders=De,dr.clearCache=function(){dn.refs.clearCache()},dr.makeApisTagOperation=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=Fn.makeExecute(e);return{apis:Fn.mapTagOperations({v2OperationIdCompatibilityMode:e.v2OperationIdCompatibilityMode,spec:e.spec,cb:t})}},dr.buildRequest=cr,dr.helpers={opId:wn},dr.getBaseUrl=fr,dr.prototype={http:Oe,execute:function(e){return this.applyDefaults(),dr.execute(hr({spec:this.spec,http:this.http,securities:{authorized:this.authorizations},contextUrl:"string"==typeof this.url?this.url:void 0,requestInterceptor:this.requestInterceptor||null,responseInterceptor:this.responseInterceptor||null},e))},resolve:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return dr.resolve(hr({spec:this.spec,url:this.url,http:this.http,allowMetaPatches:this.allowMetaPatches,useCircularStructures:this.useCircularStructures,requestInterceptor:this.requestInterceptor||null,responseInterceptor:this.responseInterceptor||null},t)).then((function(t){return e.originalSpec=e.spec,e.spec=t.spec,e.errors=t.errors,e}))}},dr.prototype.applyDefaults=function(){var e=this.spec,t=this.url;if(t&&x()(t,"http")){var n=E.a.parse(t);e.host||(e.host=n.host),e.schemes||(e.schemes=[n.protocol.replace(":","")]),e.basePath||(e.basePath="/")}};t.default=dr}]).default},function(e,t,n){"use strict";function r(e){return function(){return e}}var o=function(){};o.thatReturns=r,o.thatReturnsFalse=r(!1),o.thatReturnsTrue=r(!0),o.thatReturnsNull=r(null),o.thatReturnsThis=function(){return this},o.thatReturnsArgument=function(e){return e},e.exports=o},function(e,t,n){"use strict";var r=n(23),o=n(26),i=n(428),a=n(93),u=n(429),s=n(118),c=n(189),l=n(16),f=[],p=0,h=i.getPooled(),d=!1,v=null;function m(){w.ReactReconcileTransaction&&v||r("123")}var y=[{initialize:function(){this.dirtyComponentsLength=f.length},close:function(){this.dirtyComponentsLength!==f.length?(f.splice(0,this.dirtyComponentsLength),x()):f.length=0}},{initialize:function(){this.callbackQueue.reset()},close:function(){this.callbackQueue.notifyAll()}}];function g(){this.reinitializeTransaction(),this.dirtyComponentsLength=null,this.callbackQueue=i.getPooled(),this.reconcileTransaction=w.ReactReconcileTransaction.getPooled(!0)}function b(e,t){return e._mountOrder-t._mountOrder}function _(e){var t=e.dirtyComponentsLength;t!==f.length&&r("124",t,f.length),f.sort(b),p++;for(var n=0;n1)for(var n=1;n0&&"/"!==t[0]}));function oe(e,t,n){return t=t||[],te.apply(void 0,[e].concat(s()(t))).get("parameters",Object(f.List)()).reduce((function(e,t){var r=n&&"body"===t.get("in")?t.get("value_xml"):t.get("value");return e.set(Object(l.C)(t,{allowHashes:!1}),r)}),Object(f.fromJS)({}))}function ie(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";if(f.List.isList(e))return e.some((function(e){return f.Map.isMap(e)&&e.get("in")===t}))}function ae(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";if(f.List.isList(e))return e.some((function(e){return f.Map.isMap(e)&&e.get("type")===t}))}function ue(e,t){t=t||[];var n=w(e).getIn(["paths"].concat(s()(t)),Object(f.fromJS)({})),r=e.getIn(["meta","paths"].concat(s()(t)),Object(f.fromJS)({})),o=se(e,t),i=n.get("parameters")||new f.List,a=r.get("consumes_value")?r.get("consumes_value"):ae(i,"file")?"multipart/form-data":ae(i,"formData")?"application/x-www-form-urlencoded":void 0;return Object(f.fromJS)({requestContentType:a,responseContentType:o})}function se(e,t){t=t||[];var n=w(e).getIn(["paths"].concat(s()(t)),null);if(null!==n){var r=e.getIn(["meta","paths"].concat(s()(t),["produces_value"]),null),o=n.getIn(["produces",0],null);return r||o||"application/json"}}function ce(e,t){t=t||[];var n=w(e),r=n.getIn(["paths"].concat(s()(t)),null);if(null!==r){var o=t,i=a()(o,1)[0],u=r.get("produces",null),c=n.getIn(["paths",i,"produces"],null),l=n.getIn(["produces"],null);return u||c||l}}function le(e,t){t=t||[];var n=w(e),r=n.getIn(["paths"].concat(s()(t)),null);if(null!==r){var o=t,i=a()(o,1)[0],u=r.get("consumes",null),c=n.getIn(["paths",i,"consumes"],null),l=n.getIn(["consumes"],null);return u||c||l}}var fe=function(e,t,n){var r=e.get("url").match(/^([a-z][a-z0-9+\-.]*):/),i=o()(r)?r[1]:null;return e.getIn(["scheme",t,n])||e.getIn(["scheme","_defaultScheme"])||i||""},pe=function(e,t,n){return["http","https"].indexOf(fe(e,t,n))>-1},he=function(e,t){t=t||[];var n=e.getIn(["meta","paths"].concat(s()(t),["parameters"]),Object(f.fromJS)([])),r=!0;return n.forEach((function(e){var t=e.get("errors");t&&t.count()&&(r=!1)})),r};function de(e){return f.Map.isMap(e)?e:new f.Map}},function(e,t,n){"use strict";(function(t){ +/*! + * @description Recursive object extending + * @author Viacheslav Lotsmanov + * @license MIT + * + * The MIT License (MIT) + * + * Copyright (c) 2013-2018 Viacheslav Lotsmanov + * + * Permission is hereby granted, free of charge, to any person obtaining a copy of + * this software and associated documentation files (the "Software"), to deal in + * the Software without restriction, including without limitation the rights to + * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of + * the Software, and to permit persons to whom the Software is furnished to do so, + * subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS + * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR + * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER + * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + */ +function n(e){return e instanceof t||e instanceof Date||e instanceof RegExp}function r(e){if(e instanceof t){var n=t.alloc?t.alloc(e.length):new t(e.length);return e.copy(n),n}if(e instanceof Date)return new Date(e.getTime());if(e instanceof RegExp)return new RegExp(e);throw new Error("Unexpected situation")}function o(e){var t=[];return e.forEach((function(e,i){"object"==typeof e&&null!==e?Array.isArray(e)?t[i]=o(e):n(e)?t[i]=r(e):t[i]=a({},e):t[i]=e})),t}function i(e,t){return"__proto__"===t?void 0:e[t]}var a=e.exports=function(){if(arguments.length<1||"object"!=typeof arguments[0])return!1;if(arguments.length<2)return arguments[0];var e,t,u=arguments[0],s=Array.prototype.slice.call(arguments,1);return s.forEach((function(s){"object"!=typeof s||null===s||Array.isArray(s)||Object.keys(s).forEach((function(c){return t=i(u,c),(e=i(s,c))===u?void 0:"object"!=typeof e||null===e?void(u[c]=e):Array.isArray(e)?void(u[c]=o(e)):n(e)?void(u[c]=r(e)):"object"!=typeof t||null===t||Array.isArray(t)?void(u[c]=a({},e)):void(u[c]=a(t,e))}))})),u}}).call(this,n(79).Buffer)},function(e,t,n){"use strict";n.r(t),n.d(t,"SHOW_AUTH_POPUP",(function(){return d})),n.d(t,"AUTHORIZE",(function(){return v})),n.d(t,"LOGOUT",(function(){return m})),n.d(t,"PRE_AUTHORIZE_OAUTH2",(function(){return y})),n.d(t,"AUTHORIZE_OAUTH2",(function(){return g})),n.d(t,"VALIDATE",(function(){return b})),n.d(t,"CONFIGURE_AUTH",(function(){return _})),n.d(t,"showDefinitions",(function(){return x})),n.d(t,"authorize",(function(){return w})),n.d(t,"logout",(function(){return E})),n.d(t,"preAuthorizeImplicit",(function(){return C})),n.d(t,"authorizeOauth2",(function(){return S})),n.d(t,"authorizePassword",(function(){return A})),n.d(t,"authorizeApplication",(function(){return k})),n.d(t,"authorizeAccessCodeWithFormParams",(function(){return O})),n.d(t,"authorizeAccessCodeWithBasicAuthentication",(function(){return j})),n.d(t,"authorizeRequest",(function(){return T})),n.d(t,"configureAuth",(function(){return P}));var r=n(28),o=n.n(r),i=n(18),a=n.n(i),u=n(30),s=n.n(u),c=n(97),l=n.n(c),f=n(19),p=n.n(f),h=n(5),d="show_popup",v="authorize",m="logout",y="pre_authorize_oauth2",g="authorize_oauth2",b="validate",_="configure_auth";function x(e){return{type:d,payload:e}}function w(e){return{type:v,payload:e}}function E(e){return{type:m,payload:e}}var C=function(e){return function(t){var n=t.authActions,r=t.errActions,o=e.auth,i=e.token,a=e.isValid,u=o.schema,c=o.name,l=u.get("flow");delete p.a.swaggerUIRedirectOauth2,"accessCode"===l||a||r.newAuthErr({authId:c,source:"auth",level:"warning",message:"Authorization may be unsafe, passed state was changed in server Passed state wasn't returned from auth server"}),i.error?r.newAuthErr({authId:c,source:"auth",level:"error",message:s()(i)}):n.authorizeOauth2({auth:o,token:i})}};function S(e){return{type:g,payload:e}}var A=function(e){return function(t){var n=t.authActions,r=e.schema,o=e.name,i=e.username,u=e.password,s=e.passwordType,c=e.clientId,l=e.clientSecret,f={grant_type:"password",scope:e.scopes.join(" "),username:i,password:u},p={};switch(s){case"request-body":!function(e,t,n){t&&a()(e,{client_id:t});n&&a()(e,{client_secret:n})}(f,c,l);break;case"basic":p.Authorization="Basic "+Object(h.a)(c+":"+l);break;default:console.warn("Warning: invalid passwordType ".concat(s," was passed, not including client id and secret"))}return n.authorizeRequest({body:Object(h.b)(f),url:r.get("tokenUrl"),name:o,headers:p,query:{},auth:e})}};var k=function(e){return function(t){var n=t.authActions,r=e.schema,o=e.scopes,i=e.name,a=e.clientId,u=e.clientSecret,s={Authorization:"Basic "+Object(h.a)(a+":"+u)},c={grant_type:"client_credentials",scope:o.join(" ")};return n.authorizeRequest({body:Object(h.b)(c),name:i,url:r.get("tokenUrl"),auth:e,headers:s})}},O=function(e){var t=e.auth,n=e.redirectUrl;return function(e){var r=e.authActions,o=t.schema,i=t.name,a=t.clientId,u=t.clientSecret,s=t.codeVerifier,c={grant_type:"authorization_code",code:t.code,client_id:a,client_secret:u,redirect_uri:n,code_verifier:s};return r.authorizeRequest({body:Object(h.b)(c),name:i,url:o.get("tokenUrl"),auth:t})}},j=function(e){var t=e.auth,n=e.redirectUrl;return function(e){var r=e.authActions,o=t.schema,i=t.name,a=t.clientId,u=t.clientSecret,s={Authorization:"Basic "+Object(h.a)(a+":"+u)},c={grant_type:"authorization_code",code:t.code,client_id:a,redirect_uri:n};return r.authorizeRequest({body:Object(h.b)(c),name:i,url:o.get("tokenUrl"),auth:t,headers:s})}},T=function(e){return function(t){var n,r=t.fn,i=t.getConfigs,u=t.authActions,c=t.errActions,f=t.oas3Selectors,p=t.specSelectors,h=t.authSelectors,d=e.body,v=e.query,m=void 0===v?{}:v,y=e.headers,g=void 0===y?{}:y,b=e.name,_=e.url,x=e.auth,w=(h.getConfigs()||{}).additionalQueryStringParams;if(p.isOAS3()){var E=f.selectedServer();n=l()(_,f.serverEffectiveValue({server:E}),!0)}else n=l()(_,p.url(),!0);"object"===o()(w)&&(n.query=a()({},n.query,w));var C=n.toString(),S=a()({Accept:"application/json, text/plain, */*","Content-Type":"application/x-www-form-urlencoded","X-Requested-With":"XMLHttpRequest"},g);r.fetch({url:C,method:"post",headers:S,query:m,body:d,requestInterceptor:i().requestInterceptor,responseInterceptor:i().responseInterceptor}).then((function(e){var t=JSON.parse(e.data),n=t&&(t.error||""),r=t&&(t.parseError||"");e.ok?n||r?c.newAuthErr({authId:b,level:"error",source:"auth",message:s()(t)}):u.authorizeOauth2({auth:x,token:t}):c.newAuthErr({authId:b,level:"error",source:"auth",message:e.statusText})})).catch((function(e){var t=new Error(e).message;if(e.response&&e.response.data){var n=e.response.data;try{var r="string"==typeof n?JSON.parse(n):n;r.error&&(t+=", error: ".concat(r.error)),r.error_description&&(t+=", description: ".concat(r.error_description))}catch(e){}}c.newAuthErr({authId:b,level:"error",source:"auth",message:t})}))}};function P(e){return{type:_,payload:e}}},function(e,t){var n=e.exports={version:"2.6.11"};"number"==typeof __e&&(__e=n)},function(e,t){e.exports=function(e){if(null==e)throw TypeError("Can't call method on "+e);return e}},function(e,t,n){var r=n(133),o=Math.min;e.exports=function(e){return e>0?o(r(e),9007199254740991):0}},function(e,t,n){var r=n(50),o=n(137);e.exports=n(45)?function(e,t,n){return r.f(e,t,o(1,n))}:function(e,t,n){return e[t]=n,e}},function(e,t){e.exports=function(e){try{return!!e()}catch(e){return!0}}},function(e,t,n){"use strict";(function(e){ +/*! + * The buffer module from node.js, for the browser. + * + * @author Feross Aboukhadijeh + * @license MIT + */ +var r=n(564),o=n(565),i=n(357);function a(){return s.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function u(e,t){if(a()=a())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a().toString(16)+" bytes");return 0|e}function d(e,t){if(s.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var n=e.length;if(0===n)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return U(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return q(e).length;default:if(r)return U(e).length;t=(""+t).toLowerCase(),r=!0}}function v(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if((n>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return j(this,t,n);case"utf8":case"utf-8":return A(this,t,n);case"ascii":return k(this,t,n);case"latin1":case"binary":return O(this,t,n);case"base64":return S(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return T(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function m(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function y(e,t,n,r,o){if(0===e.length)return-1;if("string"==typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=o?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(o)return-1;n=e.length-1}else if(n<0){if(!o)return-1;n=0}if("string"==typeof t&&(t=s.from(t,r)),s.isBuffer(t))return 0===t.length?-1:g(e,t,n,r,o);if("number"==typeof t)return t&=255,s.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):g(e,[t],n,r,o);throw new TypeError("val must be string, number or Buffer")}function g(e,t,n,r,o){var i,a=1,u=e.length,s=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;a=2,u/=2,s/=2,n/=2}function c(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(o){var l=-1;for(i=n;iu&&(n=u-s),i=n;i>=0;i--){for(var f=!0,p=0;po&&(r=o):r=o;var i=t.length;if(i%2!=0)throw new TypeError("Invalid hex string");r>i/2&&(r=i/2);for(var a=0;a>8,o=n%256,i.push(o),i.push(r);return i}(t,e.length-n),e,n,r)}function S(e,t,n){return 0===t&&n===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,n))}function A(e,t,n){n=Math.min(e.length,n);for(var r=[],o=t;o239?4:c>223?3:c>191?2:1;if(o+f<=n)switch(f){case 1:c<128&&(l=c);break;case 2:128==(192&(i=e[o+1]))&&(s=(31&c)<<6|63&i)>127&&(l=s);break;case 3:i=e[o+1],a=e[o+2],128==(192&i)&&128==(192&a)&&(s=(15&c)<<12|(63&i)<<6|63&a)>2047&&(s<55296||s>57343)&&(l=s);break;case 4:i=e[o+1],a=e[o+2],u=e[o+3],128==(192&i)&&128==(192&a)&&128==(192&u)&&(s=(15&c)<<18|(63&i)<<12|(63&a)<<6|63&u)>65535&&s<1114112&&(l=s)}null===l?(l=65533,f=1):l>65535&&(l-=65536,r.push(l>>>10&1023|55296),l=56320|1023&l),r.push(l),o+=f}return function(e){var t=e.length;if(t<=4096)return String.fromCharCode.apply(String,e);var n="",r=0;for(;r0&&(e=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(e+=" ... ")),""},s.prototype.compare=function(e,t,n,r,o){if(!s.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===o&&(o=this.length),t<0||n>e.length||r<0||o>this.length)throw new RangeError("out of range index");if(r>=o&&t>=n)return 0;if(r>=o)return-1;if(t>=n)return 1;if(this===e)return 0;for(var i=(o>>>=0)-(r>>>=0),a=(n>>>=0)-(t>>>=0),u=Math.min(i,a),c=this.slice(r,o),l=e.slice(t,n),f=0;fo)&&(n=o),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var i=!1;;)switch(r){case"hex":return b(this,e,t,n);case"utf8":case"utf-8":return _(this,e,t,n);case"ascii":return x(this,e,t,n);case"latin1":case"binary":return w(this,e,t,n);case"base64":return E(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return C(this,e,t,n);default:if(i)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),i=!0}},s.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function k(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;or)&&(n=r);for(var o="",i=t;in)throw new RangeError("Trying to access beyond buffer length")}function I(e,t,n,r,o,i){if(!s.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>o||te.length)throw new RangeError("Index out of range")}function M(e,t,n,r){t<0&&(t=65535+t+1);for(var o=0,i=Math.min(e.length-n,2);o>>8*(r?o:1-o)}function D(e,t,n,r){t<0&&(t=4294967295+t+1);for(var o=0,i=Math.min(e.length-n,4);o>>8*(r?o:3-o)&255}function N(e,t,n,r,o,i){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function R(e,t,n,r,i){return i||N(e,0,n,4),o.write(e,t,n,r,23,4),n+4}function L(e,t,n,r,i){return i||N(e,0,n,8),o.write(e,t,n,r,52,8),n+8}s.prototype.slice=function(e,t){var n,r=this.length;if((e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t0&&(o*=256);)r+=this[e+--t]*o;return r},s.prototype.readUInt8=function(e,t){return t||P(e,1,this.length),this[e]},s.prototype.readUInt16LE=function(e,t){return t||P(e,2,this.length),this[e]|this[e+1]<<8},s.prototype.readUInt16BE=function(e,t){return t||P(e,2,this.length),this[e]<<8|this[e+1]},s.prototype.readUInt32LE=function(e,t){return t||P(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},s.prototype.readUInt32BE=function(e,t){return t||P(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},s.prototype.readIntLE=function(e,t,n){e|=0,t|=0,n||P(e,t,this.length);for(var r=this[e],o=1,i=0;++i=(o*=128)&&(r-=Math.pow(2,8*t)),r},s.prototype.readIntBE=function(e,t,n){e|=0,t|=0,n||P(e,t,this.length);for(var r=t,o=1,i=this[e+--r];r>0&&(o*=256);)i+=this[e+--r]*o;return i>=(o*=128)&&(i-=Math.pow(2,8*t)),i},s.prototype.readInt8=function(e,t){return t||P(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},s.prototype.readInt16LE=function(e,t){t||P(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},s.prototype.readInt16BE=function(e,t){t||P(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},s.prototype.readInt32LE=function(e,t){return t||P(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},s.prototype.readInt32BE=function(e,t){return t||P(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},s.prototype.readFloatLE=function(e,t){return t||P(e,4,this.length),o.read(this,e,!0,23,4)},s.prototype.readFloatBE=function(e,t){return t||P(e,4,this.length),o.read(this,e,!1,23,4)},s.prototype.readDoubleLE=function(e,t){return t||P(e,8,this.length),o.read(this,e,!0,52,8)},s.prototype.readDoubleBE=function(e,t){return t||P(e,8,this.length),o.read(this,e,!1,52,8)},s.prototype.writeUIntLE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||I(this,e,t,n,Math.pow(2,8*n)-1,0);var o=1,i=0;for(this[t]=255&e;++i=0&&(i*=256);)this[t+o]=e/i&255;return t+n},s.prototype.writeUInt8=function(e,t,n){return e=+e,t|=0,n||I(this,e,t,1,255,0),s.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},s.prototype.writeUInt16LE=function(e,t,n){return e=+e,t|=0,n||I(this,e,t,2,65535,0),s.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):M(this,e,t,!0),t+2},s.prototype.writeUInt16BE=function(e,t,n){return e=+e,t|=0,n||I(this,e,t,2,65535,0),s.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):M(this,e,t,!1),t+2},s.prototype.writeUInt32LE=function(e,t,n){return e=+e,t|=0,n||I(this,e,t,4,4294967295,0),s.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):D(this,e,t,!0),t+4},s.prototype.writeUInt32BE=function(e,t,n){return e=+e,t|=0,n||I(this,e,t,4,4294967295,0),s.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):D(this,e,t,!1),t+4},s.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);I(this,e,t,n,o-1,-o)}var i=0,a=1,u=0;for(this[t]=255&e;++i>0)-u&255;return t+n},s.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);I(this,e,t,n,o-1,-o)}var i=n-1,a=1,u=0;for(this[t+i]=255&e;--i>=0&&(a*=256);)e<0&&0===u&&0!==this[t+i+1]&&(u=1),this[t+i]=(e/a>>0)-u&255;return t+n},s.prototype.writeInt8=function(e,t,n){return e=+e,t|=0,n||I(this,e,t,1,127,-128),s.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},s.prototype.writeInt16LE=function(e,t,n){return e=+e,t|=0,n||I(this,e,t,2,32767,-32768),s.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):M(this,e,t,!0),t+2},s.prototype.writeInt16BE=function(e,t,n){return e=+e,t|=0,n||I(this,e,t,2,32767,-32768),s.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):M(this,e,t,!1),t+2},s.prototype.writeInt32LE=function(e,t,n){return e=+e,t|=0,n||I(this,e,t,4,2147483647,-2147483648),s.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):D(this,e,t,!0),t+4},s.prototype.writeInt32BE=function(e,t,n){return e=+e,t|=0,n||I(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),s.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):D(this,e,t,!1),t+4},s.prototype.writeFloatLE=function(e,t,n){return R(this,e,t,!0,n)},s.prototype.writeFloatBE=function(e,t,n){return R(this,e,t,!1,n)},s.prototype.writeDoubleLE=function(e,t,n){return L(this,e,t,!0,n)},s.prototype.writeDoubleBE=function(e,t,n){return L(this,e,t,!1,n)},s.prototype.copy=function(e,t,n,r){if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t=0;--o)e[o+t]=this[o+n];else if(i<1e3||!s.TYPED_ARRAY_SUPPORT)for(o=0;o>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"==typeof e)for(i=t;i55295&&n<57344){if(!o){if(n>56319){(t-=3)>-1&&i.push(239,191,189);continue}if(a+1===r){(t-=3)>-1&&i.push(239,191,189);continue}o=n;continue}if(n<56320){(t-=3)>-1&&i.push(239,191,189),o=n;continue}n=65536+(o-55296<<10|n-56320)}else o&&(t-=3)>-1&&i.push(239,191,189);if(o=null,n<128){if((t-=1)<0)break;i.push(n)}else if(n<2048){if((t-=2)<0)break;i.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;i.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;i.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return i}function q(e){return r.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(F,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function z(e,t,n,r){for(var o=0;o=t.length||o>=e.length);++o)t[o+n]=e[o];return o}}).call(this,n(39))},function(e,t,n){"use strict";e.exports=function(e){if("function"!=typeof e)throw new TypeError(e+" is not a function");return e}},function(e,t,n){e.exports=n(594)},function(e,t,n){"use strict";n.r(t),n.d(t,"UPDATE_LAYOUT",(function(){return o})),n.d(t,"UPDATE_FILTER",(function(){return i})),n.d(t,"UPDATE_MODE",(function(){return a})),n.d(t,"SHOW",(function(){return u})),n.d(t,"updateLayout",(function(){return s})),n.d(t,"updateFilter",(function(){return c})),n.d(t,"show",(function(){return l})),n.d(t,"changeMode",(function(){return f}));var r=n(5),o="layout_update_layout",i="layout_update_filter",a="layout_update_mode",u="layout_show";function s(e){return{type:o,payload:e}}function c(e){return{type:i,payload:e}}function l(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return e=Object(r.x)(e),{type:u,payload:{thing:e,shown:t}}}function f(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return e=Object(r.x)(e),{type:a,payload:{thing:e,mode:t}}}},function(e,t,n){var r=n(158),o=n(339);e.exports=n(132)?function(e,t,n){return r.f(e,t,o(1,n))}:function(e,t,n){return e[t]=n,e}},function(e,t,n){var r=n(214);e.exports=function(e){return Object(r(e))}},function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},function(e,t,n){var r=n(108),o=n(600),i=n(601),a=r?r.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":a&&a in Object(e)?o(e):i(e)}},function(e,t,n){var r=n(618),o=n(621);e.exports=function(e,t){var n=o(e,t);return r(n)?n:void 0}},function(e,t,n){var r=n(385),o=n(658),i=n(109);e.exports=function(e){return i(e)?r(e):o(e)}},function(e,t,n){"use strict";var r=n(182),o=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=f;var i=n(144);i.inherits=n(48);var a=n(395),u=n(245);i.inherits(f,a);for(var s=o(u.prototype),c=0;c=t.length?{value:void 0,done:!0}:(e=r(t,n),this._i+=e.length,{value:e,done:!1})}))},function(e,t){e.exports={}},function(e,t,n){n(557);for(var r=n(32),o=n(77),i=n(104),a=n(36)("toStringTag"),u="CSSRuleList,CSSStyleDeclaration,CSSValueList,ClientRectList,DOMRectList,DOMStringList,DOMTokenList,DataTransferItemList,FileList,HTMLAllCollection,HTMLCollection,HTMLFormElement,HTMLSelectElement,MediaList,MimeTypeArray,NamedNodeMap,NodeList,PaintRequestList,Plugin,PluginArray,SVGLengthList,SVGNumberList,SVGPathSegList,SVGPointList,SVGStringList,SVGTransformList,SourceBufferList,StyleSheetList,TextTrackCueList,TextTrackList,TouchList".split(","),s=0;s1){for(var d=Array(h),v=0;v1){for(var y=Array(m),g=0;g=this._finalSize&&(this._update(this._block),this._block.fill(0));var n=8*this._len;if(n<=4294967295)this._block.writeUInt32BE(n,this._blockSize-4);else{var r=(4294967295&n)>>>0,o=(n-r)/4294967296;this._block.writeUInt32BE(o,this._blockSize-8),this._block.writeUInt32BE(r,this._blockSize-4)}this._update(this._block);var i=this._hash();return e?i.toString(e):i},o.prototype._update=function(){throw new Error("_update must be implemented by subclass")},e.exports=o},function(e,t,n){var r=n(65),o=n(367),i=n(368),a=n(38),u=n(165),s=n(230),c={},l={};(t=e.exports=function(e,t,n,f,p){var h,d,v,m,y=p?function(){return e}:s(e),g=r(n,f,t?2:1),b=0;if("function"!=typeof y)throw TypeError(e+" is not iterable!");if(i(y)){for(h=u(e.length);h>b;b++)if((m=t?g(a(d=e[b])[0],d[1]):g(e[b]))===c||m===l)return m}else for(v=y.call(e);!(d=v.next()).done;)if((m=o(v,g,d.value,t))===c||m===l)return m}).BREAK=c,t.RETURN=l},function(e,t,n){"use strict";function r(e){return null==e}e.exports.isNothing=r,e.exports.isObject=function(e){return"object"==typeof e&&null!==e},e.exports.toArray=function(e){return Array.isArray(e)?e:r(e)?[]:[e]},e.exports.repeat=function(e,t){var n,r="";for(n=0;n1&&void 0!==arguments[1]?arguments[1]:{},r=Object(i.B)(t),a=r.type,u=r.example,s=r.properties,c=r.additionalProperties,l=r.items,f=n.includeReadOnly,p=n.includeWriteOnly;if(void 0!==u)return Object(i.e)(u,"$$ref",(function(e){return"string"==typeof e&&e.indexOf("#")>-1}));if(!a)if(s)a="object";else{if(!l)return;a="array"}if("object"===a){var d=Object(i.B)(s),v={};for(var m in d)d[m]&&d[m].deprecated||d[m]&&d[m].readOnly&&!f||d[m]&&d[m].writeOnly&&!p||(v[m]=e(d[m],n));if(!0===c)v.additionalProp1={};else if(c)for(var y=Object(i.B)(c),g=e(y,n),b=1;b<4;b++)v["additionalProp"+b]=g;return v}return"array"===a?o()(l.anyOf)?l.anyOf.map((function(t){return e(t,n)})):o()(l.oneOf)?l.oneOf.map((function(t){return e(t,n)})):[e(l,n)]:t.enum?t.default?t.default:Object(i.x)(t.enum)[0]:"file"!==a?h(t):void 0},v=function(e){return e.schema&&(e=e.schema),e.properties&&(e.type="object"),e},m=function e(t){var n,r,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},u=f()({},Object(i.B)(t)),s=u.type,c=u.properties,l=u.additionalProperties,p=u.items,d=u.example,v=a.includeReadOnly,m=a.includeWriteOnly,y=u.default,g={},b={},_=t.xml,x=_.name,w=_.prefix,E=_.namespace,C=u.enum;if(!s)if(c||l)s="object";else{if(!p)return;s="array"}if(n=(w?w+":":"")+(x=x||"notagname"),E){var S=w?"xmlns:"+w:"xmlns";b[S]=E}if("array"===s&&p){if(p.xml=p.xml||_||{},p.xml.name=p.xml.name||_.name,_.wrapped)return g[n]=[],o()(d)?d.forEach((function(t){p.example=t,g[n].push(e(p,a))})):o()(y)?y.forEach((function(t){p.default=t,g[n].push(e(p,a))})):g[n]=[e(p,a)],b&&g[n].push({_attr:b}),g;var A=[];return o()(d)?(d.forEach((function(t){p.example=t,A.push(e(p,a))})),A):o()(y)?(y.forEach((function(t){p.default=t,A.push(e(p,a))})),A):e(p,a)}if("object"===s){var k=Object(i.B)(c);for(var O in g[n]=[],d=d||{},k)if(k.hasOwnProperty(O)&&(!k[O].readOnly||v)&&(!k[O].writeOnly||m))if(k[O].xml=k[O].xml||{},k[O].xml.attribute){var j=o()(k[O].enum)&&k[O].enum[0],T=k[O].example,P=k[O].default;b[k[O].xml.name||O]=void 0!==T&&T||void 0!==d[O]&&d[O]||void 0!==P&&P||j||h(k[O])}else{k[O].xml.name=k[O].xml.name||O,void 0===k[O].example&&void 0!==d[O]&&(k[O].example=d[O]);var I=e(k[O]);o()(I)?g[n]=g[n].concat(I):g[n].push(I)}return!0===l?g[n].push({additionalProp:"Anything can be here"}):l&&g[n].push({additionalProp:h(l)}),b&&g[n].push({_attr:b}),g}return r=void 0!==d?d:void 0!==y?y:o()(C)?C[0]:h(t),g[n]=b?[{_attr:b},r]:r,g};function y(e,t){var n=m(e,t);if(n)return u()(n,{declaration:!0,indent:"\t"})}var g=c()(y),b=c()(d)},function(e,t,n){"use strict";n.r(t),n.d(t,"UPDATE_CONFIGS",(function(){return i})),n.d(t,"TOGGLE_CONFIGS",(function(){return a})),n.d(t,"update",(function(){return u})),n.d(t,"toggle",(function(){return s})),n.d(t,"loaded",(function(){return c}));var r=n(3),o=n.n(r),i="configs_update",a="configs_toggle";function u(e,t){return{type:i,payload:o()({},e,t)}}function s(e){return{type:a,payload:e}}var c=function(){return function(){}}},function(e,t,n){"use strict";n.d(t,"a",(function(){return a}));var r=n(2),o=n.n(r),i=o.a.Set.of("type","format","items","default","maximum","exclusiveMaximum","minimum","exclusiveMinimum","maxLength","minLength","pattern","maxItems","minItems","uniqueItems","enum","multipleOf");function a(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.isOAS3;if(!o.a.Map.isMap(e))return{schema:o.a.Map(),parameterContentMediaType:null};if(!n)return"body"===e.get("in")?{schema:e.get("schema",o.a.Map()),parameterContentMediaType:null}:{schema:e.filter((function(e,t){return i.includes(t)})),parameterContentMediaType:null};if(e.get("content")){var r=e.get("content",o.a.Map({})).keySeq(),a=r.first();return{schema:e.getIn(["content",a,"schema"],o.a.Map()),parameterContentMediaType:a}}return{schema:e.get("schema",o.a.Map()),parameterContentMediaType:null}}},function(e,t,n){e.exports=n(774)},function(e,t,n){"use strict";n.r(t),n.d(t,"createStore",(function(){return S})),n.d(t,"combineReducers",(function(){return k})),n.d(t,"bindActionCreators",(function(){return j})),n.d(t,"applyMiddleware",(function(){return I})),n.d(t,"compose",(function(){return T}));var r=n(465),o="object"==typeof self&&self&&self.Object===Object&&self,i=(r.a||o||Function("return this")()).Symbol,a=Object.prototype,u=a.hasOwnProperty,s=a.toString,c=i?i.toStringTag:void 0;var l=function(e){var t=u.call(e,c),n=e[c];try{e[c]=void 0;var r=!0}catch(e){}var o=s.call(e);return r&&(t?e[c]=n:delete e[c]),o},f=Object.prototype.toString;var p=function(e){return f.call(e)},h=i?i.toStringTag:void 0;var d=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":h&&h in Object(e)?l(e):p(e)};var v=function(e,t){return function(n){return e(t(n))}}(Object.getPrototypeOf,Object);var m=function(e){return null!=e&&"object"==typeof e},y=Function.prototype,g=Object.prototype,b=y.toString,_=g.hasOwnProperty,x=b.call(Object);var w=function(e){if(!m(e)||"[object Object]"!=d(e))return!1;var t=v(e);if(null===t)return!0;var n=_.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&b.call(n)==x},E=n(333),C="@@redux/INIT";function S(e,t,n){var r;if("function"==typeof t&&void 0===n&&(n=t,t=void 0),void 0!==n){if("function"!=typeof n)throw new Error("Expected the enhancer to be a function.");return n(S)(e,t)}if("function"!=typeof e)throw new Error("Expected the reducer to be a function.");var o=e,i=t,a=[],u=a,s=!1;function c(){u===a&&(u=a.slice())}function l(){return i}function f(e){if("function"!=typeof e)throw new Error("Expected listener to be a function.");var t=!0;return c(),u.push(e),function(){if(t){t=!1,c();var n=u.indexOf(e);u.splice(n,1)}}}function p(e){if(!w(e))throw new Error("Actions must be plain objects. Use custom middleware for async actions.");if(void 0===e.type)throw new Error('Actions may not have an undefined "type" property. Have you misspelled a constant?');if(s)throw new Error("Reducers may not dispatch actions.");try{s=!0,i=o(i,e)}finally{s=!1}for(var t=a=u,n=0;n0&&void 0!==arguments[0]?arguments[0]:{},t=arguments[1];if(a)throw a;for(var r=!1,o={},u=0;u0?r:n)(e)}},function(e,t){e.exports={}},function(e,t){var n={}.toString;e.exports=function(e){return n.call(e).slice(8,-1)}},function(e,t){e.exports=!0},function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},function(e,t,n){var r=n(38),o=n(353),i=n(219),a=n(217)("IE_PROTO"),u=function(){},s=function(){var e,t=n(221)("iframe"),r=i.length;for(t.style.display="none",n(354).appendChild(t),t.src="javascript:",(e=t.contentWindow.document).open(),e.write("