The main repository for the Darkflame Universe Server Emulator project.
The main repository for the Darkflame Universe Server Emulator project.
Darkflame Universe (DLU) is a server emulator for LEGO® Universe. Development started in 2013 and has gone through multiple iterations and is now able to present a near perfect emulation of the game server.
Developed by NetDevil and The LEGO Group, LEGO® Universe launched in October 2010 and ceased operation in January 2012.
Darkflame Universe is licensed under AGPLv3, please read LICENSE. Some important points:
We do not recommend hosting public servers. Darkflame Universe is intended for small scale deployment, for example within a group of friends. It has not been tested for large scale deployment which comes with additional security risks.
Darkflame Universe is a server emulator and does not distribute any LEGO® Universe files. A separate game client is required to setup this server emulator and play the game, which we cannot supply. Users are strongly suggested to refer to the safe checksums listed here to see if a client will work.
legouniverse.exe, the file MasterServer.exe is in there.legouniverse.exe.sharedconfig.ini. Find the line that says client_location and put .. after it so the line reads client_location=...MasterServer.exe.boot.cfg which is found in your LEGO Universe client, rename the file boot.cfg to something else or follow the steps here if you wish to keep the file.MasterServer.exe window and hold ctrl while pressing c to stop the server.AuthServer, ChatServer, MasterServer, WorldServer and libmariadbcpp.dylib to run. The initial pop-up will block it due to the binaries being unsigned, after allowing them to run the servers will run as normal.If you are not planning on hosting a server for others, working in the codebase or wanting to use MariaDB for a database, you can stop reading here.
If you would like to use a MariaDB as a database instead of the default of sqlite, follow the steps here.
Throughout the entire build and setup process a level of familiarity with the command line and preferably a Unix-like development environment is greatly advantageous.
If you would like a setup for a single player server only on a Windows machine built from source, use the Native Windows Setup Guide by HailStorm and skip this README.
If you are on Windows, you will need to download and install git from here
Then run the following command
git clone --recursive https://github.com/DarkflameUniverse/DarkflameServerEnsure that you have either the MSVC C++ compiler (recommended) or the Clang compiler installed. You'll also need to download and install CMake (version 3.25 up to version 3.31!).
Ensure you have brew installed. You will need to install the following packages
brew install cmake gcc mariadb openssl zlibMake sure packages like gcc, and zlib are installed. Depending on the distribution, these packages might already be installed. Note that on systems like Ubuntu, you will need the zlib1g-dev package so that the header files are available. libssl-dev will also be required as well as openssl. You will also need a MySQL database solution to use. We recommend using mariadb-server.
For Ubuntu, you would run the following commands. On other systems, the package install command will differ.
sudo apt update && sudo apt upgrade
# Install packages
sudo apt install build-essential gcc zlib1g-dev libssl-dev openssl mariadb-server cmakeThis project uses CMake version 3.25 up to version 3.31 and as such you will need to ensure you have this version installed. You can check your CMake version by using the following command in a terminal.
cmake --versionIf you are going to be using an Ubuntu environment to run the server, you may need to get a more recent version of cmake than the packages available may provide.
The general approach to do so would be to obtain a copy of the signing key and then add the CMake repository to your apt. You can do so with the following commands.
…First you'll need to start MariaDB.
For Windows the service is always running by default.
For MacOS, run the following command
brew services start mariadbFor Linux, run the following command
sudo systemctl start mysql
# If systemctl is not a known command on your distribution, try the following instead
sudo service mysql startYou will need to run this command every time you restart your environment
If you are using Linux and systemctl and want the MariaDB instance to start on startup, run the following command
sudo systemctl enable --now mysqlOnce MariaDB is started, you'll need to create a user and an empty database for Darkflame Universe to use.
First, login to the MariaDB instance.
To do this on Ubuntu/Linux, MacOS, or another Unix like operating system, run the following command in a terminal
# Logs you into the MariaDB instance as root
sudo mysqlFor Windows, run the following command in the Command Prompt (MariaDB xx.xx) terminal
# Logs you into the mysql instance
mysql -u root -p
# You will then be prompted for the password you set for root during installation of MariaDBNow that you are logged in, run the following commands.
# Creates a user for this computer which uses a password and grant said user all privileges.
# Change mydarkflameuser to a custom username and password to a custom password.
CREATE USER 'mydarkflameuser'@'localhost' IDENTIFIED BY 'password';
GRANT ALL ON *.* TO 'mydarkflameuser'@'localhost' WITH GRANT OPTION;
FLUSH PRIVILEGES;
# Then create a database for Darkflame Universe to use.
CREATE DATABASE darkflame;You can either run build.sh when in the root folder of the repository:
./build.shOr manually run the commands used in build.sh.
If you would like to build the server faster, append -j where number is the number of simultaneous compile jobs to run at once. It is recommended that you have this number always be 1 less than your core count to prevent slowdowns. The command would look like this if you would build with 4 jobs at once:
./build.sh -j4Depending on your operating system, you may need to adjust some pre-processor defines in CMakeVariables.txt before building:
client_net_version in build/sharedconfig.ini is changed to 171023.This server has a few steps that need to be taken to configure the server for your use case.
Darkflame Universe can run with either a packed or an unpacked client.
Navigate to build/sharedconfig.ini and fill in the following fields:
mysql_host (This is the IP address or hostname of your MariaDB server. This is highly likely localhost)tcp://localhost:portNum where portNum is replaced with the port you chose to run MariaDB on.mysql_database (This is the database you created for the server)mysql_username (This is the user you created for the server)mysql_password (This is the password for the user you created for the server)client_location (This is the location of the client files. This should be the folder path of a packed or unpacked client)ini files in the build directory: sharedconfig.ini, authconfig.ini, chatconfig.ini, masterconfig.ini, and worldconfig.ini.authconfig.ini contains an option to enable or disable play keys on your server. Do not change the default port for auth.chatconfig.ini contains a port option.masterconfig.ini contains options related to permissions you want to run your servers with.sharedconfig.ini contains several options that are shared across all serversworldconfig.ini contains several options to turn on Quality of Life improvements should you want them. If you would like the most vanilla experience possible, you will need to turn some of these settings off.Your build directory should contain at a minimum all of the following files.
All listed files are required for a server to start.
ini files can be located at the environment variable DLU_CONFIG_DIR and do not need to be located in this directory.
No open issues yet, or sync has not completed.