v3.9.1 Documentation
Fungus.NarrativeLog Class Reference

Controls dialog history More...

Inheritance diagram for Fungus.NarrativeLog:

Public Member Functions

delegate void NarrativeAddedHandler ()
 
void AddLine (string name, string text)
 Add a line of dialog to the Narrative Log More...
 
void Clear ()
 Clear all lines of the narrative log Usually used on restart More...
 
string GetJsonHistory ()
 Convert history into Json for saving in SaveData More...
 
string GetPrettyHistory (bool previousOnly=false)
 Show previous lines for display purposes More...
 
void LoadHistory (string narrativeData)
 Load History from Json More...
 

Static Public Member Functions

static void DoNarrativeAdded ()
 

Protected Member Functions

virtual void Awake ()
 
virtual void OnEnable ()
 
virtual void OnDisable ()
 
virtual void OnWriterState (Writer writer, WriterState writerState)
 

Events

static NarrativeAddedHandler OnNarrativeAdded
 NarrativeAdded signal. More...
 

Detailed Description

Controls dialog history

Definition at line 38 of file NarrativeLog.cs.

Member Function Documentation

◆ AddLine()

void Fungus.NarrativeLog.AddLine ( string  name,
string  text 
)

Add a line of dialog to the Narrative Log

Parameters
nameCharacter Name
textNarrative Text

Definition at line 84 of file NarrativeLog.cs.

◆ Awake()

virtual void Fungus.NarrativeLog.Awake ( )
protectedvirtual

Definition at line 50 of file NarrativeLog.cs.

◆ Clear()

void Fungus.NarrativeLog.Clear ( )

Clear all lines of the narrative log Usually used on restart

Definition at line 97 of file NarrativeLog.cs.

◆ DoNarrativeAdded()

static void Fungus.NarrativeLog.DoNarrativeAdded ( )
static

Definition at line 46 of file NarrativeLog.cs.

◆ GetJsonHistory()

string Fungus.NarrativeLog.GetJsonHistory ( )

Convert history into Json for saving in SaveData

Returns

Definition at line 106 of file NarrativeLog.cs.

◆ GetPrettyHistory()

string Fungus.NarrativeLog.GetPrettyHistory ( bool  previousOnly = false)

Show previous lines for display purposes

Returns

Definition at line 116 of file NarrativeLog.cs.

◆ LoadHistory()

void Fungus.NarrativeLog.LoadHistory ( string  narrativeData)

Load History from Json

Parameters
narrativeData

Definition at line 135 of file NarrativeLog.cs.

◆ NarrativeAddedHandler()

delegate void Fungus.NarrativeLog.NarrativeAddedHandler ( )

◆ OnDisable()

virtual void Fungus.NarrativeLog.OnDisable ( )
protectedvirtual

Definition at line 60 of file NarrativeLog.cs.

◆ OnEnable()

virtual void Fungus.NarrativeLog.OnEnable ( )
protectedvirtual

Definition at line 55 of file NarrativeLog.cs.

◆ OnWriterState()

virtual void Fungus.NarrativeLog.OnWriterState ( Writer  writer,
WriterState  writerState 
)
protectedvirtual

Definition at line 65 of file NarrativeLog.cs.

Event Documentation

◆ OnNarrativeAdded

NarrativeAddedHandler Fungus.NarrativeLog.OnNarrativeAdded
static

NarrativeAdded signal.

Sent when a line is added.

Definition at line 44 of file NarrativeLog.cs.


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