Picker Inventory Tools

by Nexela

Quick Inventory filtering and sorting

2 years ago
0.17 - 1.1
9.68K

b new game startup crashes

1 year, 5 months ago

The mod Project Cybersyn (1.2.15) caused a non-recoverable error.
Please report this error to the mod author.

Error while running event cybersyn::on_init()
The mod Picker Inventory Tools (1.1.15) caused a non-recoverable error.
Please report this error to the mod author.

Error while running event PickerInventoryTools::on_runtime_mod_setting_changed (ID 61)
stdlib/stdlib/event/event.lua:368: PickerInventoryTools/scripts/item-count.lua:43: bad argument #3 of 3 to 'index' (string expected, got nil)
stack traceback:
[C]: in function 'error'
__stdlib/stdlib/event/event.lua:368: in function 'dispatch_event'
stdlib/stdlib/event/event.lua:438: in function <stdlib/stdlib/event/event.lua:396>
stack traceback:
[C]: in function 'newindex'
__cybersyn/scripts/main.lua:940: in function <cybersyn/scripts/main.lua:937>

10 months ago

Changing update_item_count_settings in scripts/item-count.lua to this fixes it, but I'm not sure if that breaks anything else, I have no idea about factorio modding.

local function update_item_count_settings(event)
if event.player_index ~= nil then
local player = game.players[event.player_index]
if event.setting == 'picker-item-count' then
local enabled = player.mod_settings['picker-item-count'].value
local gui = get_or_create_itemcount_gui(player)
gui.visible = enabled and player.cursor_stack.valid_for_read or false
end
end
end

New response