https://lua-api.factorio.com/latest/Lua ... r_crafting
It does not actually work. To hide recipe from handcrafting menu you need to use hide[instead of hidden]_from_player_crafting, but in the documentation only "hidden", which destoyed my mental health just for 20 minutes. Fix it please, I worry about the psyche of my colleagues
LuaRecipePrototype.hidden_from_player_crafting
Re: Small documentation improvement requests
The doc tells already that hidden_from_flow_stats is read only, you are mixing scripting with prototype creation. Check out https://lua-api.factorio.com/latest/Data-Lifecycle.html and https://wiki.factorio.com/Prototype_overview.detnac wrote: ↑Wed Jan 12, 2022 8:42 pmhttps://lua-api.factorio.com/latest/Lua ... r_crafting
It does not actually work. To hide recipe from handcrafting menu you need to use hide[instead of hidden]_from_player_crafting, but in the documentation only "hidden", which destoyed my mental health just for 20 minutes. Fix it please, I worry about the psyche of my colleagues
Re: LuaRecipePrototype.hidden_from_player_crafting
How can I hide it?
Re: LuaRecipePrototype.hidden_from_player_crafting
You must set the recipe to be hidden when the prototype is defined in the Data stage. It cannot be changed at runtime.
https://wiki.factorio.com/Prototype/Recipe
https://wiki.factorio.com/Prototype/Recipe
My mods: Multiple Unit Train Control, Smart Artillery Wagons
Maintainer of Vehicle Wagon 2, Cargo Ships, Honk
Maintainer of Vehicle Wagon 2, Cargo Ships, Honk
Re: LuaRecipePrototype.hidden_from_player_crafting
If I set hidden = true, it will not be displayed in the machine. I just want to hide it from the player, and the machine can chooserobot256 wrote: ↑Mon Apr 04, 2022 11:28 amYou must set the recipe to be hidden when the prototype is defined in the Data stage. It cannot be changed at runtime.
https://wiki.factorio.com/Prototype/Recipe
Re: LuaRecipePrototype.hidden_from_player_crafting
The very next line is "hide_from_player_crafting". This is the name in the data stage, when it is writable. In the control stage it becomes "hidden_from_player_crafting", when it is read-only.
https://wiki.factorio.com/Prototype/Rec ... r_crafting
https://wiki.factorio.com/Prototype/Rec ... r_crafting
My mods: Multiple Unit Train Control, Smart Artillery Wagons
Maintainer of Vehicle Wagon 2, Cargo Ships, Honk
Maintainer of Vehicle Wagon 2, Cargo Ships, Honk
Re: LuaRecipePrototype.hidden_from_player_crafting
My God, I finally understandrobot256 wrote: ↑Mon Apr 04, 2022 11:44 amThe very next line is "hide_from_player_crafting". This is the name in the data stage, when it is writable. In the control stage it becomes "hidden_from_player_crafting", when it is read-only.
https://wiki.factorio.com/Prototype/Rec ... r_crafting
Should be: hidden = false,
hide_ from_ player_ crafting = true,
Thank you, my friend.
Re: LuaRecipePrototype.hidden_from_player_crafting
You are very welcome!
My mods: Multiple Unit Train Control, Smart Artillery Wagons
Maintainer of Vehicle Wagon 2, Cargo Ships, Honk
Maintainer of Vehicle Wagon 2, Cargo Ships, Honk