> For the complete documentation index, see [llms.txt](https://bahnproductions.gitbook.io/bahnproductions-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://bahnproductions.gitbook.io/bahnproductions-docs/bahn-productions-ue-plugins/uncommon-nodes/combinearrays.md).

# CombineArrays

K2Node built as a compact node for combining arrays into a single output array variable using wildcard propagation. This is nondestructive to the initial input arrays, and can be valuable in certain scenarios.&#x20;

<figure><img src="/files/HS93tYc45HLnUecCSeIp" alt=""><figcaption></figcaption></figure>

### Test Case - AudioParameter Struct

<figure><img src="/files/9pCwpWJsJTCM8PSJ5Bmx" alt=""><figcaption></figcaption></figure>

### Test Case - Enum

<figure><img src="/files/6LttJGqRfquUrjEhS3ju" alt=""><figcaption></figcaption></figure>

Here we use 3 enum array variables:&#x20;

1. Initial Loadout (Axe, Sword)
2. Added Weapons (Rifle, Shotgun)
3. Award Weapon (Pistol)&#x20;

InitialLoadout and AddedWeapons are combined into a new array stored in NewTempLoadout. A second Combine then merges NewTempLoadout with AwardWeapon, and the result is stored back into NewTempLoadout. At the breakpoint, all 5 weapons are present in the correct order. All 3 original variables remain untouched with their initial values.&#x20;

For further proof, I added a series of enum to strings and delays at each point in a sequence. This shows the InitialLoadout, NewTempLoadout, NewTempLoadout (AwardWeapon added), and the initialLoadout remaining intact.&#x20;

<figure><img src="/files/25yMzfXr315O3n3CPMVN" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/DyE8xclUyWSnyQDNTtjb" alt=""><figcaption></figcaption></figure>
