Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Build from source

Build using Go

To build the server from source, you will need Go 1.25 or newer:

make
# or
go build -o ./build/server ./cmd/server/main.go

To build and run with a single command:

make run
# or
go run ./cmd/server/main.go

You can choose between SQLite drivers by setting the CGO_ENABLED environment variable:

  • Build with CGO_ENABLED=0 to use modernc.org/sqlite driver (default);
  • Build with CGO_ENABLED=1 to use github.com/mattn/go-sqlite3 driver;

Folder structure

amazing-core/
├── cmd/
│   └── server/
│       └── main.go           - server entry point
├── data/
│   ├── cache.json            - asset metadata generated by cache-tool
│   └── sql/
│       ├── core_db/
│       │   ├── base.sql      - core.db base migration
│       │   └── updates/      - incremental migrations
│       ├── blob_db/
│       │   └── base.sql      - blob.db schema
│       └── queries/          - sql queries for admin dashboard explorer
├── internal/
│   ├── api/                  - http server for admin dashboard and asset streaming
│   ├── game/                 - game server and gsf messages handling
│   ├── network/              - tcp server protocol implementation
│   ├── services/             - business logic and database interaction
│   ├── config/               - configuration variables
│   └── lib/                  - shared libraries (e.g. logging, helpers)
├── tools/                    - development tools (e.g. asset importers)
└── web/                      - embedded frontend for admin dashboard