Small documentation improvement requests

Place to ask discuss and request the modding support of Factorio. Don't request mods here.
curiosity
Fast Inserter
Fast Inserter
Posts: 113
Joined: Wed Sep 11, 2019 4:13 pm
Contact:

Re: Small documentation improvement requests

Post by curiosity »

https://wiki.factorio.com/Types/LightDefinition#type - the dependent property listing is inconsistent with other pages, where they are listed on the same level as the independent ones.

Pi-C
Smart Inserter
Smart Inserter
Posts: 1149
Joined: Sun Oct 14, 2018 8:13 am
Contact:

Re: Small documentation improvement requests

Post by Pi-C »

https://lua-api.factorio.com/latest/Con ... ventFilter:
Fields

filter
:: string

The condition to filter on. One of "type"
This looks incomplete -- perhaps somebody removed the rest of the sentence accidentally?
A good mod deserves a good changelog. Here's a tutorial (WIP) about Factorio's way too strict changelog syntax!

curiosity
Fast Inserter
Fast Inserter
Posts: 113
Joined: Wed Sep 11, 2019 4:13 pm
Contact:

Re: Small documentation improvement requests

Post by curiosity »

https://wiki.factorio.com/Types/SpriteFlags is in dire need of descriptions.

curiosity
Fast Inserter
Fast Inserter
Posts: 113
Joined: Wed Sep 11, 2019 4:13 pm
Contact:

Re: Small documentation improvement requests

Post by curiosity »

The wiki doesn't say the maximum number of prototypes for most prototypes so far as I can see.
-> It's listed on all prototypes where it matters (maximum number is 255 or less).

repne-scasb
Burner Inserter
Burner Inserter
Posts: 8
Joined: Sun Jan 09, 2022 1:18 pm
Contact:

Re: Small documentation improvement requests

Post by repne-scasb »

Bug: The new API docs lack enum value lists: viewtopic.php?f=7&t=101185
-> This was fixed.

curiosity
Fast Inserter
Fast Inserter
Posts: 113
Joined: Wed Sep 11, 2019 4:13 pm
Contact:

Re: Small documentation improvement requests

Post by curiosity »

https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.darkness doesn't say what the possible values interval is.

User avatar
jan1i3
Long Handed Inserter
Long Handed Inserter
Posts: 56
Joined: Sun Dec 09, 2018 1:36 pm
Contact:

Re: Small documentation improvement requests

Post by jan1i3 »

The description for `scroll_mode` for LuaGuiElement::scroll_to_item mentions "scroll-pane", contrary to the function's (correct) description saying "listbox".

The description for `scroll_mode` for `scroll_to_element` seems to be identical, it is correct in that case, just make sure to not break that one if they are shared.
Also known as JanSharp. jan1i3 was/is my old name ;)

curiosity
Fast Inserter
Fast Inserter
Posts: 113
Joined: Wed Sep 11, 2019 4:13 pm
Contact:

Re: Small documentation improvement requests

Post by curiosity »

Oh, all the "can only be used if" remarks are missing. This is a big degradation compared to the old docs.
Speaking of which:
jan1i3 wrote:
Mon Jan 10, 2022 4:44 pm
The description for `scroll_mode` for LuaGuiElement::scroll_to_item mentions "scroll-pane", contrary to the function's (correct) description saying "listbox".
This says (or, rather, would have said) "Can only be used if this is scroll-pane". So which is it, scroll pane in general or specifically listbox?

Pi-C
Smart Inserter
Smart Inserter
Posts: 1149
Joined: Sun Oct 14, 2018 8:13 am
Contact:

Re: Small documentation improvement requests

Post by Pi-C »

Class LuaEquipment

Code: Select all

An item in a LuaEquipmentGrid, for example one's power armor.
The role of the power armor is not really clear in this example: Is the armor the item that can be placed in the equipment grid, or is the armor the grid where other things can be placed in? I'd put it this way:

Code: Select all

An item in a LuaEquipmentGrid, for example a fusion reactor placed in one's power armor.
A good mod deserves a good changelog. Here's a tutorial (WIP) about Factorio's way too strict changelog syntax!

Honktown
Filter Inserter
Filter Inserter
Posts: 844
Joined: Thu Oct 03, 2019 7:10 am
Contact:

Re: Small documentation improvement requests

Post by Honktown »

Pi-C wrote:
Thu Jan 06, 2022 7:16 pm
https://lua-api.factorio.com/latest/Con ... ventFilter:
Fields

filter
:: string

The condition to filter on. One of "type"
This looks incomplete -- perhaps somebody removed the rest of the sentence accidentally?
That's the automation of the docs. If you look at the other filters, they have more than one type of filter, so 'one of "a" or "b"' makes sense. Logically the plural-ness could be split into two or three cases... one (first), two (first and last), and "many" (first, last, middles). -> one = "filter of type a", two = "filter of type a[,] or b", many = "filter of type a, [b, c, ...], or last
I have mods! I guess!
Link

Pi-C
Smart Inserter
Smart Inserter
Posts: 1149
Joined: Sun Oct 14, 2018 8:13 am
Contact:

Re: Small documentation improvement requests

Post by Pi-C »

Honktown wrote:
Thu Jan 13, 2022 2:07 pm
Pi-C wrote:
Thu Jan 06, 2022 7:16 pm
This looks incomplete -- perhaps somebody removed the rest of the sentence accidentally?
That's the automation of the docs. If you look at the other filters, they have more than one type of filter, so 'one of "a" or "b"' makes sense.
Makes sense, but still: The description looks incomplete, so it's rather confusing than helpful.
Logically the plural-ness could be split into two or three cases... one (first), two (first and last), and "many" (first, last, middles). -> one = "filter of type a", two = "filter of type a[,] or b", many = "filter of type a, [b, c, ...], or last
Agreed! Two cases (singular/plural) are necessary, three cases (1, 2, >2) would be even better. :-)
A good mod deserves a good changelog. Here's a tutorial (WIP) about Factorio's way too strict changelog syntax!

User avatar
JohnTheCF
Burner Inserter
Burner Inserter
Posts: 14
Joined: Thu Jun 22, 2017 7:15 pm
Contact:

Re: Small documentation improvement requests

Post by JohnTheCF »

https://wiki.factorio.com/Prototype/AutoplaceControl
you will not able to change it because gui wasn`t display it.
It shouldn't be "wasn't", probably "won't" or "will not"

-> Fixed the edit. Please keep in mind that the wiki can be edited by anyone, so some edits may not have the expected quality until they have been corrected by someone else. You are invited to do these corrections yourself.

User avatar
jan1i3
Long Handed Inserter
Long Handed Inserter
Posts: 56
Joined: Sun Dec 09, 2018 1:36 pm
Contact:

Re: Small documentation improvement requests

Post by jan1i3 »

LuaProfiler says "They can be used anywhere a LocalisedString is used." However there are 3 locations I found where LocalisedStrings are part of property trees causing this to not apply (meaning LuaProfilers are not usable). I'm pretty sure I've gone through and tested all data structures that can contain LocalisedStrings (since not all of them use property trees when parsing).

LuaSurface::create_entity (with "flying-text")
LuaGuiElement::add (lots of LocalisedStrings in here)
LuaEntity.add_market_item (with Offer with TechnologyModifier type "nothing" and effect_description)

Note that you can actually directly assign to the properties that take LocalisedStrings after creating the entity or gui element and it works (though it might not be the most intentional that it does, see link below). I don't think you can directly set the market offer's LocalisedString, so that's the only place where you truly can't use LuaProfilers, but that's also kind of ridiculous :D
And note that I only tested caption for LuaGuiElements, but I'm confident that the same applies to the others.

reference: viewtopic.php?p=560263#p560263
Also known as JanSharp. jan1i3 was/is my old name ;)

Honktown
Filter Inserter
Filter Inserter
Posts: 844
Joined: Thu Oct 03, 2019 7:10 am
Contact:

Re: Small documentation improvement requests

Post by Honktown »

Code: Select all

protected_from_tile_building
is missing from the wiki
Added EntityPrototype::protected_from_tile_building, true by default. If set to false - entity won't block tile mining/building (with `TilePrototype::check_collision_with_entities` enabled).
I have mods! I guess!
Link

Xorimuth
Filter Inserter
Filter Inserter
Posts: 354
Joined: Sat Mar 02, 2019 9:39 pm
Contact:

Re: Small documentation improvement requests

Post by Xorimuth »

https://lua-api.factorio.com/latest/Lua ... quest_path should point to CollisionMaskWithFlags, not just CollisionMask. There could be lots of instances of this.

https://lua-api.factorio.com/latest/Con ... kWithFlags should explain the flags or link to the explanations at https://wiki.factorio.com/Types/CollisionMask

Post Reply

Return to “Modding interface requests”