-
Notifications
You must be signed in to change notification settings - Fork 37
Multi Verb Combat Framework
Multi Verb Combat Framework (MVCF) enables pawns to use ranged attacks provided by hediffs, apparel, and their race. In addition, it provides many unique features for additional flexibility in defining your attacks.
The first thing you have to do to use MVCF is create a MVCF mod definition. In some def file in your mod, add a MVCF.ModDef
, and enter a defName
, label
, and description
. defName
must be unique to your mod, and the other two do not matter, they just must not be empty. None of these fields will ever be shown to the player. Next, add a ActivateFeatures
tag, which will be filled as you develop. Whenever this documentation mentions "You must enable the SomeFeatureHere
feature in your ModDef
", it means you need to add SomeFeatureHere
as a list item inside ActivateFeatures
. For example, here's a mod def enabling the RangedAnimals
, HediffVerbs
, and IntegratedToggle
features: (Credit to Sarg)
<MVCF.ModDef>
<defName>AA_AlphaAnimals</defName>
<label>Alpha Animals</label>
<description>Adding animal ranged attacks for Alpha Animals creatures</description>
<ActivateFeatures>
<li>RangedAnimals</li>
<li>HediffVerbs</li>
<li>IntegratedToggle</li>
</ActivateFeatures>
</MVCF.ModDef>
How you go about adding the verbs depends on what you want to add them to.
With Apparel, put the verbs in the verbs
field of the ThingDef
, then add MVCF.Comps.CompProperties_VerbGiver
to its comps
. This requires enabling the feature ApparelVerbs
in your ModDef
.
Now, HediffDef
doesn't have a verbs
field, so you need to put the verbs in the comp itself. Add a HediffCompProperties_VerbGiver
to the comps
and then put your verbs in the verbs
field of it. This requires enabling the feature HediffVerbs
in your ModDef
. If these hediffs may be applied to an animal, you also need to enable the RangedAnimals
and IntegratedToggle
features.
Another thing MVCF allows is a weapon that has more than one ranged attacks. To use this feature, simply add more verbs to the verbs
field or your weapon's ThingDef
. This requires enabling the feature ExtraEquipmentVerbs
in your ModDef
.
To have a pawn's race give them a ranged attack, simple add a verbs
field to the pawn's race's ThingDef
. If you are adding these to an animal, you need to enable the RangedAnimals
and IntegratedToggle
features.
Want to customize your verbs even more? You need to provide AdditionalVerbProps
. How you do this depends on how you provided the verbs. All the verbProps
fields here are lists of the class AdditionalVerbProps
.
Simply add a verbProps
field to your VerbGiver
comp.
Switch HediffCompProperties_VerbGiver
to MVCF.Comps.HediffCompProperties_ExtendedVerbGiver
and add a verbProps
field.
Switch the li
in comps
with compClass
of CompEquippable
to have a Class
of MVCF.Comps.CompProperties_VerbProps
, then add a verbProps
field. Or, you can give them a new comp of type MVCF.Comps.Comp_VerbProps
, with properties of MVCF.Comps.CompProperties_VerbProps
.
One unique feature of MVCF is the ability to give ranged attacks to melee weapons, and have them still considered melee. This is useful if you want extra abilities on your spear or axe or whatever. To do this, provide <ConsiderMelee>true</ConsiderMelee>
as a sibling node to the verbProps
for your weapon.
Verbs on animals with no props will always be togglable. That being said, you can provide them with some by giving the pawn a Comp_VerbProps
.
- QuestNode_GetFaction
- Expandable projectiles
- Faction Def Extension
- Toggable patches
- Recipes Inheritance
- Adding new backstories
- Spawning things on new generated maps
- ThoughtExtensions
- WeatherLetterExtensions
- WeatherOverlayExtension
- WeatherEffectsExtension
- ThingDefExtension
- Stuff commonality extension
- Biome extension
- PipeSystem basics
- Resource
- Resource storage
- Resource processor
- Resource to thing
- Resource to power
- Thing to resource
- Resource trader
- Refill building with pipes
- Pipe valve
- Update to KCSG 2.0
- Exporting buildings
- Customizing symbols
- Debug helpers options
- Custom faction settlement
- Custom structure and scenarios
- Custom structure in quests
- Custom structure in WorldObjects
- Biome based structures
- Spawning world object(s) at world generation
- Prevent settlement spawning for nomadic factions
- Animal Behaviours Basics
-
Animal Behaviours Comp Classes
- Acid Attacks and Acid Immunity
- Animal Resources
- Animal Resources On Caravan
- Apply Hediff When Bound
- Asexual Reproduction
- Auto Nutrition
- Blink
- Build Periodically
- Cause Incident
- Change Def if Not Unique
- Change Weather
- Corpse Decayer
- Destroy This Item
- Die After Period
- Die And Change Into Another Def
- Dig Periodically
- Dig When Hungry
- Disease Event Immunity
- Disease Immunity
- Diseases After Period
- Doesn't flee
- Draftability
- Drop on Death
- Eat Weird Food
- Electrified
- Enrage Other Pawns
- Exploding Hatcher
- Extreme Xenophobia
- Fertilizer
- Filth Producer
- Fixed Gender
- Floating
- Gas Producer
- Give Thoughts On Caravan
- Graphic by Style
- Graphic by Terrain
- Hediff Effecter
- Hediff When Fleeing
- Highly Flammable
- Infecter
- Initial Ability
- Initial Hediff
- Initial Mental State
- Last Stand
- Light Sustenance
- Metamorphosis
- Mind Effecter
- Nearby Effecter
- No Taming Decay
- Passive Regenerator
- Pawn Overlay
- Produces no filth
- Refueling
- Regeneration
- State After Health Loss
- Summon On Spawn
- Swallow Whole
- Thought Effecter
- Untameable
- Animal Behaviours Hediff Comp Classes
- Animal Behaviours Damage Workers
- Animal Behaviours Def Extensions
- Animal Behaviours Extra Defs
- Animal Behaviours Misc