[2.0 API] Autoplace Settings

Place to ask discuss and request the modding support of Factorio. Don't request mods here.
Derim422
Burner Inserter
Burner Inserter
Posts: 11
Joined: Wed Jul 07, 2021 11:16 am
Contact:

[2.0 API] Autoplace Settings

Post by Derim422 »

TL;DR

Adding resources in a mod generally requires adding an autoplacer. This could be simplified with optional parameters to AutoplaceControl.

What?

An AutoplaceControl is always going to need to be associated with some planet, whether additional or not. Having a "planets" parameter in the control to handle the registration of the control with the planet_map_gen would simplify adding new types of resources significantly. Something like a planets = {} array parameter that can be empty as well, to keep the current behavior.

Why?

Currently it is necessary to add an AutoplaceControl, then add the control to the planet_map_gen.autoplace_controls, as well as adding the entity to autoplace_settings["entity"].settings. This is complex, and adding an autoplace for anything is going to need to go somewhere.
Koub
Global Moderator
Global Moderator
Posts: 7784
Joined: Fri May 30, 2014 8:54 am
Contact:

Re: [2.0 API] Autoplace Settings

Post by Koub »

[Koub] Moved to Modding interface requests
Koub - Please consider English is not my native language.
Post Reply

Return to “Modding interface requests”