M&B: Bannerlord 1.2.7
The horns sound, the ravens gather.
Loading...
Searching...
No Matches
TaleWorlds.Library.TextInquiryData Class Reference

Public Member Functions

 TextInquiryData (string titleText, string text, bool isAffirmativeOptionShown, bool isNegativeOptionShown, string affirmativeText, string negativeText, Action< string > affirmativeAction, Action negativeAction, bool shouldInputBeObfuscated=false, Func< string, Tuple< bool, string > > textCondition=null, string soundEventPath="", string defaultInputText="")
 Parameter structure of the inquiry.
 
bool HasSameContentWith (object other)
 

Public Attributes

string TitleText
 
string Text = ""
 
readonly bool IsAffirmativeOptionShown
 
readonly bool IsNegativeOptionShown
 
readonly bool IsInputObfuscated
 
readonly string AffirmativeText
 
readonly string NegativeText
 
readonly string SoundEventPath
 
readonly string DefaultInputText
 
readonly Action< string > AffirmativeAction
 
readonly Action NegativeAction
 
readonly Func< string, Tuple< bool, string > > TextCondition
 

Constructor & Destructor Documentation

◆ TextInquiryData()

TaleWorlds.Library.TextInquiryData.TextInquiryData ( string  titleText,
string  text,
bool  isAffirmativeOptionShown,
bool  isNegativeOptionShown,
string  affirmativeText,
string  negativeText,
Action< string >  affirmativeAction,
Action  negativeAction,
bool  shouldInputBeObfuscated = false,
Func< string, Tuple< bool, string > >  textCondition = null,
string  soundEventPath = "",
string  defaultInputText = "" 
)
Parameters
titleTextTitle of the inquiry.
textInner text of the inquiry.
isAffirmativeOptionShownDetermines if the positive action is shown.
isNegativeOptionShownDetermines if the negative action is shown.
affirmativeTextDetermines the text content of the positive action.
negativeTextDetermines the text content of the negative action.
affirmativeActionAction that happens when positive action is selected. Returns input text.
negativeActionAction that happens when negative action is selected.
shouldInputBeObfuscatedDetermines if the text is obfuscated while input
textConditionFunc that asks if the current input text is permitted or not. Returns result and reason hint as a string. Null by default.
soundEventPathPath of a sound file in the project. Plays at the start of the inquiry.
defaultInputTextDetermines the default text the popup will open with

Member Function Documentation

◆ HasSameContentWith()

bool TaleWorlds.Library.TextInquiryData.HasSameContentWith ( object  other)

Member Data Documentation

◆ TitleText

string TaleWorlds.Library.TextInquiryData.TitleText

◆ Text

string TaleWorlds.Library.TextInquiryData.Text = ""

◆ IsAffirmativeOptionShown

readonly bool TaleWorlds.Library.TextInquiryData.IsAffirmativeOptionShown

◆ IsNegativeOptionShown

readonly bool TaleWorlds.Library.TextInquiryData.IsNegativeOptionShown

◆ IsInputObfuscated

readonly bool TaleWorlds.Library.TextInquiryData.IsInputObfuscated

◆ AffirmativeText

readonly string TaleWorlds.Library.TextInquiryData.AffirmativeText

◆ NegativeText

readonly string TaleWorlds.Library.TextInquiryData.NegativeText

◆ SoundEventPath

readonly string TaleWorlds.Library.TextInquiryData.SoundEventPath

◆ DefaultInputText

readonly string TaleWorlds.Library.TextInquiryData.DefaultInputText

◆ AffirmativeAction

readonly Action<string> TaleWorlds.Library.TextInquiryData.AffirmativeAction

◆ NegativeAction

readonly Action TaleWorlds.Library.TextInquiryData.NegativeAction

◆ TextCondition

readonly Func<string, Tuple<bool,string> > TaleWorlds.Library.TextInquiryData.TextCondition