[2.0.65] Script blueprinting destroys components in assembling machine

Bugs that are actually features.
FoxLBA
Burner Inserter
Burner Inserter
Posts: 13
Joined: Mon May 01, 2017 6:45 pm
Contact:

[2.0.65] Script blueprinting destroys components in assembling machine

Post by FoxLBA »

The following steps change the recipe in the assembling machine by applying the blueprint via script.

1)Load save file (I checked without mods):
script_blueprinting.zip
(829.26 KiB) Downloaded 12 times
2)Run script in console:

Code: Select all

/c game.blueprints[1].build_blueprint{surface=game.surfaces[1],force=game.forces["player"],position={0,0}}
The recipe has changed. The gears and circuits are missing in the assembling machine.

Expected behavior: Unneeded components are moved to the trash slots, just like when using a blueprint through a map.
Attachments
factorio-current.log
(6.29 KiB) Downloaded 11 times
Rseding91
Factorio Staff
Factorio Staff
Posts: 16050
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [2.0.65] Script blueprinting destroys components in assembling machine

Post by Rseding91 »

Thanks for the report however this isn't a bug. The transfer-to-trash only happens when a player does the action as it's based on the distance from the player to the entity when copying settings.
If you want to get ahold of me I'm almost always on Discord.
FoxLBA
Burner Inserter
Burner Inserter
Posts: 13
Joined: Mon May 01, 2017 6:45 pm
Contact:

Re: [2.0.65] Script blueprinting destroys components in assembling machine

Post by FoxLBA »

By "trash slots" I meant additional output slots:
assembler.png
assembler.png (48.17 KiB) Viewed 86 times
I expect that the items will not be lost when changing the recipe from using the script+blueprint.

The transfer-to-trash only happens when a player does the action as it's based on the distance from the player to the entity when copying settings.
In my opinion, the distance has nothing to do with it...


Here is another save with a similar setup (the difference is that there is a character next to the assembling machine):
script_blueprinting2.zip
(981.88 KiB) Downloaded 10 times
(Load the save before each test!)
Test 1: Take a blueprint from the map blueprint library in your hand and use it on an assembling machine.
Result: items that do not fit are moved to the character's inventory.

Test 2: Take a blueprint from the map blueprint library in your hand and use it on an assembling machine via the map view.
Result: items that do not fit are moved to the additional output slots in assembling machine (screenshot above).

Test 3: Run the script (from the first message) that uses a blueprint from the map blueprint library.
Result: items that do not fit are lost.
Post Reply

Return to “Not a bug”