Skip to content

Inventory - Types/Weightinv

This page documents the hooks defined by the types/weightinv submodule in the inventory module.


GetInventoryMaxWeight(inventory, maxWeight)View Source

Purpose

Allows code to override the computed maximum carry weight for a weight inventory.

Realm

Shared

Parameters

table inventory The inventory whose maximum weight is being calculated.

number maxWeight The default maximum weight before overrides are applied.

Returns

number|nil Return a replacement max weight to override the default value.