I don't know exactly how the game engine handles loading/storing things like scripted triggers/rules/effects/etc, so I don't know how plausible this would be (especially if it requires changing how they are formatted), but I think it could be quite useful for modding and compatibility overall.
As it is, the game allows on_actions to essentially be "appended" together by including an on_actions block when defining a new on_action, like this:
on_game_start_after_lobby = {
on_actions = { initial_game_start_onaction_effects }
}
initial_game_start_onaction_effects = {
effect = {
every_player = { add_piety = 100000 }
}
on_actions = { another_test_on_action }
}
another_test_onaction = {
effect = {
every_player = { add_gold = 10000000 }
}
}
In this example, when the on_game_start_after_lobby action is triggered, it triggers the initial_game_start_onaction_effects action giving every player lots of piety, which then in turn triggers the another_test_onaction action giving every player lots of gold. This is nice in modding because you can easily add your own on_actions without having to worry about overwriting the base game ones and causing compatibility issues with other mods.
Because you can't do something like that for things like scripted effects/triggers, mods, especially large or total conversion mods, sometimes require a lot of compatibility patches because different mods need to modify the same base game effects/triggers/rules, but in different ways. While being able to "append" effects/triggers/rules won't solve all of these compatibility issues, it could definitely alleviate some of them.