Regarding disabled prerequisites still blocking
Posted: Wed May 28, 2025 3:54 pm
As of the latest release (2.0.52), if a prerequisite LuaTechnology has enabled=false, it still blocks its successors unless researched=true. Such prerequisites are normally hidden from the player.
For modders who at runtime want to disable a technology and prevent it blocking successors such that it no longer affects the tech tree, we find one of two unpleasant effects:The suggestion is to make prerequisites no longer block when disabled to avoid the above, and avoid states where player can be blocked in the UI for no apparent reason. This would be a breaking change. Edit: See below for a better suggestion.
For modders who at runtime want to disable a technology and prevent it blocking successors such that it no longer affects the tech tree, we find one of two unpleasant effects:
- The technology's effects will apply despite the technology being disabled, because researched=true must be set;
- A hidden scripted technology with no effects must be inserted between the technology and its successors with its researched status controlled by script. This leads to compatibility problems if other mods try to add the original technology as a prerequisite.