Package scripts :: Script dialogue :: Class Dialogue
[hide private]
[frames] | no frames]

Class Dialogue

object --+
         |
        Dialogue

Represents a complete dialogue and acts as a container for the dialogue data belonging to a particular NPC.

Instance Methods [hide private]
 
__init__(self, npc_name, avatar_path, default_greeting, greetings=None, sections=None)
Initialize a new Dialogue instance.
 
__str__(self)
Return the string representation of a Dialogue instance.

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __subclasshook__

Properties [hide private]
  avatar_path
  default_greeting
  greetings
  npc_name
  sections

Inherited from object: __class__

Method Details [hide private]

__init__(self, npc_name, avatar_path, default_greeting, greetings=None, sections=None)
(Constructor)

 

Initialize a new Dialogue instance.

Parameters:
  • npc_name (basestring) - name displayed for the NPC in the dialogue.
  • avatar_path (basestring) - path to the image that should be displayed as the NPC's avatar.
  • default_greeting (DialogueSection) - section of dialogue that should be displayed when the dialogue is first initiated and no other start sections are available.
  • greetings (list of RootDialogueSections) - sections of dialogue defining the conditions under which each should be displayed when the dialogue is first initiated.
  • sections (list of DialogueSections) - sections of dialogue that make up this Dialogue instance.
Overrides: object.__init__

__str__(self)
(Informal representation operator)

 

Return the string representation of a Dialogue instance.

Overrides: object.__str__