CSV Converter

Using the CSV Converter, you can create a dialogue database from a CSV (comma-separated values) file.


CSV File Format

The CSV file must follow the format below.

It can contain one or more sections. Each section is optional. The sections are:

Section Description
Database Database Properties
Actors Actors
Items Items; also used for quests
Locations Locations
Variables Variables
Conversations High level information about each conversation
DialogueEntries Individual dialogue entries in the conversations
OutgoingLinks Links between dialogue entries

The Database section must contain:

Database
Name,Version,Author,Description,Emphasis1,Emphasis2,Emphasis3,Emphasis4
(name),(version),(author),(description),(emphasis setting 1 in format #rrggbbaa biu),(emphasis2),(emphasis3),(emphasis4)
Global User Script
(luacode)

The Actors section must contain:

Actors
ID,Portrait,AltPortraits,Name,Pictures,Description,IsPlayer
Number,Special,Special,Text,Files,Text,Boolean
(id),(texturename),[(texturenames)],(name),[(picturenames)],(description),(isplayer)
...

The Items, Locations, Variables, and Conversations section must contain:

(Heading) -- where this is Items, Locations, Variables, or Conversations
ID,(field),(field),(field)...
Number,(fieldtype),(fieldtype),(fieldtype)...
(id),(fieldvalue),(fieldvalue),(fieldvalue)...

The Variables section may contain a final column titled "InitialValueType" that specifies the variable type (Text, Number, or Boolean).

The DialogueEntries section must contain:

DialogueEntries
entrytag,ConvID,ID,Actor,Conversant,MenuText,DialogueText,IsGroup,FalseConditionAction,ConditionPriority,Conditions,Script,Sequence,(field),(field)...,canvasRect
Text,Number,Number,Number,Number,Text,Text,Boolean,Special,Special,Text,Text,Text,(fieldtype),(fieldtype),...,Text
(entrytag),(ConvID),(ID),(ActorID),(ConversantID),(MenuText),(DialogueText),(IsGroup),(FalseConditionAction),(ConditionPriority),(Conditions),(Script),(Sequence),(fieldvalue),(fieldvalue)...,#;#

The DialogueEntries section may contain an optional final field "canvasRect" of the format "x;y" that specifies the dialogue entry's position on the node editor canvas.

The OutgoingLinks section must contain:

OutgoingLinks
OriginConvID,OriginID,DestConvID,DestID,ConditionPriority
Number,Number,Number,Number,Special
#,#,#,#,(priority)

Omitted values in any particular asset should be tagged with {{omit}}.

At the bottom of this page is an Example CSV File


CSV Converter Window

  1. Select Window > Dialogue System > Converters > Chat Mapper Converter.
  2. Set Source File to the name of your CSV file.
  3. Set Output Folder and Database Filename to the path (inside your Assets hierarchy) and name to create the dialogue database.
  4. Set Encoding to the encoding format of the file.
  5. Tick Overwrite if you want to overwrite an existing dialogue database (if one exists).
  6. Click Convert.

The image below shows settings for converting a CSV file:

Example CSV File

This is an excerpt of the Feature Demo database. It's been pared down for brevity, so it won't actually import into the CSV Converter, but it shows the format of each section. You can use the Dialogue Editor to export a complete version of the Feature Demo database which you can import using the CSV Converter.

Database
Name,Version,Author,Description,Emphasis1,Emphasis2,Emphasis3,Emphasis4
CSV Import,1.5.1.0,John Smith,"This is the description.",#ff0000ff b--,#44b634ff b--,#4688e6ff b--,#ccccccff b--
Global User Script
Variable["Alert"] = "Welcome!"

Actors
ID,Portrait,AltPortraits,Name,Pictures,Description,IsPlayer
Number,Special,Special,Text,Files,Text,Boolean
1,,[],Player,[../../Art/Portraits/Player.png],The player controls a sci-filieutenant.,True
2,,[],Private Hart,[../../Art/Portraits/Private Hart.png],"The squad's technical expert.",False

Items
ID,Name,Description,Success Description,Failure Description,State,Entry Count,Entry 0 State,Entry 0,Entry 1 State,Entry 1,Is Item
Number,Text,Text,Text,Text,Text,Number,Text,Text,Text,Text,Boolean
1,Assassinate the Emperor,"Your squad has infiltrated the evil Emperor's star carrier to assassinate him during the launch ceremony.\nYou can liberate your star system by opening the airlock, but scores of innocent attendees will also die.\nWill you follow orders or abandon this opportunity?","With the Emperor jettisoned into space along with scores of innocent families and children, your star system is free from the Empire's tyranny.",You decided that killing so many innocent people would make you no better than the Emperor himself. The rebellion will have to find another way.,unassigned,2,unassigned,You must hack the computer to gain control of the airlock doors.,unassigned,You must decide whether to open the airlock doors or lock them.,{{omit}}

Locations
ID,Name
Number,Text
1,Star Carrier

Variables
ID,Name,Initial Value,Description,InitialValueType
Number,Text,Text,Text,Text,
0,Alert,,Show alert messages during gameplay by setting this variable.,Text

Conversations
ID,Title,Description,Actor,Conversant
Number,Text,Text,Actor,Actor
1,Private Hart,"This conversation occurs between the player and Private Hart, who refuses to open the airlock to kill the evil Emperor because a hundred bystanders would also die. This is the primary conversation in the demo. It demonstrates branching dialogue, the quest system, sequences, and QTEs. ",1,2

DialogueEntries
entrytag,ConvID,ID,Actor,Conversant,Title,MenuText,DialogueText,IsGroup,FalseConditionAction,ConditionPriority,Conditions,Script,Sequence,Video File,Importance,FR,Menu Text FR,Sequence FR,Response Menu Sequence
Text,Number,Number,Number,Number,Text,Text,Text,Boolean,Special,Special,Text,Text,Text,Text,Text,Text,Text,Localization,Text,Text,Text
Player_1_0,1,0,1,2,START,,,False,Block,Normal,,,None(),,,,{{omit}},{{omit}},{{omit}},{{omit}},{{omit}}
Private_Hart_1_1,1,1,2,1,No Quest Yet,,"Lieutenant! We have a problem, sir!\nA big problem.",False,Block,Normal,Item["Assassinate_the_Emperor"].State == "unassigned",,"LookAt(listener,speaker); LookAt(speaker,listener); Camera(Medium); Camera(Closeup,speaker,1)@0.1; require Camera(Closeup,listener)@2",,{{omit}},{{omit}},{{omit}},{{omit}},{{omit}}
Private_Hart_1_2,1,2,2,1,Quest is Active,,"We can't murder those bystanders, sir. It's not right.",False,Block,Normal,Item["Assassinate_the_Emperor"].State == "active",,"LookAt(listener,speaker); LookAt(speaker,listener); Camera(Closeup); require Camera(Closeup,listener)@2.5",,{{omit}},{{omit}},{{omit}},{{omit}},{{omit}}
Private_Hart_1_4,1,4,2,1,Airlock Relocked,,"You did the right thing, sir.",False,Block,Normal,Item["Assassinate_the_Emperor"].State == "failure",,"LookAt(listener,speaker); LookAt(speaker,listener); Camera(Closeup); require Camera(Closeup,listener)@2",,{{omit}},{{omit}},{{omit}},{{omit}},{{omit}}
Player_1_5,1,5,1,2,,Calm down. What's the problem?,,False,Block,Normal,(Quest["Assassinate_the_Emperor"] == "success") and (Variable["gotBox"] ~= false),Quest["Assassinate_the_Emperor"] = "unassigned",,,{{omit}},{{omit}},{{omit}},{{omit}},{{omit}}
Player_1_6,1,6,1,2,,"Report, private.",,False,Block,Normal,,,,,{{omit}},{{omit}},{{omit}},{{omit}},{{omit}}
Player_1_7,1,7,1,2,,"Stand by, private. I'll be back.",,False,Block,Normal,,,,,{{omit}},{{omit}},{{omit}},{{omit}},{{omit}}
Private_Hart_1_8,1,8,2,1,,,"The Emperor is in the hangar, sir.",False,Block,Normal,,,,,{{omit}},{{omit}},{{omit}},{{omit}},{{omit}}
Player_1_9,1,9,1,2,,Good. Our spies were right.,,False,Block,Normal,,,,,{{omit}},{{omit}},{{omit}},{{omit}},{{omit}}

OutgoingLinks
OriginConvID,OriginID,DestConvID,DestID,ConditionPriority
Number,Number,Number,Number,Special
1,0,1,1,Normal
1,0,1,2,Normal
1,0,1,3,Normal
1,0,1,4,Normal

<< Aurora Toolset | Unique ID Tool >>