Table of Contents

Class QuestBase

Namespace
TaleWorlds.CampaignSystem
Assembly
TaleWorlds.CampaignSystem.dll
public abstract class QuestBase : MBObjectBase
Inheritance
QuestBase
Derived
Inherited Members

Constructors

QuestBase(string, Hero, CampaignTime, int)

protected QuestBase(string questId, Hero questGiver, CampaignTime duration, int rewardGold)

Parameters

questId string
questGiver Hero
duration CampaignTime
rewardGold int

Fields

DiscussDialogFlow

protected DialogFlow DiscussDialogFlow

Field Value

DialogFlow

OfferDialogFlow

protected DialogFlow OfferDialogFlow

Field Value

DialogFlow

QuestCharacterDialogFlow

protected DialogFlow QuestCharacterDialogFlow

Field Value

DialogFlow

RewardGold

[SaveableField(107)]
public readonly int RewardGold

Field Value

int

Properties

IsFinalized

public bool IsFinalized { get; }

Property Value

bool

IsOngoing

public bool IsOngoing { get; }

Property Value

bool

IsRemainingTimeHidden

public abstract bool IsRemainingTimeHidden { get; }

Property Value

bool

IsSpecialQuest

public virtual bool IsSpecialQuest { get; }

Property Value

bool

IsThereDiscussDialogFlow

public bool IsThereDiscussDialogFlow { get; }

Property Value

bool

IsTrackEnabled

[SaveableProperty(104)]
public bool IsTrackEnabled { get; }

Property Value

bool

JournalEntries

public MBReadOnlyList<JournalLog> JournalEntries { get; }

Property Value

MBReadOnlyList<JournalLog>

QuestDueTime

[SaveableProperty(101)]
public CampaignTime QuestDueTime { get; protected set; }

Property Value

CampaignTime

QuestGiver

public Hero QuestGiver { get; }

Property Value

Hero

RelationshipChangeWithQuestGiver

public virtual int RelationshipChangeWithQuestGiver { get; protected set; }

Property Value

int

TargetHeroDiedLogText

protected virtual TextObject TargetHeroDiedLogText { get; }

Property Value

TextObject

TargetHeroDisappearedLogText

protected virtual TextObject TargetHeroDisappearedLogText { get; }

Property Value

TextObject

TaskList

public MBReadOnlyList<QuestTaskBase> TaskList { get; }

Property Value

MBReadOnlyList<QuestTaskBase>

Title

public abstract TextObject Title { get; }

Property Value

TextObject

Methods

AddDiscreteLog(TextObject, TextObject, int, int, TextObject, bool)

public JournalLog AddDiscreteLog(TextObject text, TextObject taskName, int currentProgress, int targetProgress, TextObject shortText = null, bool hideInformation = false)

Parameters

text TextObject
taskName TextObject
currentProgress int
targetProgress int
shortText TextObject
hideInformation bool

Returns

JournalLog

AddGameMenu(string, TextObject, OnInitDelegate, MenuOverlayType, MenuFlags)

public void AddGameMenu(string menuId, TextObject menuText, OnInitDelegate initDelegate, GameOverlays.MenuOverlayType overlay = MenuOverlayType.None, GameMenu.MenuFlags menuFlags = MenuFlags.None)

Parameters

menuId string
menuText TextObject
initDelegate OnInitDelegate
overlay GameOverlays.MenuOverlayType
menuFlags GameMenu.MenuFlags

AddGameMenuOption(string, string, TextObject, OnConditionDelegate, OnConsequenceDelegate, bool, int)

public void AddGameMenuOption(string menuId, string optionId, TextObject optionText, GameMenuOption.OnConditionDelegate condition, GameMenuOption.OnConsequenceDelegate consequence, bool Isleave = false, int index = -1)

Parameters

menuId string
optionId string
optionText TextObject
condition GameMenuOption.OnConditionDelegate
consequence GameMenuOption.OnConsequenceDelegate
Isleave bool
index int

AddLog(TextObject, bool)

public JournalLog AddLog(TextObject text, bool hideInformation = false)

Parameters

text TextObject
hideInformation bool

Returns

JournalLog

AddTask(QuestTaskBase)

protected void AddTask(QuestTaskBase task)

Parameters

task QuestTaskBase

AddTrackedObject(ITrackableCampaignObject)

public void AddTrackedObject(ITrackableCampaignObject trackedObject)

Parameters

trackedObject ITrackableCampaignObject

AddTwoWayContinuousLog(TextObject, TextObject, int, int, bool)

public JournalLog AddTwoWayContinuousLog(TextObject text, TextObject taskName, int currentProgress, int range, bool hideInformation = false)

Parameters

text TextObject
taskName TextObject
currentProgress int
range int
hideInformation bool

Returns

JournalLog

AutoGeneratedInstanceCollectObjects(List<object>)

protected override void AutoGeneratedInstanceCollectObjects(List<object> collectedObjects)

Parameters

collectedObjects List<object>

ChangeQuestDueTime(CampaignTime)

public void ChangeQuestDueTime(CampaignTime questDueTime)

Parameters

questDueTime CampaignTime

CompleteQuestWithBetrayal(TextObject)

public void CompleteQuestWithBetrayal(TextObject betrayLog = null)

Parameters

betrayLog TextObject

CompleteQuestWithCancel(TextObject)

public void CompleteQuestWithCancel(TextObject cancelLog = null)

Parameters

cancelLog TextObject

CompleteQuestWithFail(TextObject)

public void CompleteQuestWithFail(TextObject cancelLog = null)

Parameters

cancelLog TextObject

CompleteQuestWithSuccess()

public void CompleteQuestWithSuccess()

CompleteQuestWithTimeOut(TextObject)

public void CompleteQuestWithTimeOut(TextObject timeOutLog = null)

Parameters

timeOutLog TextObject

GetCurrentProgress()

public virtual int GetCurrentProgress()

Returns

int

GetMaxProgress()

public virtual int GetMaxProgress()

Returns

int

GetPrefabName()

public virtual string GetPrefabName()

Returns

string

HourlyTick()

protected abstract void HourlyTick()

InitializeQuestOnCreation()

protected void InitializeQuestOnCreation()

InitializeQuestOnGameLoad()

protected abstract void InitializeQuestOnGameLoad()

InitializeQuestOnLoadWithQuestManager()

public void InitializeQuestOnLoadWithQuestManager()

IsLocationTrackedByQuest(Location)

public virtual GameMenuOption.IssueQuestFlags IsLocationTrackedByQuest(Location location)

Parameters

location Location

Returns

GameMenuOption.IssueQuestFlags

IsTracked(ITrackableCampaignObject)

public bool IsTracked(ITrackableCampaignObject o)

Parameters

o ITrackableCampaignObject

Returns

bool

OnBeforeTimedOut(ref bool, ref bool)

protected virtual void OnBeforeTimedOut(ref bool completeWithSuccess, ref bool doNotResolveTheQuest)

Parameters

completeWithSuccess bool
doNotResolveTheQuest bool

OnBetrayal()

protected virtual void OnBetrayal()

OnCanceled()

public virtual void OnCanceled()

OnCompleteWithSuccess()

protected virtual void OnCompleteWithSuccess()

OnFailed()

public virtual void OnFailed()

OnFinalize()

protected virtual void OnFinalize()

OnHeroCanBeSelectedInInventoryInfoIsRequested(Hero, ref bool)

public virtual void OnHeroCanBeSelectedInInventoryInfoIsRequested(Hero hero, ref bool result)

Parameters

hero Hero
result bool

OnHeroCanBecomePrisonerInfoIsRequested(Hero, ref bool)

public virtual void OnHeroCanBecomePrisonerInfoIsRequested(Hero hero, ref bool result)

Parameters

hero Hero
result bool

OnHeroCanDieInfoIsRequested(Hero, KillCharacterActionDetail, ref bool)

public virtual void OnHeroCanDieInfoIsRequested(Hero hero, KillCharacterAction.KillCharacterActionDetail causeOfDeath, ref bool result)

Parameters

hero Hero
causeOfDeath KillCharacterAction.KillCharacterActionDetail
result bool

OnHeroCanHavePartyRoleOrBeGovernorInfoIsRequested(Hero, ref bool)

public virtual void OnHeroCanHavePartyRoleOrBeGovernorInfoIsRequested(Hero hero, ref bool result)

Parameters

hero Hero
result bool

OnHeroCanHaveQuestOrIssueInfoIsRequested(Hero, ref bool)

public virtual void OnHeroCanHaveQuestOrIssueInfoIsRequested(Hero hero, ref bool result)

Parameters

hero Hero
result bool

OnHeroCanLeadPartyInfoIsRequested(Hero, ref bool)

public virtual void OnHeroCanLeadPartyInfoIsRequested(Hero hero, ref bool result)

Parameters

hero Hero
result bool

OnHeroCanMarryInfoIsRequested(Hero, ref bool)

public virtual void OnHeroCanMarryInfoIsRequested(Hero hero, ref bool result)

Parameters

hero Hero
result bool

OnHeroCanMoveToSettlementInfoIsRequested(Hero, ref bool)

public virtual void OnHeroCanMoveToSettlementInfoIsRequested(Hero hero, ref bool result)

Parameters

hero Hero
result bool

OnStartQuest()

protected virtual void OnStartQuest()

OnTimedOut()

protected virtual void OnTimedOut()

QuestPreconditions()

public virtual bool QuestPreconditions()

Returns

bool

RegisterEvents()

protected virtual void RegisterEvents()

RemoveLog(JournalLog)

protected void RemoveLog(JournalLog logToRemove)

Parameters

logToRemove JournalLog

RemoveTrackedObject(ITrackableCampaignObject)

public void RemoveTrackedObject(ITrackableCampaignObject trackedObject)

Parameters

trackedObject ITrackableCampaignObject

SetDialogs()

protected abstract void SetDialogs()

StartQuest()

public void StartQuest()

ToString()

public override string ToString()

Returns

string

ToggleTrackedObjects()

public void ToggleTrackedObjects()

UpdateQuestTaskStage(JournalLog, int)

protected void UpdateQuestTaskStage(JournalLog questLog, int currentProgress)

Parameters

questLog JournalLog
currentProgress int

This page was last modified at 09/01/2024 16:12:00 +00:00 (UTC).