learn modding

Place to post guides, observations, things related to modding that are not mods themselves.
Post Reply
Ygreqk
Manual Inserter
Manual Inserter
Posts: 3
Joined: Sat Dec 05, 2020 6:17 pm
Contact:

learn modding

Post by Ygreqk »

Hello, can anyone advise me on how to start modding because I do not know where to start?

robot256
Filter Inserter
Filter Inserter
Posts: 596
Joined: Sun Mar 17, 2019 1:52 am
Contact:

Re: learn modding

Post by robot256 »

Best place to start is the first tutorial on the Wiki: https://wiki.factorio.com/Tutorial:Modd ... al/Gangsir

Ygreqk
Manual Inserter
Manual Inserter
Posts: 3
Joined: Sat Dec 05, 2020 6:17 pm
Contact:

Re: learn modding

Post by Ygreqk »

Thank you :D .

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

Re: learn modding

Post by Pi-C »

I guess you'll want to start with creating or changing prototypes (recipes, items, entities etc.). So you should definitely consult the prototype definitions. Once your mod is loaded without errors, be sure to use the in-game prototype browser (hover the cursor over something and press CTRL+SHIFT+F) to inspect the final prototypes. That's really helpful because the game will everything you didn't define with default values, so your final prototype may be different from what you thought.

In addition to the tutorial robot256 linked to, here are more Modding tutorials that will become relevant to you at some point. However, there's a source beyond tutorials that you definitely should tap into: other mods!

Look at their code to see how other modders get things working! If you don't know where to start (mods may contain many files and folders) "reading a mod", I'd recommend progressing in the order in which things are loaded (see data lifecycle). So start with the settings, and continue with data.lua, data-updates.lua, and data-final-fixes.lua, following the trail if they contain something like "require(path_to_file)".

Eventually, you may want to let your mod do stuff not only when loading the game, but also when it's running (during the control stage). At that point, you should probably bookmark the Lua API description. :-)
A good mod deserves a good changelog. Here's a tutorial (WIP) about Factorio's way too strict changelog syntax!

Ygreqk
Manual Inserter
Manual Inserter
Posts: 3
Joined: Sat Dec 05, 2020 6:17 pm
Contact:

Re: learn modding

Post by Ygreqk »

Thanks for advice. :D

Post Reply

Return to “Modding discussion”