PixelCrushers.DialogueSystem.Template Class Reference

This class defines the template that the Dialogue Database Editor will use when creating new dialogue database assets such as actors and conversations. More...

Public Member Functions

Actor CreateActor (int id, string name, bool isPlayer)
 Creates a new actor with the fields defined in the template.
 
Item CreateItem (int id, string name)
 Creates a new item with the fields defined in the template.
 
Item CreateQuest (int id, string name)
 Creates a new quest with the fields defined in the template.
 
Location CreateLocation (int id, string name)
 Creates a new location with the fields defined in the template.
 
Variable CreateVariable (int id, string name, string value)
 Creates a new variable (Text type) with the fields defined in the template.
 
Variable CreateVariable (int id, string name, string value, FieldType type)
 Creates a new variable with the fields defined in the template.
 
Conversation CreateConversation (int id, string title)
 Creates a new conversation with the fields defined in the template.
 
DialogueEntry CreateDialogueEntry (int id, int conversationID, string title)
 Creates a new dialogue entry with the fields defined in the template.
 
List< FieldCreateFields (List< Field > templateFields)
 
int GetNextActorID (DialogueDatabase database)
 
Returns
A value 1 higher than the highest actor ID in the database.

 
int GetNextItemID (DialogueDatabase database)
 
Returns
A value 1 higher than the highest item/quest ID in the database.

 
int GetNextQuestID (DialogueDatabase database)
 
Returns
A value 1 higher than the highest item/quest ID in the database.

 
int GetNextLocationID (DialogueDatabase database)
 
Returns
A value 1 higher than the highest location ID in the database.

 
int GetNextVariableID (DialogueDatabase database)
 
Returns
A value 1 higher than the highest variable ID in the database.

 
int GetNextConversationID (DialogueDatabase database)
 
Returns
A value 1 higher than the highest conversation ID in the database.

 
int GetNextDialogueEntryID (Conversation conversation)
 
Returns
A value 1 higher than the highest dialogue entry ID in the conversation.

 

Static Public Member Functions

static Template FromDefault ()
 

Public Attributes

bool treatItemsAsQuests = true
 
List< FieldactorFields = new List<Field>()
 
List< FielditemFields = new List<Field>()
 
List< FieldquestFields = new List<Field>()
 
List< FieldlocationFields = new List<Field>()
 
List< FieldvariableFields = new List<Field>()
 
List< FieldconversationFields = new List<Field>()
 
List< FielddialogueEntryFields = new List<Field>()
 
List< string > actorPrimaryFieldTitles = new List<string>()
 
List< string > itemPrimaryFieldTitles = new List<string>()
 
List< string > questPrimaryFieldTitles = new List<string>()
 
List< string > locationPrimaryFieldTitles = new List<string>()
 
List< string > variablePrimaryFieldTitles = new List<string>()
 
List< string > conversationPrimaryFieldTitles = new List<string>()
 
List< string > dialogueEntryPrimaryFieldTitles = new List<string>()
 
Color npcLineColor = Color.red
 
Color pcLineColor = Color.blue
 
Color repeatLineColor = Color.gray
 

Detailed Description

This class defines the template that the Dialogue Database Editor will use when creating new dialogue database assets such as actors and conversations.

The Dialogue Database Editor stores a copy of the template in EditorPrefs using the TemplateTools class. The equivalent in Chat Mapper is Project Preferences.

Member Function Documentation

◆ CreateActor()

Actor PixelCrushers.DialogueSystem.Template.CreateActor ( int  id,
string  name,
bool  isPlayer 
)
inline

Creates a new actor with the fields defined in the template.

◆ CreateConversation()

Conversation PixelCrushers.DialogueSystem.Template.CreateConversation ( int  id,
string  title 
)
inline

Creates a new conversation with the fields defined in the template.

◆ CreateDialogueEntry()

DialogueEntry PixelCrushers.DialogueSystem.Template.CreateDialogueEntry ( int  id,
int  conversationID,
string  title 
)
inline

Creates a new dialogue entry with the fields defined in the template.

◆ CreateFields()

List< Field > PixelCrushers.DialogueSystem.Template.CreateFields ( List< Field templateFields)
inline

◆ CreateItem()

Item PixelCrushers.DialogueSystem.Template.CreateItem ( int  id,
string  name 
)
inline

Creates a new item with the fields defined in the template.

◆ CreateLocation()

Location PixelCrushers.DialogueSystem.Template.CreateLocation ( int  id,
string  name 
)
inline

Creates a new location with the fields defined in the template.

◆ CreateQuest()

Item PixelCrushers.DialogueSystem.Template.CreateQuest ( int  id,
string  name 
)
inline

Creates a new quest with the fields defined in the template.

◆ CreateVariable() [1/2]

Variable PixelCrushers.DialogueSystem.Template.CreateVariable ( int  id,
string  name,
string  value 
)
inline

Creates a new variable (Text type) with the fields defined in the template.

◆ CreateVariable() [2/2]

Variable PixelCrushers.DialogueSystem.Template.CreateVariable ( int  id,
string  name,
string  value,
FieldType  type 
)
inline

Creates a new variable with the fields defined in the template.

◆ FromDefault()

static Template PixelCrushers.DialogueSystem.Template.FromDefault ( )
inlinestatic

◆ GetNextActorID()

int PixelCrushers.DialogueSystem.Template.GetNextActorID ( DialogueDatabase  database)
inline

Returns
A value 1 higher than the highest actor ID in the database.

◆ GetNextConversationID()

int PixelCrushers.DialogueSystem.Template.GetNextConversationID ( DialogueDatabase  database)
inline

Returns
A value 1 higher than the highest conversation ID in the database.

◆ GetNextDialogueEntryID()

int PixelCrushers.DialogueSystem.Template.GetNextDialogueEntryID ( Conversation  conversation)
inline

Returns
A value 1 higher than the highest dialogue entry ID in the conversation.

◆ GetNextItemID()

int PixelCrushers.DialogueSystem.Template.GetNextItemID ( DialogueDatabase  database)
inline

Returns
A value 1 higher than the highest item/quest ID in the database.

◆ GetNextLocationID()

int PixelCrushers.DialogueSystem.Template.GetNextLocationID ( DialogueDatabase  database)
inline

Returns
A value 1 higher than the highest location ID in the database.

◆ GetNextQuestID()

int PixelCrushers.DialogueSystem.Template.GetNextQuestID ( DialogueDatabase  database)
inline

Returns
A value 1 higher than the highest item/quest ID in the database.

◆ GetNextVariableID()

int PixelCrushers.DialogueSystem.Template.GetNextVariableID ( DialogueDatabase  database)
inline

Returns
A value 1 higher than the highest variable ID in the database.

Member Data Documentation

◆ actorFields

List<Field> PixelCrushers.DialogueSystem.Template.actorFields = new List<Field>()

◆ actorPrimaryFieldTitles

List<string> PixelCrushers.DialogueSystem.Template.actorPrimaryFieldTitles = new List<string>()

◆ conversationFields

List<Field> PixelCrushers.DialogueSystem.Template.conversationFields = new List<Field>()

◆ conversationPrimaryFieldTitles

List<string> PixelCrushers.DialogueSystem.Template.conversationPrimaryFieldTitles = new List<string>()

◆ dialogueEntryFields

List<Field> PixelCrushers.DialogueSystem.Template.dialogueEntryFields = new List<Field>()

◆ dialogueEntryPrimaryFieldTitles

List<string> PixelCrushers.DialogueSystem.Template.dialogueEntryPrimaryFieldTitles = new List<string>()

◆ itemFields

List<Field> PixelCrushers.DialogueSystem.Template.itemFields = new List<Field>()

◆ itemPrimaryFieldTitles

List<string> PixelCrushers.DialogueSystem.Template.itemPrimaryFieldTitles = new List<string>()

◆ locationFields

List<Field> PixelCrushers.DialogueSystem.Template.locationFields = new List<Field>()

◆ locationPrimaryFieldTitles

List<string> PixelCrushers.DialogueSystem.Template.locationPrimaryFieldTitles = new List<string>()

◆ npcLineColor

Color PixelCrushers.DialogueSystem.Template.npcLineColor = Color.red

◆ pcLineColor

Color PixelCrushers.DialogueSystem.Template.pcLineColor = Color.blue

◆ questFields

List<Field> PixelCrushers.DialogueSystem.Template.questFields = new List<Field>()

◆ questPrimaryFieldTitles

List<string> PixelCrushers.DialogueSystem.Template.questPrimaryFieldTitles = new List<string>()

◆ repeatLineColor

Color PixelCrushers.DialogueSystem.Template.repeatLineColor = Color.gray

◆ treatItemsAsQuests

bool PixelCrushers.DialogueSystem.Template.treatItemsAsQuests = true

◆ variableFields

List<Field> PixelCrushers.DialogueSystem.Template.variableFields = new List<Field>()

◆ variablePrimaryFieldTitles

List<string> PixelCrushers.DialogueSystem.Template.variablePrimaryFieldTitles = new List<string>()

The documentation for this class was generated from the following file: