AAEmu 1.2 (Rust) is an open source server emulator for ArcheAge 1.2 (client r208022),
written in Rust.
It is a spin-off of AAEmu, which is written in C# and covers many client versions. Here the login server, game server and tools were ported to Rust for the 1.2 client only. The C# code is no longer in the tree, but it remains in the git history.
- What you need
- Quick start (Docker)
- Setup without Docker
- Starting the game client
- Configuration
- Development
- Repository layout
- Help and contributing
- License
| Notes | |
|---|---|
| Rust (stable) | Install with rustup. No .NET SDK is needed. |
| MySQL 8 | Docker runs it for you, or use one installed locally. |
| ArcheAge 1.2 client | The game_pak and bin32/archeage.exe. Not distributed here. |
compact.sqlite3 |
The 1.2 game database. Not distributed here. |
To get the client and the database, see Dependencies and Downloads.
This path needs Docker. MySQL runs in a container, and the login and game servers run on your machine.
-
Clone the repository:
git clone https://github.com/AAEmu/AAEmu-1.2-Rust.git cd AAEmu-1.2-Rust -
Add the game data:
- Copy
compact.sqlite3torust/crates/aaemu-game/app/Data/. - Copy the client
game_paktorust/crates/aaemu-game/app/ClientData/. Alternatively, list its path inrust/crates/aaemu-game/app/Configurations/ClientData.json.
- Copy
-
Start everything:
cd rust cargo xtask dev --releaseThis creates
.envfrom.env.example, starts MySQL, then starts the login server, then the game server. -
Start the client. See Starting the game client.
-
Create the databases by importing
SQL/aaemu_login.sqlandSQL/aaemu_game.sqlinto MySQL. -
Add the game data, as in step 2 of the Docker quick start.
-
Set the MySQL credentials for both servers. Put them in a
Config.Local.jsonnext to eachConfig.json(see Configuration). -
Start the login server first, then the game server in a second terminal:
cd rust cargo run --release -p aaemu-login cargo run --release -p aaemu-gameThe scripts
Scripts/start_login.sh/start_game.sh(Linux/macOS) andScripts/start AAEmu.Login.bat/start AAEmu.Game.bat(Windows) do the same.
The servers apply the database updates in SQL/updates/ at startup when
Connections:AutoApplyUpdates is true.
To run the whole stack in containers instead, docker-compose.yaml runs MySQL, Adminer
(http://localhost:8080), login and game. Copy .env.example to .env, run
Scripts/docker-install-local.sh (or .ps1), then docker compose up -d. See the
Docker Installation Guide.
| Port | Server | Used by |
|---|---|---|
| 1237 | login | clients |
| 1234 | login | game server registration (listens on loopback by default) |
| 1239 | game | clients |
| 1250 | game | stream channel (UCC, emblems) |
| 1280 | game | optional web API |
To check that the stack is up:
- The login server listens on 1237.
- The game server listens on 1239 and 1250.
- The login log shows
Registered GameServer.
The repository includes its own launcher, so no third-party launcher is needed. It starts the 1.2 client and hands it the login ticket:
cd rust
cargo run --release -p aaemu-launcher -- --client "C:\ArcheAge\bin32\archeage.exe" --login 127.0.0.1:1237 --user myname- Password: the launcher asks for it, or takes
--password,--password-fileor$AAEMU_PASSWORD. - Accounts: when
AutoAccountis enabled, the login server creates the account on the first login. - Options:
--langselects the client locale (defaulten_us).--helplists the rest.
Each server reads its files from its application directory:
| Server | Directory | Contents |
|---|---|---|
| Login | rust/crates/aaemu-login/app/ |
Config.json, ExampleConfig.Local.json |
| Game | rust/crates/aaemu-game/app/ |
Config.json, Configurations/*.json, Data/, ClientData/, Scripts/Commands/kits.json |
- Local overrides (database password, hosts and so on) go in a
Config.Local.jsonnext toConfig.json. This file is gitignored. Start fromExampleConfig.Local.json. - Environment variables and arguments override the files. Environment variables use the form
Connections__MySQLProvider__Password=..., command-line arguments the form--Section:Key=value. SecretKeymust be the same on the login and game servers.InternalNetwork.Hostmust be set to"*"or an IP address in the loginConfig.Local.jsonif the game server runs on another host.AAEMU_APP_PATHselects another application directory. The game server also accepts the directory as its first argument.- Logging goes to stdout and is controlled by
RUST_LOG(defaultinfo).
For more detail, see:
cd rust
cargo build --release # build everything
cargo test --workspace # unit and integration tests
cargo xtask ci # fmt --check, clippy -D warnings, tests: exactly what CI runs
cargo xtask publish --archive # self-contained server folders in publish/- Publishing:
cargo xtask publishcreatespublish/aaemu-<version>-<target>/, containingAAEmu.Login/,AAEmu.Game/,Tools/andSQL/. Start the binaries from their folders. - Live testing:
rust/LIVE-TESTING.mdcovers running the servers against real data with the headlessaaemu-testclientbot (smoke, parity and load tests). - Before changing game code, read
rust/crates/aaemu-game/CONTRIBUTING-PORT.md(layout, locking rules, packet conventions). - Differences from the C# server are recorded in
PORTING.md.
| Path | Contents |
|---|---|
rust/ |
Cargo workspace. Its crates: aaemu-login, aaemu-game, the shared aaemu-commons, aaemu-physics, aaemu-launcher, aaemu-testclient, the tools and xtask. |
SQL/ |
Base MySQL schemas and the incremental updates in SQL/updates/. |
Docs/ |
Documentation. Docs/wiki/ is the user guide. |
Scripts/ |
Start, publish and Docker helper scripts. |
docker/, docker-compose.yaml |
Container images and the Compose stack. |
- Documentation: Docs/wiki, including the FAQ and the mini troubleshooting guide.
- Questions: the community Discord. Please don't use the issue tracker for support requests.
- Contributing: contributions are welcome. Read the Contributing Guidelines before you open a pull request or an issue.
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
AAEmu is not affiliated with XLGames. All brands and trademarks belong to their respective owners. AAEmu is not XLGames-approved software, nor is it associated with XLGames.
