Booktorio deprecated


Deprecated in favor of the built-in Tips and Tricks interface.

Tweaks
3 years ago
0.18 - 1.1
620

g Thumbs up

3 years ago

This is a very practical mod you made here, not very complicated for modders to use and very helpful for users in-game. I included a hopefully helpful wiki in my AircraftDrones mod, which looks really nice in my opinion.
So thank you and: see title ;)

I have two questions though that I wasn't able to solve with the instructions or the example mod.
1. Can I write text next to images?

2. Can I control the empty lines between the different elements?
As you in the screenshot it's not consistent, this is all with the default style - I didn't find out how to create/edit the styles.

Regards,
IngoKnieto

Linver β˜†
3 years ago

Teorically I can add this feature, but I fear the GUIs, because padding and margin in Factorio are magical!

Try to implement it ur self first, and let see the result.
U can use this:

2.9 TopicPlugin

Show a plugin, created by a function that must be given to Booktorio via some remote method. One way to implement this is give a file with a function returned, another way is specify a remote to use. Both (functions and remotes) should accept only one argument, a flow gui element, to use like parent(root) add inside of it custom gui elements. Warning! Remember that Booktorio is designed to create wikis, so all interfaces are stateless, don't use plugins to create gui elements that must remain loaded in times, also don't create plugin functions that have problem to run two time in the same savegame/map.
- type :: string (mandatory)
- path :: string (optional)
- remote_name :: string (optional)
- remote_function :: string (optional)
- style :: string (optional)

Mandatory values
- type, is the type of this element, in this case must be "plugin".

Optional values
- path, mandatory if remote_name and remote_function are not given, is a path of a mod file that return one function that add some gui element/s to the flow that the function must accept in the arguments.
- remote_name, mandatory if path is not given, is the name the interface that contain the remote function that add some gui element/s to the flow that the function must accept in the arguments.
- remote_function, mandatory if path is not given, is the spefied function name of the remote inteface that add some gui element/s to the flow that the function must accept in the arguments.
- style, the name of the style to apply on the flow element given to the plugin function, if not given will be used the standard Booktorio style.

All TopicTitle, TopicSubtitle, TopicText, TopicImage, TopicPlugin, support pair definition, for exame this two are equivalent forms:

    {type = "text", text = "gui.bk-ex-description-1"}
    {"text", "gui.bk-ex-description-1"}

Only if have the two main mandatory values defined.

New response