Class BaseQuestConfigurator<T, TBuilder>
Implements common fields and components for blueprints inheriting from Kingmaker.Blueprints.Quests.BlueprintQuest.
Inheritance
Inherited Members
Namespace: BlueprintCore.Blueprints.Configurators.Quests
Assembly: BlueprintCore.dll
Syntax
public abstract class BaseQuestConfigurator<T, TBuilder> : BaseFactConfigurator<T, TBuilder> where T : BlueprintQuest where TBuilder : BaseQuestConfigurator<T, TBuilder>
Type Parameters
Name | Description |
---|---|
T | |
TBuilder |
Remarks
Each supported blueprint type has a corresponding Configurator
class to create and modify blueprints of
that type, e.g. FeatureConfigurator supports BlueprintFeature
. Configurators exist for all
blueprint types inheriting from Kingmaker.Blueprints.BlueprintScriptableObject, excluding any that are not used in the
base game.
Creating a Blueprint
Use New(string, string)
to create a blueprint:
FeatureConfigurator.New(MyBlueprintName, MyBlueprintGuid)
Once New()
is called the blueprint is added to the game library and can be referenced.
Using the Configurator
New()
returns a configurator with methods to set or modify blueprint fields and add or modify
Kingmaker.Blueprints.BlueprintComponent:
FeatureConfigurator.New(MyBlueprintName, MyBlueprintGuid).AddToGroups(FeatureGroup.Feat).AddPrerequisiteAlignment(AlignmentMaskType.LawfulGood).Configure();
Each method call returns the configurator allowing you to chain calls. Nothing is modified on the blueprint until
Configure()
is called, at which point the changes are applied and validated. Potential problems with the
blueprint are logged as warnings.
Modifying an Existing Blueprint
Use For(Blueprint)
to modify existing blueprints:
CharacterClassConfigurator.For(WizardClassGuid)
Usage is otherwise identical to creating a new blueprint.
For more information see Using BlueprintCore.
Constructors
| Improve this Doc View SourceBaseQuestConfigurator(Blueprint<BlueprintReference<T>>)
Declaration
protected BaseQuestConfigurator(Blueprint<BlueprintReference<T>> blueprint)
Parameters
Type | Name | Description |
---|---|---|
Blueprint<Kingmaker.Blueprints.BlueprintReference<T>> | blueprint |
Methods
| Improve this Doc View SourceAddExperience(IntEvaluator, Nullable<Int32>, Nullable<Boolean>, Nullable<EncounterType>, Action<BlueprintComponent, BlueprintComponent>, ComponentMerge, Nullable<Single>, Nullable<Boolean>)
Adds Kingmaker.Blueprints.Classes.Experience.Experience
Declaration
public TBuilder AddExperience(IntEvaluator count = null, int? cR = null, bool? dummy = null, EncounterType? encounter = null, Action<BlueprintComponent, BlueprintComponent> merge = null, ComponentMerge mergeBehavior = ComponentMerge.Fail, float? modifier = null, bool? playerGainsNoExp = null)
Parameters
Type | Name | Description |
---|---|---|
Kingmaker.ElementsSystem.IntEvaluator | count | |
System.Nullable<System.Int32> | cR | |
System.Nullable<System.Boolean> | dummy | |
System.Nullable<Kingmaker.Blueprints.Classes.Experience.EncounterType> | encounter | |
System.Action<Kingmaker.Blueprints.BlueprintComponent, Kingmaker.Blueprints.BlueprintComponent> | merge | If mergeBehavior is ComponentMerge.Merge and the component already exists, this expression is called to merge the components. |
ComponentMerge | mergeBehavior | Handling if the component already exists since the component is unique. Defaults to ComponentMerge.Fail. |
System.Nullable<System.Single> | modifier | |
System.Nullable<System.Boolean> | playerGainsNoExp | InfoBox: When true, Exp will be used in encounter CR calculation, but player will not gained it |
Returns
Type | Description |
---|---|
TBuilder |
Remarks
- 00_FindEchoLair876fc5d40aa5d8b47ac0138cf0a680ae
- DLC3_CR16_FaerieDragonHungryMagicSummon1f238fcbd1bb41cfbc35729a2d7c0d2c
- Ziforian_normal7ef2998dbeb7fda43a47ce842f4d142d
AddToObjectives(Blueprint<BlueprintQuestObjectiveReference>[])
Adds to the contents of Kingmaker.Blueprints.Quests.BlueprintQuest.m_Objectives
Declaration
public TBuilder AddToObjectives(params Blueprint<BlueprintQuestObjectiveReference>[] objectives)
Parameters
Type | Name | Description |
---|---|---|
Blueprint<Kingmaker.Blueprints.BlueprintQuestObjectiveReference>[] | objectives | Blueprint of type BlueprintQuestObjective. You can pass in the blueprint using:
|
Returns
Type | Description |
---|---|
TBuilder |
ClearObjectives()
Removes all elements from Kingmaker.Blueprints.Quests.BlueprintQuest.m_Objectives
Declaration
public TBuilder ClearObjectives()
Returns
Type | Description |
---|---|
TBuilder |
CopyFrom(Blueprint<BlueprintReference<BlueprintQuest>>, Predicate<BlueprintComponent>)
Copies fields and components of the specified types from the blueprint.
Declaration
public TBuilder CopyFrom(Blueprint<BlueprintReference<BlueprintQuest>> blueprint, Predicate<BlueprintComponent> componentMatcher)
Parameters
Type | Name | Description |
---|---|---|
Blueprint<Kingmaker.Blueprints.BlueprintReference<Kingmaker.Blueprints.Quests.BlueprintQuest>> | blueprint | |
System.Predicate<Kingmaker.Blueprints.BlueprintComponent> | componentMatcher | Any components in |
Returns
Type | Description |
---|---|
TBuilder |
Remarks
NOT A DEEP COPY. This means objects copied are shared between blueprints. Changes to copied objects affect both blueprints.
Recommended when you need to create a nearly identical ability but change some parts such as a
ContextRankConfig
.
// Copy the Undead Bloodline's Incorporeal Form ability, replacing the duration w/ Character Level rounds
AbilityConfigurator.New(NewIncorporealForm, Guids.NewIncorporealForm)
.CopyFrom(
AbilityRefs.BloodlineUndeadIncorporealFormAbility,
typeof(AbilityEffectRunAction),
typeof(AbilityResourceLogic),
typeof(SpellComponent))
.AddContextRankConfig(ContextRankConfigs.CharacterLevel())
.Configure();
CopyFrom(Blueprint<BlueprintReference<BlueprintQuest>>, Type[])
Copies fields and components of the specified types from the blueprint.
Declaration
public TBuilder CopyFrom(Blueprint<BlueprintReference<BlueprintQuest>> blueprint, params Type[] componentTypes)
Parameters
Type | Name | Description |
---|---|---|
Blueprint<Kingmaker.Blueprints.BlueprintReference<Kingmaker.Blueprints.Quests.BlueprintQuest>> | blueprint | |
System.Type[] | componentTypes | Any components in |
Returns
Type | Description |
---|---|
TBuilder |
Remarks
NOT A DEEP COPY. This means objects copied are shared between blueprints. Changes to copied objects affect both blueprints.
Recommended when you need to create a nearly identical ability but change some parts such as a
ContextRankConfig
.
// Copy the Undead Bloodline's Incorporeal Form ability, replacing the duration w/ Character Level rounds
AbilityConfigurator.New(NewIncorporealForm, Guids.NewIncorporealForm)
.CopyFrom(
AbilityRefs.BloodlineUndeadIncorporealFormAbility,
typeof(AbilityEffectRunAction),
typeof(AbilityResourceLogic),
typeof(SpellComponent))
.AddContextRankConfig(ContextRankConfigs.CharacterLevel())
.Configure();
ModifyCompletionText(Action<LocalizedString>)
Modifies Kingmaker.Blueprints.Quests.BlueprintQuest.CompletionText by invoking the provided action.
Declaration
public TBuilder ModifyCompletionText(Action<LocalizedString> action)
Parameters
Type | Name | Description |
---|---|---|
System.Action<Kingmaker.Localization.LocalizedString> | action |
Returns
Type | Description |
---|---|
TBuilder |
ModifyDescription(Action<LocalizedString>)
Modifies Kingmaker.Blueprints.Quests.BlueprintQuest.Description by invoking the provided action.
Declaration
public TBuilder ModifyDescription(Action<LocalizedString> action)
Parameters
Type | Name | Description |
---|---|---|
System.Action<Kingmaker.Localization.LocalizedString> | action |
Returns
Type | Description |
---|---|
TBuilder |
ModifyObjectives(Action<BlueprintQuestObjectiveReference>)
Modifies Kingmaker.Blueprints.Quests.BlueprintQuest.m_Objectives by invoking the provided action on each element.
Declaration
public TBuilder ModifyObjectives(Action<BlueprintQuestObjectiveReference> action)
Parameters
Type | Name | Description |
---|---|---|
System.Action<Kingmaker.Blueprints.BlueprintQuestObjectiveReference> | action |
Returns
Type | Description |
---|---|
TBuilder |
ModifyOnSetAutoKingdom(Action<ActionList>)
Modifies Kingmaker.Blueprints.Quests.BlueprintQuest.OnSetAutoKingdom by invoking the provided action.
Declaration
public TBuilder ModifyOnSetAutoKingdom(Action<ActionList> action)
Parameters
Type | Name | Description |
---|---|---|
System.Action<Kingmaker.ElementsSystem.ActionList> | action |
Returns
Type | Description |
---|---|
TBuilder |
ModifyTitle(Action<LocalizedString>)
Modifies Kingmaker.Blueprints.Quests.BlueprintQuest.Title by invoking the provided action.
Declaration
public TBuilder ModifyTitle(Action<LocalizedString> action)
Parameters
Type | Name | Description |
---|---|---|
System.Action<Kingmaker.Localization.LocalizedString> | action |
Returns
Type | Description |
---|---|
TBuilder |
OnConfigureCompleted()
Declaration
protected override void OnConfigureCompleted()
Overrides
RemoveFromObjectives(Blueprint<BlueprintQuestObjectiveReference>[])
Removes elements from Kingmaker.Blueprints.Quests.BlueprintQuest.m_Objectives
Declaration
public TBuilder RemoveFromObjectives(params Blueprint<BlueprintQuestObjectiveReference>[] objectives)
Parameters
Type | Name | Description |
---|---|---|
Blueprint<Kingmaker.Blueprints.BlueprintQuestObjectiveReference>[] | objectives | Blueprint of type BlueprintQuestObjective. You can pass in the blueprint using:
|
Returns
Type | Description |
---|---|
TBuilder |
RemoveFromObjectives(Func<BlueprintQuestObjectiveReference, Boolean>)
Removes elements from Kingmaker.Blueprints.Quests.BlueprintQuest.m_Objectives that match the provided predicate.
Declaration
public TBuilder RemoveFromObjectives(Func<BlueprintQuestObjectiveReference, bool> predicate)
Parameters
Type | Name | Description |
---|---|---|
System.Func<Kingmaker.Blueprints.BlueprintQuestObjectiveReference, System.Boolean> | predicate |
Returns
Type | Description |
---|---|
TBuilder |
SetCompletionText(LocalString)
Sets the value of Kingmaker.Blueprints.Quests.BlueprintQuest.CompletionText
Declaration
public TBuilder SetCompletionText(LocalString completionText)
Parameters
Type | Name | Description |
---|---|---|
LocalString | completionText | You can pass in the string using a LocalizedString or the Key to a LocalizedString. |
Returns
Type | Description |
---|---|
TBuilder |
SetDescription(LocalString)
Sets the value of Kingmaker.Blueprints.Quests.BlueprintQuest.Description
Declaration
public TBuilder SetDescription(LocalString description)
Parameters
Type | Name | Description |
---|---|---|
LocalString | description | You can pass in the string using a LocalizedString or the Key to a LocalizedString. |
Returns
Type | Description |
---|---|
TBuilder |
SetDescriptionPriority(Int32)
Sets the value of Kingmaker.Blueprints.Quests.BlueprintQuest.m_DescriptionPriority
Declaration
public TBuilder SetDescriptionPriority(int descriptionPriority)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | descriptionPriority |
Returns
Type | Description |
---|---|
TBuilder |
SetGroup(QuestGroupId)
Sets the value of Kingmaker.Blueprints.Quests.BlueprintQuest.m_Group
Declaration
public TBuilder SetGroup(QuestGroupId group)
Parameters
Type | Name | Description |
---|---|---|
Kingmaker.Enums.QuestGroupId | group |
Returns
Type | Description |
---|---|
TBuilder |
SetLastChapter(Int32)
Sets the value of Kingmaker.Blueprints.Quests.BlueprintQuest.m_LastChapter
Declaration
public TBuilder SetLastChapter(int lastChapter)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | lastChapter |
Returns
Type | Description |
---|---|
TBuilder |
SetObjectives(Blueprint<BlueprintQuestObjectiveReference>[])
Sets the value of Kingmaker.Blueprints.Quests.BlueprintQuest.m_Objectives
Declaration
public TBuilder SetObjectives(params Blueprint<BlueprintQuestObjectiveReference>[] objectives)
Parameters
Type | Name | Description |
---|---|---|
Blueprint<Kingmaker.Blueprints.BlueprintQuestObjectiveReference>[] | objectives | Blueprint of type BlueprintQuestObjective. You can pass in the blueprint using:
|
Returns
Type | Description |
---|---|
TBuilder |
SetOnSetAutoKingdom(ActionsBuilder)
Sets the value of Kingmaker.Blueprints.Quests.BlueprintQuest.OnSetAutoKingdom
Declaration
public TBuilder SetOnSetAutoKingdom(ActionsBuilder onSetAutoKingdom)
Parameters
Type | Name | Description |
---|---|---|
ActionsBuilder | onSetAutoKingdom |
Returns
Type | Description |
---|---|
TBuilder |
SetQuestMarkerColorType(QuestMarkerColors.QuestMarkerColorType)
Sets the value of Kingmaker.Blueprints.Quests.BlueprintQuest.m_QuestMarkerColorType
Declaration
public TBuilder SetQuestMarkerColorType(QuestMarkerColors.QuestMarkerColorType questMarkerColorType)
Parameters
Type | Name | Description |
---|---|---|
Kingmaker.Blueprints.Root.QuestMarkerColors.QuestMarkerColorType | questMarkerColorType |
Returns
Type | Description |
---|---|
TBuilder |
SetTitle(LocalString)
Sets the value of Kingmaker.Blueprints.Quests.BlueprintQuest.Title
Declaration
public TBuilder SetTitle(LocalString title)
Parameters
Type | Name | Description |
---|---|---|
LocalString | title | You can pass in the string using a LocalizedString or the Key to a LocalizedString. |
Returns
Type | Description |
---|---|
TBuilder |
SetType(QuestType)
Sets the value of Kingmaker.Blueprints.Quests.BlueprintQuest.m_Type
Declaration
public TBuilder SetType(QuestType type)
Parameters
Type | Name | Description |
---|---|---|
Kingmaker.Enums.QuestType | type |
Returns
Type | Description |
---|---|
TBuilder |