Package parpg :: Module dialogue :: Class DialogueResponse
[hide private]
[frames] | no frames]

Class DialogueResponse

source code

  object --+    
           |    
DialogueNode --+
               |
              DialogueResponse

DialogueNode that represents one possible player response to a particular DialogueSection.

Instance Methods [hide private]
 
__init__(self, text, next_section_id, actions=None, condition=None)
Initialize a new DialogueResponse instance.
source code

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

Properties [hide private]
  actions
  condition
  next_section_id
  text

Inherited from object: __class__

Method Details [hide private]

__init__(self, text, next_section_id, actions=None, condition=None)
(Constructor)

source code 

Initialize a new DialogueResponse instance.

Parameters:
  • text (basestring) - text displayed as the content of the player's response.
  • next_section_id (basestring) - ID of the DialogueSection that should be jumped to if this response is chosen by the player.
  • actions (list of DialogueActions) - dialogue actions that should be executed if this response is chosen by the player.
  • condition (basestring) - Python expression that when evaluated determines whether the DialogueResponse should be displayed to the player as a valid response.
Overrides: object.__init__