Page 1 of 1

Add LuaControl::open_factoriopedia_gui(prototype?)

Posted: Fri Mar 07, 2025 11:38 am
by sfyb
The mod I've been working on Factorio Codex gives players access to something similar to Satisfactory's quick search. Before the 2.0 update, I displayed information about items/fluids in my own GUI, but since Factoriopedia was added, I want to open that instead. However, Factoriopedia seems to be a black spot in the Factorio modding API.

Therefore I request a function similar to

Code: Select all

LuaControl::open_technology_gui(technology?)
in order to open Factoriopedia and display a specific Prototype. It would be great if anything that Factoriopedia can display could also be used in the API call to open it.

To implement this with minimal changes to the API (as far as I can tell) I would suggest following signature:

Code: Select all

LuaControl::open_factoriopedia_gui(prototype?)
where prototype can uniquely identify any prototype displayable in Factoriopedia (something like LuaPrototypeBase::name).

Re: Add LuaControl::open_factoriopedia_gui(prototype?)

Posted: Tue Mar 18, 2025 8:57 am
by zerwiport
+1

Re: Add LuaControl::open_factoriopedia_gui(prototype?)

Posted: Wed Mar 26, 2025 5:35 pm
by PennyJim
+1 Could be combined with a CustomInput bound to the open factoriopedia keybind to do some complex factoriopedia behavior.

I don't have any particular needs, but I do have ideas.
Like if you're reusing a common entity in a compound entity you can choose to open the entity that represents *that* compound entity instead of the useless page for the common entity.

I fear the repeated use of "entity" makes that less then intelligible, but the initial statement stands on its own I think.

Re: Add LuaControl::open_factoriopedia_gui(prototype?)

Posted: Sat Apr 05, 2025 1:01 am
by sOvr9000
+1
04-04-2025, 18-00-57.png
04-04-2025, 18-00-57.png (11.65 KiB) Viewed 447 times
to open the Factoriopedia to some item :)

Re: Add LuaControl::open_factoriopedia_gui(prototype?)

Posted: Sun Apr 06, 2025 7:13 pm
by Rseding91
Added for the next release.