Happiness, Influence, & Allegiance

This is for directed discussions on immediate questions of game design. Only moderators can create new threads.
Locked
Message
Author
User avatar
OllyG
Space Kraken
Posts: 151
Joined: Wed Jul 20, 2011 12:03 pm

Re: Happiness, Influence, & Allegiance

#106 Post by OllyG »

Cray are described as 'Cheerful enthusiastic robots' - they need a species bonus to Happiness.

Trith are 'Bereaved xenophobic telepaths' - a penalty to happiness.

Derthrean are 'Pacifistic, bio-engineering, pain ridden, floating plant/virus synthesis' ( :shock: who came up with this?) - an extra penalty when invaded or at war?

Eaxaw are 'Evil amazonian xenophobic aggressive worms' - aggressive seems the opposite of pacifistic. They should be species specials like telepathic and xenophobic, which affect how happiness is affected by war/peace and invasion.

Exobots are 'Semi-autonomous robots' - they should get a bonus to Allegiance; can't see them revolting.

Happiness and Allegiance should definitely be heavily affected by species.
Geoff the Medio wrote:
eleazar wrote:If an empire manages a bloodless invasion
Meaning what? Just dropping ground troops, no orbital bombardment? I assume that means there needs to be an orbital bombardment button next to the invade button then? With essentially the same mechanism to specify which ships will do so (so as to allow the player to control the amount of bombardment)?
If the invading force is large enough then surely the defenders will just surrender?
The invasion button could be supplemented with a 'bloodless invasion' button :P which would use up twice as many troop ships, but not reduce happiness.

User avatar
Sloth
Content Scripter
Posts: 685
Joined: Sat Mar 17, 2007 12:28 am

Re: Happiness, Influence, & Allegiance

#107 Post by Sloth »

Is it time to start discussing this topic again, now that Happiness and Approval (r7161) have slowly made their way into the code?

I would be willing to refine and explain my concept again. It works with Influence or without Influence (since the Influence discussion really ended nowhere).
All released under the GNU GPL 2.0 and Creative Commons Attribution-ShareAlike 3.0 licences.

User avatar
Sloth
Content Scripter
Posts: 685
Joined: Sat Mar 17, 2007 12:28 am

Re: Happiness, Influence, & Allegiance

#108 Post by Sloth »

It has been pretty silent since the release of 0.4.4. To have something to discuss, here is my revised concept for Happiness and Approval:

What's the effect of Happiness:
- The Happiness of planets influences the Approval of the respective species (in both directions).
- Happiness will protect the planet from Espionage actions.
- Low Happiness (< 10) will reduce Production.
- Very low Happiness (zero) will lead to a Rebellion which in turn can lead to independence of the planet.

What's the effect of Approval:
- Approval influences Happiness on planets with the respective species (in both directions).
- Approval will improve Espionage actions on objects with the respective species (enemy colonies/ships).


In detail (the numbers):
- Happiness has values between 0 and 100 (capped if target is greater or smaller).
- Approval has values up to 100 (capped if target is greater). No lower bound.
- Starting Approval (both target and current) of the starting species is 100. Other species start with 50.
- Colonies (colonized or captured) start with current Happiness equal to the Approval of the respective species.

Calculation of target Approval (each turn):
Target Approval is the mean current happiness of all your planets with the respective species, weighted by population. A = (H1*P1+H2*P2+...)/(P1+P2+...).
Current Approval moves with the speed of 1 point/turn towards target Approval.
Approval of species not in the empire will not change.

Calculation of target Happiness (each turn):
Target Happiness base is the current Approval of the respective species.
+ 20 for homeworld.
+ 10 supply-connected to homeworld.
+ 10 for capital.
+ 10 for Gaia.
+ 50 Paradise Planet Focus (produces nothing).
+ X for each Supply Line connected planet with Happiness Focus (X should depend on population). [maybe X = ProducingPopulation^2 / EmpirePopulation]
+ X due to happiness raising techs/buildings.
+- X Species traits (sometimes tied to conditions, for example xenophobic, don't like Black Holes, Tiny Planets etc.).
+- X Specials.
+ 10 for Good planet.
- 10 for Poor planet.
- 20 for Hostile planet.
- 100 Concentration Camp (but no production penalty or rebellions).
- 0.02 * total population of the empire

Actions that change current meters:
- Invading a planet (one turn of ground combat) with the species reduces current Approval by 10.
- Bombing a planet with the species reduces current Approval by 20. More for homeworld.
- Bioterror on a planet with the species reduces current Approval by 20.
- A Concentration Camp on a planet with the species reduces current Approval by 20.

Thresholds for Happiness penalties:
- If Happiness < 10: Production of PP, RP, TP is multiplied with Happiness/10. (riots, strikes)
- If Happiness = 0: Target Troops is set to 0. (Rebellion)
- If Happiness = 0 and Troops = 0: Independence.

What the numbers should accomplish:
- Invading multiple planets with a single species in short time requires a choice:
...a) Set them to Paradise Planet Focus to avoid rebellions, which makes them unproductive until you've won the trust of the species.
...b) Give up on the species for a long time and build Concentration Camps.
- The happiness of the starting species should almost never be a problem. Even in a very large empire the happiness shouldn't approach 10, so as long as espionage is not implemented there should be no concern about happiness unless you mess up (like repeatedly disregarding their preferences).
- Species could gain a lot of character by giving them something they like/dislike. Some hate other species (xenophobic), some love tiny planets, some love war, some hate to be far from their homeworld, some love asteroid belts in their system, etc.
All released under the GNU GPL 2.0 and Creative Commons Attribution-ShareAlike 3.0 licences.

User avatar
Vezzra
Release Manager, Design
Posts: 6095
Joined: Wed Nov 16, 2011 12:56 pm
Location: Sol III

Re: Happiness, Influence, & Allegiance

#109 Post by Vezzra »

Sloth wrote:It has been pretty silent since the release of 0.4.4.
It has been that way the past couple of releases, probably because everyone is a bit exhausted and needs a break after all the effort that goes with getting a release out. 0.4.4 has been particularly demanding, so I expect the silence to continue for a while... ;)

User avatar
MatGB
Creative Contributor
Posts: 3310
Joined: Fri Jun 28, 2013 11:45 pm

Re: Happiness, Influence, & Allegiance

#110 Post by MatGB »

Vezzra wrote:
Sloth wrote:It has been pretty silent since the release of 0.4.4.
It has been that way the past couple of releases, probably because everyone is a bit exhausted and needs a break after all the effort that goes with getting a release out. 0.4.4 has been particularly demanding, so I expect the silence to continue for a while... ;)
Pretty much, I'm spending my time writing rulebooks and playng C-Evo which has nice nostalgia but terrible AI/difficulty balance, I'll be doing some scripting when my head clears but right now it's break time, I think I burnt out a bit testing every single RC candidate with so many games.
Mat Bowles

Any code or patches in anything posted here is released under the CC and GPL licences in use for the FO project.

User avatar
Krikkitone
Creative Contributor
Posts: 1559
Joined: Sat Sep 13, 2003 6:52 pm

Re: Happiness, Influence, & Allegiance

#111 Post by Krikkitone »

Sloth wrote:It has been pretty silent since the release of 0.4.4. To have something to discuss, here is my revised concept for Happiness and Approval:

.
One significant problem with your feature is the positive feedback issue.

ie Happiness and Allegiance will both trend to 100 or 0 long term

If the components of "target happiness" are

Allegiance +X

if your Average X is >0 then target happiness will be greater than current allegiance, meaning that target allegiance will be a moving target always moving Above current allegiance... so both current and target allegiance and happiness will increase every turn until 100.

if your Average X <0 then target happiness will be less than current allegiance, meaning that target allegiance will be a moving target always Less than current allegiance

Basically the system has three possible results
1. Happiness and Allegiance are moving Up continuously to 100
2. Happiness and Allegiance are moving Down Continuously to 0 happiness (and some - amount of allegiance)
3. Average Happiness and Allegiance are Exactly equal and stagnant (any change moves it to one of the others)


What I would put as a better idea

Allegiance (Species wide) does depend on average Happiness (as well as other factors)
Happiness does NOT depend on allegiance

Instead "world behavior" [spies, rebellion, production penalties] depends on Happiness (local factors) + Allegiance (global factors)
(If Allegiance+Happiness =<0 then you get rebels)

Concentration camp=-100 to happiness
Which lowers happiness on this world... lowering Allegiance everywhere by a smaller amount... however the lowered allegiance does not affect the happiness leading to even More lowered allegiance.

User avatar
Sloth
Content Scripter
Posts: 685
Joined: Sat Mar 17, 2007 12:28 am

Re: Happiness, Influence, & Allegiance

#112 Post by Sloth »

Krikkitone wrote: One significant problem with your feature is the positive feedback issue.

ie Happiness and Allegiance will both trend to 100 or 0 long term

If the components of "target happiness" are

Allegiance +X

if your Average X is >0 then target happiness will be greater than current allegiance, meaning that target allegiance will be a moving target always moving Above current allegiance... so both current and target allegiance and happiness will increase every turn until 100.

if your Average X <0 then target happiness will be less than current allegiance, meaning that target allegiance will be a moving target always Less than current allegiance

Basically the system has three possible results
1. Happiness and Allegiance are moving Up continuously to 100
2. Happiness and Allegiance are moving Down Continuously to 0 happiness (and some - amount of allegiance)
3. Average Happiness and Allegiance are Exactly equal and stagnant (any change moves it to one of the others)
Your calculation is missing that happiness is capped at 100. So even when "your Average X is >0" Allegiance will always stay below 100 (Allegiance can only reach 100 when all your planets have X>0).

What i expect for "normal" empires is that the Allegiance of their starting and native species will settle in the range of 80-95. My goal was not to pester the player with keeping its own folk happy (unless he picks up some difficult species like xenophobics), but to make invasions come at a bigger cost.
All released under the GNU GPL 2.0 and Creative Commons Attribution-ShareAlike 3.0 licences.

Mitten.O
Programmer
Posts: 255
Joined: Sun Apr 06, 2014 4:15 pm

Re: Happiness, Influence, & Allegiance

#113 Post by Mitten.O »

Sloth wrote: Your calculation is missing that happiness is capped at 100. So even when "your Average X is >0" Allegiance will always stay below 100 (Allegiance can only reach 100 when all your planets have X>0).

What i expect for "normal" empires is that the Allegiance of their starting and native species will settle in the range of 80-95. My goal was not to pester the player with keeping its own folk happy (unless he picks up some difficult species like xenophobics), but to make invasions come at a bigger cost.
I think you are right in that the drift of allegiance will stop because happiness is capped at both ends, but is the feedback loop still desirable? It means that when "average X>0", they will both grow until some planet or planets has 100 and even worse, when "average X<0", they will stop dropping only when some planet(s) reaches happiness = 0.

Think about an empire where some species lives only on one planet. Say the total effect of other factors on that planet is -10. Then happiness will be below allegiance and allegiance will fall, which will make happiness fall, etc... until they rebel. The feedback loop won't weaken before the happiness is capped.
Any code by me in this post is released under GPL 2.0 or later.

User avatar
Krikkitone
Creative Contributor
Posts: 1559
Joined: Sat Sep 13, 2003 6:52 pm

Re: Happiness, Influence, & Allegiance

#114 Post by Krikkitone »

Mitten.O wrote:
Sloth wrote: Your calculation is missing that happiness is capped at 100. So even when "your Average X is >0" Allegiance will always stay below 100 (Allegiance can only reach 100 when all your planets have X>0).

What i expect for "normal" empires is that the Allegiance of their starting and native species will settle in the range of 80-95. My goal was not to pester the player with keeping its own folk happy (unless he picks up some difficult species like xenophobics), but to make invasions come at a bigger cost.
I think you are right in that the drift of allegiance will stop because happiness is capped at both ends, but is the feedback loop still desirable? It means that when "average X>0", they will both grow until some planet or planets has 100 and even worse, when "average X<0", they will stop dropping only when some planet(s) reaches happiness = 0.

Think about an empire where some species lives only on one planet. Say the total effect of other factors on that planet is -10. Then happiness will be below allegiance and allegiance will fall, which will make happiness fall, etc... until they rebel. The feedback loop won't weaken before the happiness is capped.
I think I can see a reason for doing that though....
The idea is you have to Control the other factors

It does make it simple in terms of game results... 2 possible results (technically 3 but practically 2)
1. Happiness rises until it is at 100 on some planets (and near 100 on others)
2. Happiness falls until is is at 0 on some planers (and near 0 on others)

Basically there is a Threshold.... regarding the 'other factors'

Above 0 you will win that species over
Below 0 you will lose that species to rebellion*


A simple change for "Target Approval" make it (5 + H1*P1 +H2*P2 ...)/(0.1 +P1+P2...)
That way if you have 0 pop in your empire, it balances out at 50... but if you have 1 pop in your empire, that out weighs the 50 by a factor of 10 to 1)

*actually you will lose the worlds that give the species unhappiness factors first.... so if some worlds have 'other factors' >0.. they won't revolt.. and once you lose the 'poor' worlds... your happiness for that species will rise again.

OK I like it :) The positive feedback acts as a switch.. world is stable or not

also if your worlds are highly unequal...

1 Paradise homeworld (+70) and 5 poor worlds (-10 each) [that somehow have the same pop to make this balance]

The Paradise world would be at 100 happiness, the Poor worlds would all be 10 below the average..
(100+5*(av-10))/6=av
100+5average-50=6 average
50= average
So the poor worlds would be at only 40 happiness
...or of they have 1/5 the pop of the paradise hw (more likely)
100+average-10=2 average
90=average
poor worlds at 80


So while overall it tends to 'go up v. go down'.. there will be a few worlds that have stable but low happiness (so they can be vulnerable to spies, etc.)

User avatar
Sloth
Content Scripter
Posts: 685
Joined: Sat Mar 17, 2007 12:28 am

Re: Happiness, Influence, & Allegiance

#115 Post by Sloth »

Krikkitone wrote:A simple change for "Target Approval" make it (5 + H1*P1 +H2*P2 ...)/(0.1 +P1+P2...)
That way if you have 0 pop in your empire, it balances out at 50... but if you have 1 pop in your empire, that out weighs the 50 by a factor of 10 to 1)
I think i like this change. The effect is that a species that has been bombed by your empire slowly "forgets" about it, which has to be balanced, but is desireable and realistic i guess.
All released under the GNU GPL 2.0 and Creative Commons Attribution-ShareAlike 3.0 licences.

User avatar
Krikkitone
Creative Contributor
Posts: 1559
Joined: Sat Sep 13, 2003 6:52 pm

Re: Happiness, Influence, & Allegiance

#116 Post by Krikkitone »

Sloth wrote:
Krikkitone wrote:A simple change for "Target Approval" make it (5 + H1*P1 +H2*P2 ...)/(0.1 +P1+P2...)
That way if you have 0 pop in your empire, it balances out at 50... but if you have 1 pop in your empire, that out weighs the 50 by a factor of 10 to 1)
I think i like this change. The effect is that a species that has been bombed by your empire slowly "forgets" about it, which has to be balanced, but is desireable and realistic i guess.
Well you can make Bombing have a bigger effect on Current Allegiance.
Possibly have it depend on if it was "bombing out" ie if your bombing wiped out the population then it could be something like an "additional -100/# of planets species still occupies"

User avatar
labgnome
Juggernaut
Posts: 833
Joined: Mon Mar 02, 2015 5:57 pm

Re: Happiness, Influence, & Allegiance

#117 Post by labgnome »

I have a concept for a farily simple (at least in my mind) system for hapyness/politics between species. I'll give a basic run-through here because I don't know if it's a different enough idea to warrent its own thread.

Each species has a variaty of traits, like metabolism and prefered planet type. Species could also have "likes" and "dislikes" for different species traits. Both empire-building and native species should have these likes and dislikes. There would be a limited number of like and dislike "slots" for each species.

Being in an empire with a species with a trait they liked would increase hapyness, if the empire was founded by a species with that trait would increase hapyness even more. Conversely, being in an empire with a species that had a trait they disliked would decrease hapyness, and if it was the founder of the empire, decrease hapyness even more. Hapyness in regards to proximity would also be a factor, so that the furthr away they are from species they dislike the less it negativly effects their hapyness. Species who disliked each other would take small penalties if they were in neighboring systems and take larger penalties if their planets were in the same system. This would mean that as players were expanding their empire, they would have to get more and more "picky" about the species they brought into their empire, to manage their hapyness. *For colonizing species, both empire and native, those with more narrow planetary preferences should get more like slots, and species with broader planetary prefernces should get more dislike slots. If your species, and the native species you want both like each other, intigrating their planet peacefully should be easy, simmilarly there should be less of a penalty to hapyness if they are conquered.

Alternately species with a broad enviromental preference might have to take "dislikes all but" traits in certian areas, while species with narrow preferences might tak "likes all but" traits. In this model Xenophobic might be a "dislikes all" kind of trait.

There may even be additional traits (not likable or dislikable) to effect these preferences in a species. Things like "glorious liberators", "community builders" or "special snowflakes".

*Note: this may help balance out the Egassem.
All of my contributions should be considered released under creative commons attribution share-alike license, CC-BY-SA 3.0 for use in, by and with the Free Orion project.

User avatar
Vezzra
Release Manager, Design
Posts: 6095
Joined: Wed Nov 16, 2011 12:56 pm
Location: Sol III

Re: Happiness, Influence, & Allegiance

#118 Post by Vezzra »

I'm locking this thread, it has become too large and old. The topics discussed here shall be continued in new threads.

Locked