Provide a way to clear LuaPlayer::entity_copy_source
Posted: Sat Feb 07, 2026 7:05 pm
entity_copy_source is the entity that the player last used Shift+Right-click on to copy its settings. A function to clear this property (i.e. set it back to nil) would be very nice, if not direct write access.
The motivation for this is my mod Compact Recipe Pins which allows you to create GUI pins of recipes, and then copy/paste those recipes from the pin into the machine.
To do this, I overload the controls for the standard copy/paste to create a control scheme that's obvious to the user, but this ends up conflicting with the standard copy behaviour, and I've had to employ numerous workarounds.
Obviously I could just solve it all by using different controls, but that's not what I'm looking to hear.
The motivation for this is my mod Compact Recipe Pins which allows you to create GUI pins of recipes, and then copy/paste those recipes from the pin into the machine.
To do this, I overload the controls for the standard copy/paste to create a control scheme that's obvious to the user, but this ends up conflicting with the standard copy behaviour, and I've had to employ numerous workarounds.
Obviously I could just solve it all by using different controls, but that's not what I'm looking to hear.