building_game_data - ryzom/ryzomcore GitHub Wiki


title: Building Game Data description: published: true date: 2023-03-01T04:56:35.069Z tags: editor: markdown dateCreated: 2019-11-24T12:08:54.302Z

This document is outdated. The gamedata build scripts configuration is now automatically handled by the quick start scripts. {.is-danger}

Introduction

This manual covers the game data build pipeline. It covers setting up build environment, using the build scripts, and further documents all details of the entire pipeline configuration.

Overview

gamedata_overview.png

Prerequirements

Before proceeding, the following steps must have already been taken:

  • Compiled server binaries (Linux)
  • Compiled tools (Win32)
  • Compiled client (Win32) The gamedata build box will be assumed to be a Windows 7 or Windows 10 machine. No official support is currently provided for running the build pipeline under Linux.

Build Environment

Install required software

The build pipeline requires Python 2.7 to be installed on the build machine. You will also need Mercurial to be installed. Additionally, if you are planning to work with 3ds Max, a licensed copy of 3ds Max needs to be available on the build machine.

Prepare data directories

On the game data build machine we require a copy of the code repository, the leveldesign repository, and the assets. We also need access to the compiled tools for the local platform, compiled client binaries for the different supported architectures, and the server binaries compiled for Linux.

Code repository

If you already have the code respository available, you may skip this step.

  • Create a directory called 'ryzomcore' for the code repository
  • Open the directory
  • Right click > TortoiseHg > Clone
  • Source: https://bitbucket.org/ryzom/ryzomcore
  • Options: Check "Do not update the new working directory"
  • Click Ok and wait for the download process to finish
  • Open the '.hg' directory (It may be hidden)
  • Edit 'hgrc' with a basic text editor like notepad
  • Add the following lines to the end of the file and save:
[extensions]
eol =
mq =
  • Go back to the directory where you cloned the repository.
  • Right click > TortoiseHg > Update
  • Click update

Leveldesign repository

  • Create a directory called 'ryzomcore-data' for the leveldesign repository
  • Open the directory
  • Right click > TortoiseHg > Clone
  • Source: https://bitbucket.org/ryzom/ryzomcore-data
  • Click Ok and wait for the download process to finish

Assets

Link directories

For convenience, we will create virtual path names for our directories, which are the same on all machines. This is necessary, as there currently are a number of files which depend on absolute paths.

  • Create a batch file called init_ryzomcore.bat and open it in a basic text editor like notepad
  • Enter the following text, modify the paths to link to your local directories, and save
subst R: /D
subst R: S:\ryzomcore
subst L: /D
subst L: S:\ryzomcore-data
subst W: /D
subst W: S:\ryzomcore-assets
subst T: /D
subst T: S:\ryzomcore-build
  • Run the batch file you just created, this will create virtual R:, L:, W: and T: drives (which will disappear on reboot).

Pipeline setup

Configure the build site

Open a terminal window and browse to

R:
cd R:/code/nel/tools/build_gamedata

Run

0_setup.py
  • Build Quality: Can be 0 or 1, should be 1
  • Primary Tool Directory: Directory containing the compiled Ryzom Core tools
  • Secondary Tool Directory: Directory containing external tools, such as xdelta and lzma
  • Tool Suffix: Executable suffix of tools, should be '.exe' on Windows, type '--' on Linux to make this parameter blank
  • Script Directory: Directory containing the build gamedata scripts, current directory
  • Workspace Directory: Directory containing the pipeline configuration
  • Database Directory: Directory containing assets
  • Export Build Directory: Intermediate build output directory
  • Install Directory: Intermediate packaging directory
  • Client Dev Directory: Output directory for developer client
  • Client Patch Directory: Output directory for client patches
  • Client Install Directory: Output directory for end user client
  • Shard Install Directory: Intermediate shard packaging directory
  • World Edit Install Directory: Output directory for landscape data used in world editor tool
  • Leveldesign Directory: Directory containing georges sheets
  • Leveldesign DFN Directory: Directory containing georges sheet definitions
  • Leveldesign World Directory: Directory containing world description sheets
  • Primitives Directory: Directory containing AI primitives
  • Gamedev Directory: Directory containing developer files
  • Data Shard Directory: Directory containing developer files for shard
  • Data Common Directory: Directory containing common developer files
  • Translation Directory: Directory containing translation files
  • Leveldesign Data Shard Directory: Directory containing data files for shard
  • Leveldesign Data Common Directory: Directory containing common data files
  • World Editor Files Directory: Directory containing developer files for world editortool
  • Primary Windows exe/dll/cfg Directory: Redistributable STL if necessary
  • Secondary Windows exe/dll/cfg Directory: External libraries
  • Tertiary Windows exe/dll/cfg Directory: Windows client binaries
  • Quaternary Windows exe/dll/cfg Directory: Client configuration
  • Quinary Windows exe/dll/cfg Directory: No longer used
  • Senary Windows exe/dll/cfg Directory: No longer used
  • Septenary Windows exe/dll/cfg Directory: Client configuration
  • Linux Service Executable Directory: Directory containing Ryzom Core server binaries for Linux
  • Linux Client Executable Directory: Directory containing Ryzom Core client binaries for Linux
  • Patchman Cfg Admin Directory: Directory containing redistributable patchman scripts
  • Patchman Cfg Default Directory: Directory containing default service configuration files
  • 3dsMax Available: Can be 0 or 1
  • 3dsMax Directory: Path to 3ds Max installation
  • 3dsMax User Directory: Writable 3ds Max user directory
  • 3dsMax Executable: Executable for 3ds Max The configuration is stored under 'configuration/buildsite.py'. To run the script a second time without being asked for settings, the option '--noconf' can be used.

Using the pipeline

To build the game data, we have three main scripts which need to be executed:

  • 1_export.py: Exports assets to formats usable by the NeL engine
  • 2_build.py: Builds the exported assets, this includes for example the lighting ofthe landscape.
  • 3_install.py: Prepares the exported assets into separated packages.

Several options can be used with these scripts:

  • -ipj: Include project
  • -epj: Exclude project
  • -ipc: Include process
  • -epc: Exclude process

For development, there are a further number of scripts:

  • a1_worldedit_data.py: Sets up the landscape data in the world edit output directory for use with the world editor tools
  • b1_client_dev.py: Sets up and configures a developer client
  • b2_shard_data.py: Creates the data packages for the shard

A number of convenience pipeline scripts have been created, which execute the appropriate scripts with set options:

  • all_dev.bat: Used when adding new assets, runs the entire build pipeline
  • executables_dev.bat: Update only executables
  • interface_dev.bat: For changes to the graphic interface xml files
  • leveldesign_dev.bat: Rebuild leveldesign

The 'c' and 'd' scripts are disregarded in this manual. They are covered by the shard deployment manual. From the build_gamedata directory, after first setup you should simply run:

all_dev.bat

Workspace configuration

To be continued

⚠️ **GitHub.com Fallback** ⚠️