Table of Contents

Class DialogEvents.ActionTaken

Namespace
Anvil.API.Events
Assembly
NWN.Anvil.dll

Triggered when a dialog "Action Taken" node is executed.

public sealed class DialogEvents.ActionTaken : IEvent
Inheritance
DialogEvents.ActionTaken
Implements
Inherited Members
Extension Methods

Examples

[ScriptHandler("my_action_taken")]
public void DialogActionTaken(CallInfo callInfo)
{
  DialogEvents.ActionTaken eventData = new DialogEvents.ActionTaken();
  Log.Info($"Action taken, speaker: {eventData.CurrentSpeaker?.Name}, player: {eventData.PlayerSpeaker?.ControlledCreature?.Name}");
}

Remarks

This class should be constructed manually as a part of a script handler, matching the script name specified in the dialog node.

Properties

CurrentSpeaker

Gets the creature/object currently speaking.

LastSpeaker

Gets the last creature/object that spoke in this conversation.

PlayerSpeaker

Gets the player speaker in this conversation.

Methods

PauseConversation()

Pauses the current conversation. Wraps NWScript.ActionPauseConversation().

ResumeConversation()

Resumes a paused conversation. Wraps NWScript.ActionResumeConversation().