Page 1 of 1

[0.15.X] Dynamic recipe mods cause issues

Posted: Thu Jun 01, 2017 4:21 am
by EmperorZelos
My mod Omnimatter has dynamic recipes that can be changed and sometimes with mod settings and such for multiplayer, it says different content but same version number, when they all are equal.

Re: [0.15.X] Dynamic recipe mods cause issues

Posted: Thu Jun 01, 2017 4:33 am
by TokMor
For example, the attached mod settings file works fine when I host the server, but players are unable to join unless I send them the settings file. Expected result would be that they would download the settings from the server like other mods.

Re: [0.15.X] Dynamic recipe mods cause issues

Posted: Thu Jun 01, 2017 4:34 am
by EmperorZelos
Image

Re: [0.15.X] Dynamic recipe mods cause issues

Posted: Thu Jun 01, 2017 5:35 am
by Loewchen
If you change a mod in any way, you need to provide the modified mod to the players beforehand or they will not be able to join, there is no way around that.

Re: [0.15.X] Dynamic recipe mods cause issues

Posted: Thu Jun 01, 2017 5:51 am
by Nexela

Code: Select all

if settings.startup["omnimatter-infinite"].value then
	require("prototypes.generation.omnite-inf")
end

Because you are doing things like that. Which is a no no. It changes the CRC of the mod which in turns means it won't think it is the same version unless everyone has the exact same settings to begin with.

Re: [0.15.X] Dynamic recipe mods cause issues

Posted: Thu Jun 01, 2017 6:17 am
by Rseding91
Nexela wrote:

Code: Select all

if settings.startup["omnimatter-infinite"].value then
	require("prototypes.generation.omnite-inf")
end

Because you are doing things like that. Which is a no no. It changes the CRC of the mod which in turns means it won't think it is the same version unless everyone has the exact same settings to begin with.
Correct.

"require" all fines at all times and then conditionally add them to data.raw based off the settings.