Hello!
I am trying to make a mod out of something: a beautiful story and map my teacher made for us to play with in factorio. However he didn't do it by making a mod, he did it by changing the game files. So now that I'm trying to make a mod out of it so that more people can play it.
I expect I will have many questions along the way.
My first question that I haven't been able to find: is there any way to add scenario's to a mod? So that people that download it can just add the mods folder and don't have to go adding things anywhere else?
My second question: Is there a way to change existing items in the game through a mod? I see that it is possible to add new items fairly easily but can you change how existing things work? Like for example change the recipe for red science?
Scenario in a mod?
- aubergine18
- Smart Inserter
- Posts: 1264
- Joined: Fri Jul 22, 2016 8:51 pm
- Contact:
Re: Scenario in a mod?
For scenario stuff, investigate "story_table" - you can find example in base/scenarios/sandbox/control.lua or search for scripts that contain text (require "story") without the parentheses, I just added those to make it clear what text to search. Also, check out the base/campaigns folder. You can find source code to `story` stuff in core/lualib/story.lua
Existing items, techs, recipes, etc., can be changed via a mod - they can be found in the 'data' global - a lot of the balancing mods do that sort of thing so you can look at their code to see how it's done.
Existing items, techs, recipes, etc., can be changed via a mod - they can be found in the 'data' global - a lot of the balancing mods do that sort of thing so you can look at their code to see how it's done.
Better forum search for modders: Enclose your search term in quotes, eg. "font_color" or "custom-input" - it prevents the forum search from splitting on hypens and underscores, resulting in much more accurate results.
Re: Scenario in a mod?
Just make a folder called scenarios in the mod folder and put the scenario in there. It will show up in your game under Custom scenario:
Mod request - please change flamethrower ammo recipe
Change a recipe
[HELP] Edit the data of only one entity
For the second question:
Mod request - please change flamethrower ammo recipe
Change a recipe
[HELP] Edit the data of only one entity
Re: Scenario in a mod?
Thanks! You guys are awesome