Government stability and demographics

What would you like to see in Freeciv? Do you have a good idea what should be improved or how?
Post Reply
Ignatus
Elite
Posts: 644
Joined: Mon Nov 06, 2017 12:05 pm
Location: St.Petersburg, Russia
Contact:

Government stability and demographics

Post by Ignatus »

Running a government is not always smooth. Even if nobody conquers your capital and you let your cities better starve than rebel (the latter, for some reason, is considered very democratic in our games), there can be social conditions when a small group of intrigaunts or a crony system grown unnoticed may ruin the way the nation is governed or invert most basic principles of the state.

I suggest to add to the game spontaneous government changes. They would basically happen at a random turn shuffling the player's cards but coming of it should be predictable. For each such an event we declare thresholds of demographical stats (literacy, mil. service, production per citizen...) within which a specific government is stable, but each unit out of them increases the chance of power system mutation (maybe, until the maximal probability). This would make the governent game features both more developed and more smooth - e.g. you must weight the risks when in a Republic you build libraries to get techs faster rather than courthouses, as the high corruption may throw you back to Tribal. Sometimes the change may be even advantageous - you will probably get from Democracy to Communism in a heavy wartime without revolution period, just bccecause your people understand the need.

The "Revolution_When_Unhappy" effect may be replaced by this more generic mechanism. Example of a possible ruleset code:

Code: Select all

; A Despotism may be thrown into revolution
; by any rebelling city if the nation knows Republic and is literate enough
[govchange_peoples_revolution]
name = _("People's Revolution")
gov_from = "Despotism"
gov_to = "Anarchy"
;city unhappiness warnings precede
message = _("From mere local manifestations, uprisings spread all over the country!"), _("People, willing for a better government, make the dictator to retire!")
;revolution message follows
reqs = {"type", "name", "range"
 "Tech", "Republic", "Player"
}
factors = {"Stat", "MinThreshold", "BaseProbPct", "ProbIncPm", "NewGroup"
  "CityUnhappinessTurns", 1, 100 ; a city must rebel
  "Literacy", 30, 20, 5, TRUE ; 20% to 55% probable
  "CitiesUnhappy", 1, 0, 30 ; +3% each unhappy city
}
Wahazar
Elite
Posts: 362
Joined: Mon Jul 02, 2018 1:49 pm

Re: Government stability and demographics

Post by Wahazar »

Maybe just to add effect, which can be randomly called (with percentage probability defined) if its requirements are fulfilled?
It would be useful also for other events, for example disasters, which are now , if I remember correctly, hardcoded.
Augmented2 ruleset/modpack for freeciv2.6: http://forum.freeciv.org/f/viewtopic.php?f=11&t=91047
Ignatus
Elite
Posts: 644
Joined: Mon Nov 06, 2017 12:05 pm
Location: St.Petersburg, Russia
Contact:

Re: Government stability and demographics

Post by Ignatus »

Wahazar wrote:Maybe just to add effect, which can be randomly called (with percentage probability defined) if its requirements are fulfilled?
What we call "effects" are just sums of integer numbers each of which is included when specific requirement set is fully true; more complicated things than one number require additional data (e.g. "Inspire_Partisans" uses a Lua callback that indirectly addresses unit type with "Partisan" flag). The requirements may be various but their types include few civ stats that seem suitable for defining government stability, and these stats are not usable in other cases I can pretend. So, the mechanism would better use special syntax like for disasters.
It would be useful also for other events, for example disasters, which are now , if I remember correctly, hardcoded.
There are a lot of signals that can invoke a Lua script with flexible behaviour on different occasions. Just Lua can't yet do most of what disasters do. Also, explaining flexible things to AI is difficult overall and has about no softcoded mechanism now (the unit roles like "Hunter" are some of the few examples).
Post Reply