[0.16.16] LuaPlayer::blueprint_to_setup invalid
Posted: Tue Jan 16, 2018 7:37 pm
When an area is selected with a blank blueprint while holding SHIFT to suppress display of the editing window, during the on_player_setup_blueprint event LuaPlayer::blueprint_to_setup is an invalid ItemStack.
The on_player_configured_blueprint event is also never fired, in sum giving mods no opportunity to adjust the contents of a blueprint created in this way.
Selecting without holding SHIFT works as expected.
Steps to repro:
1) setup script handler:
2) Drag-select entities with an empty blueprint while holding SHIFT.
3) Script displays "false", expected "true," with the ItemStack holding the blueprinted entities.
The on_player_configured_blueprint event is also never fired, in sum giving mods no opportunity to adjust the contents of a blueprint created in this way.
Selecting without holding SHIFT works as expected.
Steps to repro:
1) setup script handler:
Code: Select all
/c script.on_event(defines.events.on_player_setup_blueprint, function(e) game.print(serpent.line(game.players[e.player_index].blueprint_to_setup.valid_for_read)) end)
3) Script displays "false", expected "true," with the ItemStack holding the blueprinted entities.