Small documentation improvement requests
Small documentation improvement requests
Did you just run into a prototype property that was called pizza_type but didn't seem to do anything with pizzas at all and didn't have a description to tell you what it really does? Did you try to use a complicated method in the control stage but couldn't figure out how the format the doc describes should look like and there wasn't any example? We want to fix that :D
We are looking for properties/methods that are missing descriptions or could use examples in both the prototype docs and the runtime docs. We would like to prioritize our documentation efforts by what mod authors specifically run into or have problems with due to missing explanations/examples. Please post your requests in this thread.
Examples of the kind of requests we're looking for: 88004 89845
Examples of a recent improvement that we would like to repeat for other properties/methods: Added examples for LuaCommandProcessor.add_command and Types/LineTriggerItem
Please do not just say "most things in the prototype docs", we know and we'd like to prioritize working what you run into, instead of going alphabetically.
We are looking for properties/methods that are missing descriptions or could use examples in both the prototype docs and the runtime docs. We would like to prioritize our documentation efforts by what mod authors specifically run into or have problems with due to missing explanations/examples. Please post your requests in this thread.
Examples of the kind of requests we're looking for: 88004 89845
Examples of a recent improvement that we would like to repeat for other properties/methods: Added examples for LuaCommandProcessor.add_command and Types/LineTriggerItem
Please do not just say "most things in the prototype docs", we know and we'd like to prioritize working what you run into, instead of going alphabetically.
I'm an admin over at https://wiki.factorio.com. Feel free to contact me if there's anything wrong (or right) with it.
Re: Small documentation improvement requests
Something like "examples of values" would've been sufficient to prevent confusion I encountered (when looking for a value). In other words, the table contains a lot more attack-related stuff, not only those things.
-> Updated for the next release
I have mods! I guess!
Link
Link
- eradicator
- Smart Inserter
- Posts: 5202
- Joined: Tue Jul 12, 2016 9:03 am
- Contact:
Re: Small documentation improvement requests
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
- DedlySpyder
- Filter Inserter
- Posts: 253
- Joined: Fri Jun 20, 2014 11:42 am
- Contact:
Re: Small documentation improvement requests
Took a look through my bug reports, which were normally because something was unclear to me:
[*]LuaEntity.destroy() Returns True on Invalid Entity - Rseding told me this only returns false if it failed to destroy a valid entity.
[*]LuaSurface.find_non_colliding_position() Infinite Loop 0 Radius - This occurs when the chunks weren't generated. A hint to generate the chunks first would have been helpful.
[*]That weird multiplayer save, but single player thing that happens. I'm still not entirely sure of how, but when you take a multiplayer game and just play it locally it's still kind of a multiplayer game. Specifically it will still fire on_player_joined_game but not on_player_left_game.
[*]Ghost Lost in Migration When Changing Entity Type - It's just not supported, but I don't believe it's noted anywhere
[*]Entity placeable_by Hidden Dependency on Item's Order - Placeable_by just adds the item to the items_to_place_this array, which is then sorted by order, so the lowest sort is always the winner here for blueprints. Whereas primary-place-result on the item places it at the beginning of the array.
Re: Small documentation improvement requests
Re: Small documentation improvement requests
Alternative phrasing: "The old tile becomes hidden if it is not minable and the new tile is."
-> Improved for the next release
- eradicator
- Smart Inserter
- Posts: 5202
- Joined: Tue Jul 12, 2016 9:03 am
- Contact:
Re: Small documentation improvement requests
Regarding LuaForce.set/get_friend (and probably LuaForce.set/get_cease_fire) they have no effect on the neutral force. Which would've saved me a bunch of time had I known :D.
(Note from eradicator:Klonan has decided that he doesn't want to fix it for unclear reasons. So I'd want at least documentation of every hidden hardcoded effect on both set/get_cease_fire and set/get_friend for all directions. I.e. is PlayerForce.get_friend(NeutralForce) always true too? Or is it just NeutralForce.get_friend(PlayerForce) that's always treated as true even though the API lies about it?)
(Note 2 from eradicator: So Klonan said he's going to think about it some more.)
(Note from Therenas: The correction of this is waiting on the related bug being fixed)
(Note from eradicator:
(Note 2 from eradicator: So Klonan said he's going to think about it some more.)
Last edited by eradicator on Wed Jun 16, 2021 10:47 am, edited 4 times in total.
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Re: Small documentation improvement requests
My mods: Spidertron Patrols | Spidertron Enhancements | Factory Search | Spidertron Engineer | Spidertron Weapon Switcher | Power Overload
Re: Small documentation improvement requests
Re: Small documentation improvement requests
https://wiki.factorio.com/Types/ItemProductPrototype wrote: amount_min and amount_max
Type: Types/uint16
Mandatory if amount is not specified and named keys are being used.
Moderator note: Discussion of this post was split into a separate topic: 98070
A good mod deserves a good changelog. Here's a tutorial (WIP) about Factorio's way too strict changelog syntax!
Re: Small documentation improvement requests
-> Fixed and added example for the next release
My mods: Spidertron Patrols | Spidertron Enhancements | Factory Search | Spidertron Engineer | Spidertron Weapon Switcher | Power Overload
Re: Small documentation improvement requests
I'd appreciate some explanation of HighlightBoxEntity please.
https://wiki.factorio.com/Prototype/HighlightBoxEntity
Overall, when would you use this? The following are the questions that I had as I read through it and tried it out, but from experimenting it seems that it is only used to display the highlight box permanently.Given that, is the description "Used to attach graphics to entities during runtime." really true? It seems that it is a lot more specific (and less useful) than that.
Does setting `bounding_box` in the data do anything? -> Added on https://wiki.factorio.com/Prototype/HighlightBoxEntity
In https://lua-api.factorio.com/latest/Lua ... ate_entity, according to the game, it must have either `target`, `source`, or `bounding_box` set, but it says that `source` is only used for 'beams'...? (It might be useful to expand on when you'd want to use `target` as well).
In the `highlight-box` specific arguments for `surface.create_entity`:
It would be useful if it stated that `bounding_box` is absolute coordinates, not relative coordinates like they are in entity data definitions.
It seems that `position` is ignored when using `bounding_box` but it has to be set anyway.
What are the meanings of `box_type` (https://lua-api.factorio.com/latest/Con ... RenderType). When would you use each? Are there any examples of usage of those already in the game? EDIT it seems that they just set different colours.
Less important it could state that time_to_live and blink_interval are in ticks (presumably... I've not tested yet).
-> Fixed for the next release (finally!)
https://wiki.factorio.com/Prototype/HighlightBoxEntity
Overall, when would you use this? The following are the questions that I had as I read through it and tried it out, but from experimenting it seems that it is only used to display the highlight box permanently.
Does setting `bounding_box` in the data do anything?
In the `highlight-box` specific arguments for `surface.create_entity`:
It would be useful if it stated that `bounding_box` is absolute coordinates, not relative coordinates like they are in entity data definitions.
It seems that `position` is ignored when using `bounding_box` but it has to be set anyway.
What are the meanings of `box_type` (https://lua-api.factorio.com/latest/Con ... RenderType). When would you use each? Are there any examples of usage of those already in the game? EDIT it seems that they just set different colours.
Less important it could state that time_to_live and blink_interval are in ticks (presumably... I've not tested yet).
-> Fixed for the next release (finally!)
My mods: Spidertron Patrols | Spidertron Enhancements | Factory Search | Spidertron Engineer | Spidertron Weapon Switcher | Power Overload
- ickputzdirwech
- Filter Inserter
- Posts: 698
- Joined: Sun May 07, 2017 10:16 am
- Contact:
Re: Small documentation improvement requests
-> Improved for the next release.
Mods: Shortcuts for 1.1, ick's Sea Block, ick's vanilla tweaks
Tools: Atom language pack
Text quickly seems cold and unfriendly. Be careful how you write and interpret what others have written.
- A reminder for me and all who read what I write
Tools: Atom language pack
Text quickly seems cold and unfriendly. Be careful how you write and interpret what others have written.
- A reminder for me and all who read what I write
Re: Small documentation improvement requests
-> Fixed for the next release.
Re: Small documentation improvement requests
remove pressure_to_speed_ratio from the example
It does not exist among the prototype keys/links. It is mentioned in the example, but in the log:
Code: Select all
39.413 Warning PrototypeLoader.cpp:202: Value ROOT.fluid.<some-fluid-name>.pressure_to_speed_ratio was not used.
I have mods! I guess!
Link
Link
Boundaries for values in surface.map_gen_settings
It seems that a value of lower than 1/6th (0.166667) for the frequency of ore patches ( used in surface.map_gen_settings.autoplace_controls ) has no effect in game. The docs though do not state any limits as there is only a reference to MapGenSize for the type to be used.
Here is a post about what I tested and found: 84632
And here is Rseding91's assessment of the situation: 91396
It appears to be an obscure thing. Making it work for lower values would be my preferred solution, but if that is not possible, it would be nice, if the docs state the boundaries.
-> Thanks for the detailed explanation. This has been noted on the MapGenSize concept. Basically, anything that's outside the range of values the vanilla map generator offers are not guaranteed to work as expected
-
- Long Handed Inserter
- Posts: 65
- Joined: Tue Apr 17, 2018 11:45 pm
- Contact:
Re: Small documentation improvement requests
-> Thanks for the context!
-
- Inserter
- Posts: 27
- Joined: Fri Mar 01, 2019 1:14 pm
- Contact:
Re: Small documentation improvement requests
-> Documented, thank you to snouz, Honktown and posila.
Re: Small documentation improvement requests
DoubleThought wrote: ↑Wed May 12, 2021 6:59 amTypes/IconData (https://wiki.factorio.com/Types/IconData) does not specify what units shift works in. I am uncertain if it's in grid coordinates, where an icon ranges from [-1, 1], or where an icon ranges from [0, 1], or where an icon ranges from [0, icon_size].
-> Documented, thank you to snouz, Honktown and posila.
I have mods! I guess!
Link
Link
- ickputzdirwech
- Filter Inserter
- Posts: 698
- Joined: Sun May 07, 2017 10:16 am
- Contact:
Re: Small documentation improvement requests
PS: I wonder what else is available and not mentioned there...
-> Fixed for the next release. We're also having a look at what else is missing.
Mods: Shortcuts for 1.1, ick's Sea Block, ick's vanilla tweaks
Tools: Atom language pack
Text quickly seems cold and unfriendly. Be careful how you write and interpret what others have written.
- A reminder for me and all who read what I write
Tools: Atom language pack
Text quickly seems cold and unfriendly. Be careful how you write and interpret what others have written.
- A reminder for me and all who read what I write