Source-checkedQuality of life & UI

Configurable Stack Size (Lua)

by nozwock · for Barotrauma

Configure the stack size of any in-game item via an editable config file. The 63-stack size limit is removed in Singleplayer but remains in Multiplayer. By default: Stackable "smallitems" have a…

2.6KDownloads
22 mo agoLast updated
Steam WorkshopSource

About Configurable Stack Size (Lua)

From Steam Workshop

Configure the stack size of any in-game item via an editable config file. The 63-stack size limit is removed in Singleplayer but remains in Multiplayer. By default: Stackable "smallitems" have a…

Configure the stack size of any in-game item via an editable config file. The 63-stack size limit is removed in Singleplayer but remains in Multiplayer. By default:

  • Stackable "smallitems" have a stack size of 64 (32 in player inventory).
  • Items like O2/fuel tanks remain unstackable in player inventory but stack to 64 elsewhere.
  • Ammo and battery stacks are doubled in player inventory (e.g., 24 revolver rounds instead of 12).

All defaults are customizable in the config file.

Requirements

Configuration

Launch the game once with the mod enabled to generate the default config in the "Barotrauma/ModConfigs/ConfigurableStackSize/" directory. "Barotrauma" refers to the folder where your save files are stored.

The configuration file is initially minified. It's recommended to format it with an auto-formatter before making modifications.

In Multiplayer, only the host’s configuration is used and synced to players.

Format


"itemPatches": [
    {
        "applyOnlyToStackables": false,
        "tags": [ "mobilebattery", "handheldammo" ],
        "operations": [
            { "key": "MaxStackSize", "operation": "=", "value": "{maxStackSize}" },
            { "key": "MaxStackSizeCharacterInventory", "operation": "*", "value": 2 },
        ]
    }
],
"containerOptions": {
    "maxStackSize": 64,
    "characterInventoryCapacity": 32,
}

The configuration uses "itemPatches" to define stack size rules based on tags or item IDs. Items are matched in top-down order, applying the operations of the first matching patch.

Each item has three stack sizes: general, player inventory, and mobile containers. Operations modify these sizes using numbers or references to container options like "{maxStackSize}".

The "containerOptions" section sets general stack size limits for different container types. For example, "maxStackSize" applies to containers that don't fall under other specific container groups. Customize these limits as needed in the config file.

If "applyOnlyToStackables" is not specified, it defaults to true.

Refer to the config file for more details.

Note:

  • I plan to add an UI to edit item stack size in-game instead of having to go through the config file.

Highlights

From source data

Footprint

Rated a light load on a server.

Last update

Its author last shipped an update 22 mo ago.

Configurable Stack Size (Lua) on Nxeon

From our catalogue
One-click install
Not available. One-click install isn't available for this game's mods yet. Download it and upload it to your server in Files.
Server load
light
Smallest plan we suggest
Barotrauma — 2 GB (2 GB RAM). This follows our own load rating above, not a benchmark.
Latest build
2025-01-09, released 2025-01-09

Game versions by loader

LoaderGame versionsNewest
Workshop

From 1 recorded build of Configurable Stack Size (Lua).

Dependencies

Declared by the newest build that lists any. Required ones are installed with it on one-click installs.

Run Configurable Stack Size (Lua) on a Barotrauma server

Deploy a server above, then upload the file in Files.

What kind of mod it is

From the catalog
Listed on Steam Workshop as “Workshop”

Quality of life & UI

Small conveniences, tweaks and interface improvements players notice straight away.

Compatibility

Game
Barotrauma

Verified at the source

  • ✓Steam WorkshopOfficial listing, checked 2026-10-10Open ↗
  • ✓Authornozwock, as published on Steam Workshop
  • ✓LicenseNot published by the sourceFree

Configurable Stack Size (Lua), answered

Generated from the mod’s own source data.

Is it free?

Yes. Configurable Stack Size (Lua) is free to download from Steam Workshop.

How do I add it to my Nxeon server?

One-click install isn't available for this game's mods yet. Download Configurable Stack Size (Lua) from Steam Workshop and upload it to your Nxeon Barotrauma server in Files.

NxLabs

Run Configurable Stack Size (Lua) on a Barotrauma server.

Deploy in about a minute from $4.99 a month, then upload Configurable Stack Size (Lua) in Files.