# ResourceContainerAdder

`ResourceContainerAdder` adds one or more resource-container definitions to a variant and reinitializes the stock resource-capacity module in the OAB.

## Purpose

Use this transformer when a variant changes the resources a part can store. Typical uses include alternate tank loadouts, optional built-in monopropellant, or visual variants that also change stored resource definitions.

## Type

Source-backed runtime type: `VSwift.Modules.Transformers.ResourceContainerAdder`

## Fields

* `Containers`: `List<ContainedResourceDefinition>`

## Behavior

* `ApplyCommon`: no effect
* `ApplyInOab`: converts each `ContainedResourceDefinition` into a stock `ResourceContainer`, appends it to the OAB part's container list, and then shuts down and reinitializes `Module_ResourceCapacities`
* `ApplyInFlight`: currently no effect

## State handling

* Reverter: yes, via `ResourceContainerReverter.Instance`
* Saves information: yes, through `ResourceContainerLoader`
* Visualizes information: flagged as yes by the transformer

## Example

This fragment shows the real top-level V-SwiFT field names. The inner `ContainedResourceDefinition` payload uses the stock KSP2 resource-definition structure.

```patch
Transformers: [
  {
    Name: "ResourceContainerAdder",
    Containers: [
      { ... }
    ]
  }
]
```

## Caveats

* The current implementation is OAB-focused and does not implement an in-flight application path.
* After modifying containers, V-SwiFT explicitly rebuilds and reinitializes `Module_ResourceCapacities`. That makes this transformer more invasive than a simple data append.
* The class advertises `VisualizesInformation = true`, but the source file does not currently define a custom stat-block renderer of its own.

## Related

* [ResourceContainerRemover](https://docs.ksp2redux.org/doc/resourcecontainerremover-Odx0MAUn6I)
* [Module_ResourceCapacities](https://docs.ksp2redux.org/doc/module_resourcecapacities-qa9eCws56E)
* [Resource Containers](https://docs.ksp2redux.org/doc/resource-containers-GdCYofMOyE)