Skip to content

ChangeInventorySizeAction ​

Inherits: PlayerEventAction < EventAction < Resource

Action that makes the bag of player(s) bigger (or smaller) for good: more slots, more carry capacity. A bigger backpack as the reward of a quest, a pouch bought from a smith. What the stats give (Bag Slots, Carry Capacity) is changed with effects and equipment; this is on top of it and is saved.

Properties ​

intslots4
floatcapacity0.0

Methods ​

Stringget_player_function_description()
boolexecute_on_players( players: Array[Player] )
Dictionarysave()
voidload_data( data: Dictionary )

Property descriptions ​

int slots = 4 ​

Slots to add (a negative number takes slots away). In a grid, one slot is one row

float capacity = 0.0 ​

Carry capacity to add (a negative number takes it away). It only matters when the inventory style counts weight

Method descriptions ​

String get_player_function_description() ​

Override to provide action-specific description

bool execute_on_players( players: Array[Player] ) ​

Execute action on target players

Dictionary save() ​

Save action state to a dictionary

void load_data( data: Dictionary ) ​

Load action state from a dictionary