Request: GetCurrentConversation - script function to return the currently active conversation
prwo
Member Posts: 69
To my knowledge, there is no way to query the dialog (conversation) that is currently running.
There is a way to provide the desired dialog ResRef in BeginConversation and ActionStartConversation (overriding the default one set in the toolset), but there is no way to read out this provided ResRef or the defaulted one (in general: the one that is to be started or effectively already running), e.g. in the OnConversation script or in any script that is called from within the running conversation.
I'd like to request a function like this:
This way a script could distinguish which conversation it is currently in and make choices depending on it.
There is a way to provide the desired dialog ResRef in BeginConversation and ActionStartConversation (overriding the default one set in the toolset), but there is no way to read out this provided ResRef or the defaulted one (in general: the one that is to be started or effectively already running), e.g. in the OnConversation script or in any script that is called from within the running conversation.
I'd like to request a function like this:
// * Returns the conversation ResRef oObject is currently in. Returns "" if oObject is currently not in a conversation.
string GetCurrentConversation (object oObject)
This way a script could distinguish which conversation it is currently in and make choices depending on it.
Post edited by prwo on
0
Comments
So you would have to implement another workaround to retrieve default dialogs, since, to my knowledge, there is no way to read out a creature's set Conversation either.
-> Well, this would ask for another pair of useful functions:
// * Returns the conversation that is currently assigned to oObject. string GetConversation (object oObject) // * Assigns a new conversation oObject. string SetConversation (object oObject, string sResRef)
Maybe the second paragraph in my initial post was misleading: "There is a way to provide the desired dialog ResRef in BeginConversation and ActionStartConversation (overriding the default one set in the toolset), but there is no way to read out this provided ResRef". -> Actually I want to read out the dialog independently on how it was set. I corrected this in the initial post.