0% found this document useful (0 votes)
397 views9 pages

Speedtree Tutorial For NWN2

This document provides a tutorial for creating a custom cattail plant in SpeedTree and importing it into Neverwinter Nights 2. It explains how to set up the necessary files, edit the tree structure and parameters in SpeedTree, and import the modified tree into the game. The tutorial aims to demonstrate the basic SpeedTree workflow to encourage experimenting with creating vegetation assets for Neverwinter Nights 2.

Uploaded by

Vermillion185
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
397 views9 pages

Speedtree Tutorial For NWN2

This document provides a tutorial for creating a custom cattail plant in SpeedTree and importing it into Neverwinter Nights 2. It explains how to set up the necessary files, edit the tree structure and parameters in SpeedTree, and import the modified tree into the game. The tutorial aims to demonstrate the basic SpeedTree workflow to encourage experimenting with creating vegetation assets for Neverwinter Nights 2.

Uploaded by

Vermillion185
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 9

1

SpeedTree Tutorial for Neverwinter Nights 2


by Vermillion
09/21/2019
v 1.0

Alright guys, the guide is here at last! We will create a single cattail plant based on cattail cluster
from NWN2, with original textures but much better polycount. This tutorial is very basic, so anyone
can repeat the steps and get the idea.
1. What is SpeedTree?
SpeedTree is a procedural vegetation modeling software for architectural visualization, movies
and games. This Technology was developed by Interactive Data Visualization, Inc. about two
decades ago and it was revolutionary at the time. Ones of the first games to use it were The Elder
Scrolls IV: Oblivion (2006) and Neverwinter Nights 2 (2006).

Now SpeedTree is very popular and licensed by many game developers. You can see it in a bunch
of titles such as Player Unknown’s Battlegrounds (2017), Assassin’s Creed Odyssey (2018) and
Apex Legends (2019).

Recently, I found that NWN2 .spt files can be edited with SpeedTree versions 3, 4.1, 4.2 and
5.0, which means we can now create custom trees, shrubs, flowers and with some experience and
time, almost any kind of flora limited only by imagination (and NWN2 capabilities).
NOTE: I recommend to use SpeedTree CAD 4.2. SpeedTree CAD 3 can be very frustrating: you
need to press F5 anytime you make a change to your tree to see the difference, which is annoying.
SpeedTree 5.0 Modeler is relatively modern and pretty good compared to older versions, but
doesn't have backward compatibility.

2
2. Tree System in NWN2
Each tree has four “components”: 1) Model .spt with .dds or .tga textures, 2) Line in dialog.tlk,
3) Line in trees.2da, 4) Blueprint .utr file. Let’s prepare all that stuff before start working with the
plant itself.
2.1 Model and textures (.spt & .dds)
To find models and textures go to the …\Neverwinter Nights 2\Data\ folder where
SpeedTree.zip, SpeedTree_X1.zip, SpeedTree_X2.zip archives are located.
TIP: I recommend to unpack all that stuff in one folder and use them as a references.
Open SpeedTree.zip. As you can see, each tree has an .spt model file and a couple of .dds
textures, three in most cases: diffuse map for trunk, normal map for trunk and a diffuse with alpha
channel for leaves, branches, fronds (so called composite map).

NOTE: some of the trees have suffixes at the end of the file name: *C – Cluster, *FU – Fruits,
*F – Fall, *SP – Spring, *W – Winter, *WSnow – Snowy version.
Find and copy Cattailc.spt, CattailC.dds, CattailBark_N.dds, CattailBark.dds. Now go to you
Override folder in …\User\Documents\Neverwinter Nights 2\Override\, create CattailS
subfolder, paste files there. Rename Cattailc.spt to CattailS.spt; rename and convert
CattailC.dds, CattailBark_N.dds, CattailBark.dds into CattailS.tga, CattailBark_N.tga,
CattailBark.tga using Photoshop or any other graphics editor.
NOTE: renaming leave texture is crucial – it must match model name.
2.2 Adding a new line in dialog.tlk
Talk table or dialog.tlk is a file that contains all text in Neverwinter Nights 2 except for the
dialogs. Each piece of text in the file is identified by a number called a String Reference
(StringRef or StrRef). With 2DA/TLK Editor open dialog.tlk (located in the base game folder),
jump to the bottom of the document and add new StringRef number, name of tree and save the
file.

3
2.3 Adding a new line in trees.2da
Two-dimensional arrays or .2da are tables that contain presets and rules for all aspects of the
game. In our case, information about all trees is stored in Trees.2da (can be found in
…\Neverwinter Nights 2\Data\2DA_X2.zip). Copy Trees.2da to your Override\CattailS folder,
open with 2DA/TLK Editor (or any other .2da editor), add a new line as displayed in the picture
and save the file.

2.4 Creating new blueprint


Blueprints allow us to work with objects in Toolset and to create instances. Tree blueprints have
.utr extension and can be found in …\Neverwinter Nights 2\Data\Templates.zip. Copy
cattailc.utr to the Override\CattailS folder, rename it to cattails.utr. Open it with GFF Editor
and edit the file as shown below.
NOTE: Tag and ResRef are strings to identify an object within the game. Usually they match the
model and blueprint name, but Tag must contain uppercase letters.
TIP: Seed is a variant of your tree. It’s not necessary, but it may be useful to set its value from
SpeedTree CAD 4.2 to see exactly the same tree in Toolset by default.

If you’ve done everything correctly, your …\User\Documents\Neverwinter Nights


2\Override\CattailS folder should look like this:

4
3. Tree System in NWN2
3.1 Setting up with SpeedTree CAD 4.2
Download SpeedTree CAD, unzip and run SpeedTree CAD 4.2.exe and you’ll see something
like this.

A few words about the user interface:


Menu Bar: a standard bar with File, Edit, View etc. tabs.
Tree window: you can see your tree model here. Navigation is very simple: rotate camera with left
mouse button, zoom by scrolling mouse wheel, press and dragging mouse wheel to move camera.
clicking the right mouse button in the tree window brings up the popup menu.
Toolbar: most useful here are View/Hide Leaves, Frond, Branches and Toggle Wind buttons.
Tree properties bar: the most important part, you can access all of the parameters that comprise
the shape and form of the tree here.
3.2 Tree structure
SpeedTree model composed of trunk, branches, fronds and leaves. Trunk may have "Level 1"
branches as its children. Each "Level 1" branch can have "Level 2" branches as its children. Branch
geometry can be replaced with frond geometry at any level (and all subsequent levels) but the
internal tree structure remains unchanged. The children of all branches at the last branch level are
the leaves of the tree, which are created using one of two methods: leaf cards (sprites) or leaf meshes
(polygons). Not all models will have all three of the basic components present in them. For
example, palm trees will likely have branches and fronds but no leaves.

5
The figure below depicts the hierarchical structure used by the SpeedTree modeling engine to
represent the structure of a tree.

Now open CattailS.spt and let’s look at how the curious cattail cluster was made in NWN2: it’s
actually a single plant with a short trunk (invisible in the game) and level 1branches bent at 90
degrees, branches level 2 are replaced by fronds.

TIP: If you want to dig deeper into SpeedTree structure and functionality, I recommend you check
the attached .chm references.
3.3 Editing the tree
NOTE: One important thing you need to understand before you start working: SpeedTree isn't a
modeling tool - you can't just "add some branches here and there". It’s a generator and you work
not only with the instance that you see right now but with the whole preset. It may be useful to see
what other instances looks like by changing the Seed number (Global Tab → Seeds section →
Randomize).
TIP: SpeedTree CAD is a very buggy tool and crashes happen from time to time - save your work
often and with different filenames.
1) Go to Menu Bar → Maps → click Remove embedded composite data and Remove
embedded composite data.

6
2) To see leave texture go to Tree properties bar → Fronds → in the section Texture Maps into
Diffuse layer choose CattailS.tga.
3) Delete level 2 branches (Tree properties bar → Branches Tab → in the «Level» section
choose Level 2 and press «Edit» and «Delete») and hide the fronds and leaves (Toolbar → View
Fronds and View Leaves buttons).
4) Hide the fronds and leaves (Toolbar → View Fronds and View Leaves buttons) and let’s work
on the trunk. Go to Tree properties bar → Trunk Tab and change parameters as shown in the
picture.

Most of the parameters are self-explanatory although some are not so obvious. Try to play with
parameters and curves - you’ll see the difference. To make a dilation at the top of the stem (it's a
cattail flower) click to Radius profile graph, in the curve editor make a similar curve.

7
5) Now unhide fronds (Toolbar → View Fronds) and go to the Branches Tab. Change the settings
as shown in the picture:

6) Make a few changes on the Fronds Tab:

8
7) Cattail should look good for now:

Save the file and launch the NWN2 Toolset. Under the Blueprints → Trees → Shrubs you’ll find
Cattail Singe.

That’s all, thanks for reading! Of course I didn’t cover many aspects here but this is enough to
start experimenting. My plan is make advanced guide for really complex tree in the future. If you
discover typos, errors or have any additions please contact me.
-Vermillion

You might also like