Tutorials/Getting started with NetRadiant

From Unvanquished
Jump to: navigation, search

Requirements

You will need:

Note that if you go the developer way with assets repositories you may need other tools, to be documented later. There is no need for those extra tools if you go the developer way using asset repository snapshots.

NetRadiant Installation

Information 48x48.png

Note

This is currently outdated, the only way to currently install NetRadiant is to build it from repository.

Follow the instructions on Ingar's Installation Guide. Mac and Linux users will have to use the terminal.

Information 48x48.png

Note

Arch Linux users can use the netradiant-git PKGBUILD to get the game and the netradiant-unvanquished for the gamepack.

Start up NetRadiant for the first time and configure it

When you first start up NetRadiant you will be asked what game you want to map for.

  • If Unvanquished is not listed, then you are running an older or unsupported version that does not ship the gamepack. If you can't update, you may find help from other people of the community on forums or via chat (IRC or Discord).
  • If you don't want to see this dialog on startup you can disable it with the second checkbox.

Netrad global prefs.png

You may also be asked for the game's engine path if NetRadiant can't find it. This is the location where the game stores its main folder holding the many .dpk resources.

There is two ways to work with files, the lazy way which is also the quick & dirty one, and the developer way which requires some extra steps but ensures a clean mapping environment that is not polluted by files randomly downloaded from servers. So you can expect this configuration window to pop-up the first time you run NetRadiant:

Netrad engine not found.png

The lazy way

To configure NetRadiant the lazy way use the installation directory and the user directory. This enables quickly a working setup that does not require extra knowledge. To do that, just set the engine path (which is the installation directory) and store your own maps in the user directory (NetRadiant already knows where it is). This ensures seamless integration with the game and requires less knowledge.

Netradiant-engine-path-lazy-setup.png

These are the default locations, you only need to know the installation path (Default Data Directory) since NetRadiant will find the Default User Directory itself:

Platform Variant Default Binary Directory (fs_libpath) Default Data Directory (fs_basepath) Default User Directory (fs_homepath) Notes
Windows 32 bit C:\Program Files\Unvanquished My Documents\My Games\Unvanquished The actual directories depends on where the game was installed.
64 bit C:\Program Files (x86)\Unvanquished
Mac Installed with updater Unvanquished/Unvanquished.app/Contents/MacOS Unvanquished/ ~/Library/Application Support/Unvanquished The data directory is the directory containing Unvanquished.app.
Linux Installed with updater ~/.local/share/unvanquished/base ~/.local/share/unvanquished The default user directory is an XDG Base Directory.
Installed from distribution repository /usr/lib/unvanquished /usr/share/unvanquished


The developer way

To configure NetRadiant the developer way either clone the assets repositories (you'll need git to clone it and Urcheon to prepare it) or download a snapshot, you will end with a directory named UnvanquishedAssets containing a src directory full of dpkdir directories. Set the full path to UnvanquishedAssets/src as PakPath 0. Create another directory for your own work, for example MyAssets and create a src directory in it. Set the full path to MyAssets/src as PakPath 1. Activate Do not use Engine Path and Do not use Home Path to be sure NetRadiant will only look for files in PakPaths.

The layout will looks like this:

Mapping
  └── Unvanquished
      ├── UnvanquishedAssets
      │   └── src
      │       └── (a long list of .dpkdir directories)
      └── MyAssets
          └── src

You can customize this file layout but thanks to experience this one is known to work well especially if you plan to contribute to official assets while you make custom ones and also map for other games.

Netradiant-engine-path-developer-setup.png

You can edit those paths in configuration window later:

Netradiant-engine-path-further-edit.png

Last minute tweaking and checking

Finally you should be greeted by the default interface of NetRadiant:

Netrad default.png

You may configure NetRadiant to only display shaders since any Unvanquished texture is distributed with a shader, this way you'll be sure to hide some files you don't need to see and would not want to mistakenly apply on surfaces (normal maps, stuff like that):

Netradiant-shaders-only.png

Make sure you have a common shader category. If you do not, get help on forums or via chat (IRC or Discord).

Netrad common.png

First steps with your map

Save your map before doing anything else

Before doing anything, save your map right after NetRadiant started! Don't worry if it's empty!

In all case you need to create a dpkdir for your map. If your map is named castle, you'll have to create a map-castle_<version>.dpkdir directory with a maps directory in. Notice the map- prefix, the _<version> suffix and the .dpkdir extension.

For the version string of your dpkdir, it's recommended to use src as a convention for source directories since it's recommended to use number based version for released dpk (like map-castle_1.4.dpk) and to use a greater version for source dpkdir to ensure the level editor or the game will not load outdated assets while editing, compiling or testing. The src version number is greater than any number-based version string like 1.4 or 2.5-christmas-edition, hence it's a good convention to use it for sources.

The basename of your dpkdir and the basename of your map must be the same. So you have to store castle.map in map-castle_src.dpkdir/maps for example.

If you've set-up NetRadiant the lazy way, create the dpkdir (in our example: map-castle_src.dpkdir) in the pkg directory of the user game directory:

Netradiant-save-map-lazy-way.png

If you've set-up NetRadiant the developer way, create the dpkdir in the src directory of your own asset directory (MyAssets in our example):

Netradiant-save-map-developer-way.png

Information 48x48.png

Note

If you go the developer way, you'll have to call q3map2 this way:

q3map2 -game unvanquished -fs_nobasepath -fs_nohomepath -fs_pakpath UnvanquishedAssets/src -fs_pakpath MyAssets/src -bsp MyAssets/src/map-castle_src.dpkdir/maps/castle.map

And use -pakpath engine option to find your compiled map the same way.

Enable or disable texture sets

Creates a file named DEPS at the root of your dpkdir, so in our example the file will be stored as map-castle_src.dpkdir/DEPS.

For the demonstration we will enable the tex-space texture set to get spacy skyboxes, and the tex-pk01 and tex-pk02 texture sets for surfaces. You may also list the tex-all meta texture set that will enable all Unvanquished official texture set, by the way it's better to only load what's needed (it will shorten loading time in game, reduce memory usage and avoid potential conflicts).

Gedit-deps-map-file.png

Reload the VFS using the 🗘 Refresh Models button on the toolbar or using the Flush and Reload Shaders option in texture browser menu. Don't worry the names, those options do the exact same things:

Netradiant-toolbar-refresh-textures.png

Netradiant-texture-browser-refresh-textures.png

You'll see the enabled texture sets listed and related textures displayed, ready to use:

Netradiant-space-textures.png

Making your own first map for real

See the Mapping Guide for mapping instructions and how-to!