Package Description

Inventory+

If you want to buy me a coffee alt-text or if you want to support the original author with paypal to felix.mueller.86@web.de

A Foundry VTT module to enhance the dnd5e inventory. Allows to customize your Inventory in various ways, transfer items instead duplicate between character sheet, ordering the items, and many other feature hidden under the hood.

example

NOTE: If you are a javascript developer and not a typescript developer, you can just use the javascript files under the dist folder

NOTE: This module is under maintenance, I have no plans to update or add features. However, I will try to fix any bugs as possible. Any contribution is welcome.

Installation

It's always better and easier to install modules through in in app browser. Just search for "Mount Up!"

To install this module manually:

  1. Inside the Foundry "Configuration and Setup" screen, click "Add-on Modules"
  2. Click "Install Module"
  3. In the "Manifest URL" field, paste the following url: https://raw.githubusercontent.com/p4535992/inventory-plus/master/src/module.json
  4. Click 'Install' and wait for installation to complete
  5. Don't forget to enable the module in game using the "Manage Module" button

libWrapper

This module uses the libWrapper library for wrapping core methods. It is a hard dependency and it is recommended for the best experience and compatibility with other modules.

Details

This module allows you to create custom inventory categories and sort items into them and the default categories. You can also order the categories around and even disable weight tracking on a per category basis.

Features

Due to collisions, code maintenance problems, and reduction in the number of modules I have rewritten for the inherent use of the module some features of other modules, mentioned in the credits of this document. I invite you to support these authors in their various kofis and patreons. Each feature is non-blocking with the other modules and can be activated / deactivated from a specific module setting, which we list below

Feature: Enable item transfer: Know that you can temporarily disable the transfer feature by pressing the alt key while you move the item.

[Only with 'Feature: Enable item transfer' enabled] Enable currency transfer: When moving an object named "Currency" is transferer it will open a dialog to transfer money instead of transferring the actual item.",

[Only with 'Feature: Enable item transfer' enabled] Enable for actors of the same type: If disabled you will have to rely on the pairs you can define by hand.

[Only with 'Feature: Enable item transfer' enabled] Compatible Actor Types: The body of a JSON map of compatible actor type key-value pairs allowing transfer. By default this module only works between actor sheets of the same type, but some game systems may have other combinations that work. Example 1: "character":"synthetic","synthetic":"vehicles","vehicles":"character". Example 2 (for DnD5e): "character":"vehicle","vehicle":"character" that would enable moving item between characters and vehicles. You can also have multiple actor types as value, example 3: "character":["vehicle", "character"],"vehicle":"character" would enable transfer from character to vehicle, from character to character and from vehicle to character but NOT from vehicle to vehicle (providing that the "actors of the same type" checkbox is unchecked).",

Feature: Enable inventory sorter: Automatically sorts all actors' items (inventory, features, and spells) alphabetically (within each category).

Feature: Equipment Multiplier: Apply a weight multiplier to equipped items

[Only with 'Feature: Equipment Multiplier' enabled] Equipment Multiplier value: What weight multiplier to apply to equipped items

API

game.modules.get('inventory-plus').api.calculateWeightFromActor(actorIdOrName:string) ⇒ number

A method to calculate the weight (the one from the module filters) on the actor

Returnsnumber

Param Type Description Default
actorIdOrName string The actor id or name (if founded) undefined

game.modules.get('inventory-plus').api.calculateWeight(inventory: Category[], currency: number) ⇒ number

Returnsnumber

Param Type Description Default
inventory Category[] Array of categories undefined
currency number Total weigth currency undefined

game.modules.get('inventory-plus').api.isCategoryFulled(actor: Actor, categoryType: string, itemData:ItemData) ⇒ boolean

Returnsboolean

Param Type Description Default
actor Actor The actor undefined
categoryType string The id of the category undefined
itemData ItemData The item data to drop on the invetory with specific category type undefined

A method to calculate the weight (the one from the module filters) on inventory array and the current currency present on the actor

The Category object is represented like this:

{
  label: string;
  dataset: { type: string };
  sortFlag: number;
  ignoreWeight: boolean;
  maxWeight: number;
  ownWeight: number;
  collapsed: boolean;
  items: ItemData[];
}

Returnsnumber

Param Type Description Default
actorIdOrName string The actro id or name (if founded) undefined

 

Tagged Categories

  1. Actor and Item Sheets

Available Versions

  1. Version 0.1

  2. Version 0.2

  3. Version 0.3

  4. Version 0.3.1

  5. Version 0.3.2

  6. Version 0.3.3

  7. Version 0.3.4

  8. Version 0.3.5

  9. Version 0.5.0

  10. Version 0.5.1

  11. Version 0.5.3

  12. Version 0.5.6

  13. Version 0.5.9

  14. Version 0.5.11

  15. Version 0.5.18