Page 1 of 1

post-oil changes, some technologies impossible. (modded)

Posted: Sun Aug 11, 2019 1:43 am
by usafphoenix
After the oil update, some mods broke, but i realized, this could be resolved with a base-game update.

Technology prerequisites, if removed, renamed, or altered in data-updates or data-final-fixes causes some technologies to be unreachable. This can be fixed by having "prerequisite" logic mandate that the named technology exists runtime. if a pre-requisite is set up during data.lua or data-updates.lua stages, but points to a technology that gets removed in the final stage, currently, that technology can't be researched because the necessary prerequisite is missing:

but if the game runtime stage is set up so that any techs with prerequisite pointers point to a technology that has been removed (or is otherwise impossible), that entry in the prerequisites table should be ignored/skipped.

Re: post-oil changes, some technologies impossible. (modded)

Posted: Sun Aug 11, 2019 2:05 am
by DaveMcW
usafphoenix wrote:
Sun Aug 11, 2019 1:43 am
Technology prerequisites, if removed, renamed, or altered in data-updates or data-final-fixes causes some technologies to be unreachable.
Don't do that.

If another mod does that, tell the author to stop or mark it as incompatible.

Re: post-oil changes, some technologies impossible. (modded)

Posted: Sun Aug 11, 2019 2:30 am
by usafphoenix
Yes, that WOULD be nice, if everyone that made mods practiced best methods, but sometimes a mod comes along and it DOESN'T.

This shouldn't be an issue, however, if the logic were changed slightly, such that, if a technology has a prerequisite named, that no longer exists, rather than marking it as "red" and impossible to research, ignore the reference to a non-existant tech. This shouldn't even cause a crash, as there is no functional-reasoning why it shouldn't work this way: If the tech exists, obey the prerequisite; if the technology listed has been removed---ignore the prerequisite.

otherwise, i have about 15 bug reports to send off to various mod authors right now >_>

Re: post-oil changes, some technologies impossible. (modded)

Posted: Sun Aug 11, 2019 3:54 am
by FuryoftheStars
You probably should report them anyway, though in principle I don’t disagree with you.

Re: post-oil changes, some technologies impossible. (modded)

Posted: Tue Aug 13, 2019 3:56 pm
by slippycheeze
usafphoenix wrote:
Sun Aug 11, 2019 2:30 am
Yes, that WOULD be nice, if everyone that made mods practiced best methods, but sometimes a mod comes along and it DOESN'T.

This shouldn't be an issue, however, if the logic were changed slightly, such that, if a technology has a prerequisite named, that no longer exists, rather than marking it as "red" and impossible to research, ignore the reference to a non-existant tech. This shouldn't even cause a crash, as there is no functional-reasoning why it shouldn't work this way: If the tech exists, obey the prerequisite; if the technology listed has been removed---ignore the prerequisite.

otherwise, i have about 15 bug reports to send off to various mod authors right now >_>
Actually, best practice would be that Wube implement a hard-fail check at the end of the data phase. This would mirror the various other ways that something "wrong" will fail. Given that a technology with a prerequisite that doesn't exist, and is visible to the user, is logically impossible, it'd match that sort of thing that also causes mods to hard-fail.

Which means your 15 bug reports will be submitted by a wide range of people when the mod stopped working entirely. :)