Verb Comps - Vanilla-Expanded/VanillaExpandedFramework GitHub Wiki
Verb comps add additional features to verbs, mainly drawing, acting like turrets, or reloading.
Drawing is done with MVCF.VerbComps.VerbCompProperties_Draw
, and then the compClass
set to MVCF.VerbComps.VerbComp_Draw
. This requires the Drawing
feature. The properties have these fields:
Provides a graphic, used for two things: 1. If draw
is true
, this is what will be drawn, and 2. this is used as an icon for the verb's gizmo. For more information, see Verb Icon Strategy.
List of draw positions to use. This is explained in More Details.
If the owner doesn't match any defNames
from specificPositions
, then this DrawPosition
is used.
How much to scale the icon when drawing. Only used if draw
is true.
Specific scalings to use. This is explained in More Details.
If true, pawns that do not match any specific defName
in scalings
and/or specificPositions
will search for the ones with a defName
of Human
. Useful to support modded races easily.
Independent Fire is done with MVCF.VerbComps.VerbCompProperties_Turret
, and the compClass
must be MVCF.VerbComps.VerbComp_Turret
. This requires the IndependentFire
feature. It has all the fields of VerbCompProperties_Draw
, and these:
If true, then do not draw. This is for if you want a turret verb with no graphic.
If true, then it forces this verb to choose a different target from all the other verbs on the pawn.
Cooldowns are added with MVCF.VerbComps.VerbCompProperties_Cooldown
, and compClass
set to MVCF.VerbComps.VerbComp_Cooldown
. It also has these fields:
This sets the cooldown time in seconds.
Reloading is done with MVCF.Reloading.Comps.VerbCompProperties_Reloadable
, and compClass
set to MVCF.Reloading.Comps.VerbComp_Reloadable
. You can provide the following fields:
Number of items that are needed to reload each shot of the weapon.
Maximum number of shots that can be loaded in this weapon.
Number of seconds it takes to reload each shot of the weapon.
Replace the class of the targeted verb with the provided one. Used if you want to remove a Verb_ShootOneUse
, for example.
Sound to play when reloading the weapon.
If true, weapon will be loaded upon creation. Otherwise, it will be empty.
If true, then when a pawn is generated with this weapon, they will also be given a pistol or knife as a back-up.
When a pawn is generated with this weapon, these items will be added to their inventory.