Page 1 of 1

Scenarios on mod portal

Posted: Mon Dec 11, 2017 7:53 pm
by Aprillion
Thanks to the latest FFF "Level designer needed" message, I am now thinking about creating a scenario to improve my Lua during upcoming holiday season.

I wanted to review code of some popular scenarios, but found conflicting info about publishing scenarios:
* https://wiki.factorio.com/Scenario_system suggests "scenarios cannot be uploaded to the official mod portal" and should be published on random places
* but https://www.reddit.com/r/factorio/comme ... io_portal/ provides a workaround how to package scenarios inside a normal mod
* in https://mods.factorio.com/?q=scenario it looks like people either don't use the mod portal for publishing scenarios or don't create scenarios
* search.php?keywords=scenario&fid%5B0%5D=36 suggests there are more scenarios published elsewhere and linked from the forum

I understand that non-mod-scenarios can be installed on a server without installing on a client, but IMHO that is a smaller use case than using the standard Mod Portal for distribution. The portal provides nice in-game integration, popularity statistics, version compatibility checking, place for discussion/reporting of problems, ...

Are there other reasons why the Mod Portal is not officially recommended for publishing scenarios? Could we add a category on the portal for mods that include a scenario/campaign?

So I can review code of scenarios that are shipped with the game, but which others are popular / well written?

Re: Scenarios on mod portal

Posted: Mon Dec 11, 2017 8:11 pm
by Klonan
Putting scenarios in mods isn't a workaround, its a pretty good way of doing it, and I would recommend it

Otherwise we are just duplicating a bunch of code about info.jsons, descriptions, mod locale etc. when having scenarios like this doesn't really make them work better

Re: Scenarios on mod portal

Posted: Tue Dec 12, 2017 1:07 pm
by Aprillion
Klonan wrote:its a pretty good way of doing it, and I would recommend it
Thanks! Not sure if stuff on reddit gets deleted, but FTR: just put the files inside /scenarios or /campaigns subtree inside the mod.

Re: Scenarios on mod portal

Posted: Tue Feb 27, 2018 4:01 pm
by Deadly-Bagel
Bump for getting Scenarios added as a tag to the portal - the sooner this happens, the fewer scenarios end up on the General tag.

Re: Scenarios on mod portal

Posted: Sat Aug 24, 2019 11:22 pm
by kizrak
Aprillion wrote:
Tue Dec 12, 2017 1:07 pm
Thanks! Not sure if stuff on reddit gets deleted, but FTR: just put the files inside /scenarios or /campaigns subtree inside the mod.
So I was able to create a mod containing the /scenarios/<name>/control.lua which would show up in the games "Mod Scenarios" under new game. I tried using a similar structure for campaigns but was unable to get anything to show up under "Start Campaign". Can mods (that are uploaded/downloaded via mod portal) add campaigns? or are they limited to scenarios?

Re: Scenarios on mod portal

Posted: Sun Aug 25, 2019 8:19 am
by Klonan
kizrak wrote:
Sat Aug 24, 2019 11:22 pm
I tried using a similar structure for campaigns but was unable to get anything to show up under "Start Campaign". Can mods (that are uploaded/downloaded via mod portal) add campaigns? or are they limited to scenarios?
Yes, mods can add campaigns, be sure to include a description.json in the campaign folder

Re: Scenarios on mod portal

Posted: Sun Aug 25, 2019 5:34 pm
by kizrak
Klonan wrote:
Sun Aug 25, 2019 8:19 am
Yes, mods can add campaigns, be sure to include a description.json in the campaign folder
Thanks a million!

For anyone else reading this later, you also must have an image.png or the game crashes...
The \Steam\steamapps\common\Factorio\data\base\campaigns\npe folder can be used as a rough example (it is the simplest of the base campaigns).