To start with, let’s create a conversation for Siegfried. In fact, there will be several different conversations, but which one will be displayed will depend on the situation. Siegfried will have a quest for Geralt (the player) to kill the bandit leader. To create a conversation file we must select New -> Conversation (.dlg) from the File menu:

Image1115.png

The new conversation window will open:

Image1117.png

Display only the properties window. Select Utility Windows -> Properties from the View menu:

Image1119.png

The Properties window will open on the right side of the screen:

Image1121.png

Now add the first node of the conversation. To do this, select new conversation and right-click:

Image1123.png

If we save our conversation, the file name displayed will be siegfried_conversation, for example, instead of new conversation. We will save the conversation later. Now select Create Quest Node from the menu:

Image1125.png


This is how you create a quest conversation. The first empty node appears here:

Image1127.png

Remember that each conversation, regardless of its type (e.g. quest, dialog or cutscene), is always initiated by another character. It is never started by Geralt, i.e. the player. That is why the node we have just added will be for Siegfried. To create the text that Siegfriedwill say, double-click on EMPTY:

Image1129.png

This opens a window:

Image1131.png

Write "Hello Geralt” and hit ENTER. The first node is ready for Siegfried:

Image1133.png

Now Geralt (the player) must reply. To do this, select the “Hello Geralt” node and right-click:

Image1135.png

Select Create Quest Reply from the menu:

Image1137.png

This creates another empty node:

Image1139.png

Note that this node is blue. This means that Geralt (the player) will use it. Characters speak in turns – first one character speaks, then the other and so on. To create Geralt’s response, double-click on the new node and a window will open. Write “Hello Siegfried. Do you have any quests for me?” in the window and hit ENTER:

Image1141.png

Let’s add another node for Geralt. Select the “Hello Geralt” node and right-click:

Image1143.png

Select Create Quest Reply from the menu again:

Image1145.png

This adds another empty node for Geralt:

Image1147.png

Double-click on the new node and write “Farewell”. Then hit ENTER:

Image1149.png

Note that the “Farewell” node is a second option available during the quest conversation – the player can choose whether to say “Hello Siegfried. Do you have any quests for me?”) or “Farewell”. Left-click on the “Farewell” node:

Image1151.png

Now, in the properties window, click the right-hand column opposite the Conv Type attribute. Select Accompanying from the list:

Image1153.png

Now the “Farewell” node is a second choice during a quest conversation. Its changed status is visible in the new icon which appears to the left of the node:

Image1155.png

What we have done so far can be described in the following way: when the conversation starts, Siegfried says “Hello Geralt.” After this, Geralt can ask Siegfried if he has any quest, saying “Hello Siegfried. Do you have any quests for me?” or simply end the conversation by saying “Farewell.”

Now we will add a new node to allow Siegfried to respond to Geralt’s question about quests. To do this, select the ”Hello Siegfried. Do you have any quests for me” node and right-click:

Image1157.png

Select Create Quest Entry from the menu:

Image1159.png

This creates an empty node for Siegfried’s response:

Image1161.png

Double-click on the node and add the following text: “I do. You must deal with the bandit leader. I cannot do this”. Then hit ENTER:

Image1163.png

Now we have to add a reply. Select the “I do. You must deal with the bandit leader. I cannot do this” node and right-click.

Image1165.png

Select Create Quest Reply from the menu:

Image1167.png

This adds a new node:

Image1169.png

Double-click on it and write “Done”. Then hit ENTER:

Image1171.png

Since Geralt is not obligated to accept the quest, we must add a node so that he can decline. When Geralt, or the player, does not want to accept the quest offered by Siegfried, he can reply “Farewell”. But since this response already exists, we don’t have to go to the trouble of writing it again. Instead we can use a trick. Select the existing “Farewell” node and right-click:

Image1173.png

Select Copy from the menu:

Image1175.png

Now select the “I do. You must deal with the bandit leader. I cannot do this” node and right-click:

Image1177.png

Select Paste as link from the menu:

Image1179.png

This adds a node which is really a link to another node:

Image1181.png

Thanks to this trick we can avoid doubling up entries and the player will see the usual “Farewell” reply on the screen. However, we need to move the new link under the “Done” node. To do this, left-click and hold on the “Farewell” link:

Image1183.png

Then drag it down to the “Done” node and let go of the left mouse button:

Image1185.png

This is an simple and useful way to move nodes around. This is what we have done so far: at the beginning of the conversation Siegfried says “Hello Geralt.” In response, Geralt (the player) can ask Siegfried if he has any quests, saying “Hello Siegfried. Do you have any quests for me?”, or simply exit the conversation by saying “Farewell.”

If the player chooses the first response, Siegfried will reply “I do. You must deal with the bandit leader. I cannot do this.” Here the player can decide whether or not to accept the quest. The player will then select “Done” or can reject the quest by selecting “Farewell.” As you may have noted, the “Done” node determines that the player has accepted Siegfried’s quest. That’s why we need to assign a quest id to this node. Click on the “Done” node:

Image1187.png

In the Properties window, click the right-hand column opposite the Quest Id attribute and write siegfried_task :

Image1189.png

Note that the icon next to the “Done” node has changed:

Image1191.png


Important: After a quest node (one that contains a quest id), the next node in a given conversation branch cannot be another quest node. In our case this isn’t a problem, since our link leads to the “Farewell” node and is an Accompanying type node.

We’ve finished the node with Siegfried’s quest for Geralt. If the player already has this quest, however, the conversation we have prepared will not be displayed. We need to create a new conversation in which Siegfried will ask Geralt if he has completed the quest yet. If the answer is yes, then we need another conversation in which Siegfried will praise Geralt for completing the quest.

If there are three conversations, how does the game know which one to display? We have to take care of that ourselves by adding a flag system. Click on the “Hello Geralt” node:

Image1193.png

In the Properties window, click on the small yellow icon in the right-hand column opposite the Add Flag attribute in the After Flags section:

Image1195.png

This opens the Flags window:

Image1197.png

Right-click on the field in the Flags window and select Create Name from the menu:

Image1199.png

This opens the Enter name window:

Image1201.png

Write orders_received in the window:

Image1203.png

Then click on OK. The flag will appear in the Flags window:

Image1205.png

If you want to delete a particular flag, right-click on it and select Delete Name from the menu:

Image1207.png

We don’t want to delete this flag, though, so after adding it just click on OK in the Flags window:

Image1209.png

Now we’ll add a second flag called leader_killed. This flag will have the value 0 (false) if the bandit leader is alive. Once Geralt (the player) kills the bandit leader the value of the flag will change to 1 (true).

This flag, however, must a global flag. So far we have created local flags, i.e. ones that are only relevant during conversations. Global flags are relevant throughout the game, thus they can be used when creating quests, for example. This is described in another chapter of this manual. Global flags are saved in the globaldlgflags.2da file.

We need to create one now. To do this, select New -> 2DA file (.2da) from the File menu:

Image1211.png

The new 2da editor window will open:

Image1213.png

The Witcher’s .2da files are simple databases which contain text written in 2D tables. A .2da file may be composed of any number of columns and rows, but each new .2da file contains only two columns and two rows. The first row of a .2da file is a heading and the following row is a record. The first column is always a record key by which the database is addressed. In our globaldlgflags.2da file we only need one column. To remove the other one, right-click on either row:

Image1215.png

Select Remove Column from the menu:

Image1217.png

A window called Removing columns… will appear:

Image1219.png

Click on Yes:

Image1221.png

This removes the column. If you want to insert a new column, right-click on the spot where this column should be inserted and select Insert Column from the menu:

Image1223.png

To add a column on the end, select Add Column from the menu:

Image1225.png

Our .2da file now has one column. For the time being we need only one row but we cannot remove any. Note that rows are numbered from 0, starting from the second row. Why? As mentioned before, the first column and the first row may serve to create a heading. This is not necessary in our case, so right-click on the first row:

Image1227.png

Select **** from the menu:

Image1229.png

This highlights that our file .2da does not have a column heading:

Image1231.png

Now double-click on the second row:

Image1233.png

Write leader_killed in the field:

Image1235.png

Then hit ENTER. That’s it. If you want to add other rows to this file in the future, right-click on the place where you want to insert another row and select Insert Row from the menu:

Image1237.png

To add a new row at the end, select Add Row from the menu:

Image1239.png

If we wanted our.2da file to contain column and row headings, we would have to select Fix / Unfix from the menu before saving the file:

Image1241.png

This would change the first column and the first row into headings. Later, to modify the file we would have to select Fix / Unfix from the menu, otherwise new columns or rows couldn’t be added.

Our .2da file does not need any headings so we’ll leave it as it is. We need only save the file. To do this, select Save As… from the File menu:

Image1243.png

This opens the standard Windows window used for saving files. The Witcher’s .2da files are found in the Data\2DA folder. Open this folder, enter the name globaldlgflags and click on Save. Note that this file must be saved in the .2da format:

Image1245.png

If a different type of file is listed instead, it probably means that you’re trying to save the content in another open window by accident. Before saving the file, make sure that the new 2da editor window is active. If this window is inactive, the title bar will be grey:

Image1247.png

A different color means that the window is active:

Image1249.png

The asterisk before the window name means that the file has not been saved since the last change was introduced. Just as when saving templates, instead of choosing Save as… from the File menu, we can select Save new 2da editor. This will save the file directly in the module. Don’t do this now, however.

Let’s go back to our conversation. Click the right-hand column opposite the Add Flags attribute in the After Flags section and select orders_received from the list:

Image1251.png

The list is arranged alphabetically. Now we’ve added the orders_received flag:

Image1253.png

Flags are characterized by two states – either the flag is true (numerical value 1) or false (value 0). When Geralt begins his conversation with Siegfried, he does not have a quest from him yet. Therefore the flag should be set to 0. To change the value, click the right-hand column opposite the orders_received flag and write 0. Then hit ENTER:

Image1255.png

If you want to delete a flag from the After Flags section (don’t confuse this with deleting flags in the Flags window), click the right-hand column opposite the flag and delete the existing value:

Image1257.png

Then hit ENTER. The flag will be automatically deleted from the After Flags section:

Image1259.png

If you have deleted a flag you can add it to the list again by selecting it and setting the appropriate value, i.e. 0.

Now click on the “Done” node:

Image1261.png

In the Properties window, click the right-hand column opposite the Add Flags attribute in the After Flags section. Select orders_received from the list:

Image1263.png

Because the flag is automatically set on 1 (true), we do not need to change anything:

Image1265.png

Click the right-hand column opposite the Add Flags attribute again and select leader_killed from the list:

Image1267.png

This adds the leader_killed flag:

Image1269.png

However, we need to set the flag’s value to 0 because the bandit leader (Bandit leader) hasn’t been killed yet. Click the right-hand column opposite the leader_killed flag and enter the value 0. Then hit ENTER:

Image1271.png

These flags tell the game which conversation it should display and when. The conversation we will add in a minute will be only displayed when the orders_received flag’s value is 1 (true). We already know that the flag will have that value only after Geralt accepts Siegfried’s quest, i.e. after choosing the "Done” node.

Finally, two important remarks. Quest conversations’ flag properties are only modifiable in the After Flags section. Their values will be set after selecting a particular node. Also, when a player selects a quest node, i.e. one with a quest id, the conversation contained in this node will not be displayed during the next conversation.

Community content is available under CC-BY-SA unless otherwise noted.