Shortcuts


Adds a host of useful shortcuts to improve QOL. Shortcuts for the artillery remote, discharge defense remote, tree deconstructor, and toggles for equipment, rail blocks and the player lamp. Also adds in a customizable grid overlay, far zoom and an artillery wagon toggle shortcut. See mod portal FAQ page for a full list of shortcuts and supported mods.

Utilities
4 years ago
0.17
24

b Crash when equipping modded armor

4 years ago
(updated 4 years ago)

Trying to update the 'Iron Man' armor set mod to be compatible with the latest version of 0.17. Game loads things in just fine but when I equip it I get an error with your mod:

Error while running event
Shortcuts::on_player_armor_inventory_changed(ID 35) real number expected got nil.
stack traceback:
Shortcuts/control.lua:13: in function 'update_armor'
Shortcuts/control.lua:157: in function 'reset_state'
Shortcuts/control.lua:365: in function
<Shortcuts/control.lua:363>
stack traceback:
[C]: in function 'get_inventory'
Shortcuts/control.lua:13: in function 'update_armor'
Shortcuts/control.lua:157: in function 'reset_state'
Shortcuts/control.lua:365: in function
<Shortcuts/control.lua:363>

If there's something I can do to the mod I'm trying to fix then let me know otherwise I'll have to disable yours until it's fixed :(

4 years ago

This is due to some mod-breaking API changes in 0.17.35. It's a simple fix on the mod author's part, just needs to rename some events and prototypes.

4 years ago

Ah okay, glad to hear it wasn't something to do with what I was doing XD
Thanks for the quick reply.

4 years ago

Its not just with modded armor. I also had a simelar error with the vanilla modular armor

De modificatie Shortcuts heeft een niet-herstelbare fout veroorzaakt.
Rapporteer deze a.u.b. bij de auteur van de modificatie.

Error while running event Shortcuts::on_player_armor_inventory_changed (ID 35)
real number expected got nil.
stack traceback:
Shortcuts/control.lua:13: in function 'update_armor'
Shortcuts/control.lua:157: in function 'reset_state'
Shortcuts/control.lua:365: in function <Shortcuts/control.lua:363>
stack traceback:
[C]: in function 'get_inventory'
Shortcuts/control.lua:13: in function 'update_armor'
Shortcuts/control.lua:157: in function 'reset_state'
Shortcuts/control.lua:365: in function <Shortcuts/control.lua:363>

4 years ago

I have got the same error while clicking in normal armor, not even a modular onde

The mod Shortcuts caused a non-recoverable error.
Please report this error to the mod author.

Error while running event Shortcuts::on_player_armor_inventory_changed (ID 35)
real number expected got nil.
stack traceback:
Shortcuts/control.lua:13: in function 'update_armor'
Shortcuts/control.lua:157: in function 'reset_state'
Shortcuts/control.lua:365: in function <Shortcuts/control.lua:363>
stack traceback:
[C]: in function 'get_inventory'
Shortcuts/control.lua:13: in function 'update_armor'
Shortcuts/control.lua:157: in function 'reset_state'
Shortcuts/control.lua:365: in function <Shortcuts/control.lua:363>

4 years ago

will have to wait for a fix!

4 years ago

control.lua
13:local power_armor = player.get_inventory(defines.inventory.player_armor)
to
13:local power_armor = player.get_inventory(defines.inventory.character_armor)

4 years ago

theoretically, replacing all instances of 'player' with 'character' should do it, but it's not that simple it appears.

4 years ago

Mernom, what broke when you tried Slon96' fix?

4 years ago

Hello, apologies for the delay.
I see that 0.17.35 has made the player/character naming more consistent
Will be releasing a fix for this

New response