"Love system"
Posted: Fri Jan 02, 2015 5:50 pm
Hello!
I would like to add an option that improves the AI love/hate system (except for all other AI love factors), when a human plays with a lot of AIs. The main purpose is to balance the gameplay (equal the chances) when there are a lot of players. In other words, the strongest/most powerful guys would be more likely attacked by the other players than the weaker ones - in some way, that would flatter the chances to win a game, because in most games, gaps between the strongest guy and weaker ones are too large.
This could be done in several ways.
1) THE STATIC HATE SYSTEM: every 10 (or 20... or 30...) turns, the program simply compares the overall power (strength) of civilizations (population, science, wonders, military factor and so on...) and arrange a queue (nr. 1 = best civ on a list, nr. 2 = second civ on a list, nr. 3 = third civ on a list, etc). The first player on a list (most powerful/developed one) always gets specific, predefined additional AI hate factor (say, AI LOVE minus 20). The second one on a list always gets respectively lower value (AI LOVE minus 10). And so on.
From the program's perspective, it would look like this:
- the 1st player (with the greatest overall strength factor) gets (-20) LOVE,
- the 2nd player (with the second overall strength factor) gets (-10) LOVE,
- the rest one (from 3rd to 10th) gets zero (0) LOVE (= remains untouched by this factor).
Of course, it could be arranged in a different way:
- the 1st one gets (-15) LOVE,
- the 2nd one gets (-10) LOVE,
- the 3rd one gets (-5) LOVE,
- the 4th one gets (0) LOVE,
- the 5th one gets (0) LOVE,
- ...
As you can see, the following players on a list (4th, 5th, and so on...) are untouched by this factor.
Of course, this could be reversed: instead of "hating" the strongest players, the weaker ones could get some love bonus... It's all up to the designer:
- the 1st one gets (-15) LOVE,
- the 2nd one gets (-10) LOVE,
- the 3rd one gets (-5) LOVE,
- the 4th one gets (0) LOVE,
- the 5th one gets (0) LOVE,
- ...
- the 9th ine one gets (+5) LOVE,
- the weakest one gets (+10) LOVE.
This is the simplest solution to code, but has some disadvantages - all factors have to be already predefined, which doesn't always have to fit well: when the first player has 35000 overall strength points, he gets most of the hate (-20 LOVE), because he's in the first place on a queue, while the second player, which is almost the same powerful (34000 overall strength), gets way less hate (-10 LOVE). We can set it to (-20) and (-15) instead, but then the player with 50000 overall strength will get almost the same hate as the second one in a queue, which has only 12000, which wouldn't be fair for the second guy in a queue.
2) THE DYNAMIC HATE SYSTEM: every 10 (or 20... or 30...) turns, the program compares the overall strength of civilization, list them in a queue, checks the quantity (value) of differences between players, and spreads the AI hate from a predefined, but dynamic pool between a players. The spread of this pool is respectively bigger when the inequalities of overall strength are higher, so most of it it can be all - theoretically - taken by the first one, and it's fair, because he's powerful.
Let's suppose there are 10 players, from which two of them are clearly outstanding from the others. The program computes the AI overall pool, which can be lower or higher, depending on the inequalities between players, and spreads it between them according to their overall civilization power: the first one, as the most powerful one, may get AI LOVE (-40), while the second may get (-20). When the inequalities are lower, the first one on a list may get (-10) additional AI LOVE, while the second may get (-5).
Suppose we take five best civs and spreads the hate from 30 points of so-called "hate pool".
From the program's perspective, it would look like this:
- the 1st one has 10000 points of "power"
- the 2nd one has 8000 points of "power"
- the 3rd one has 6000 points of "power"
- the 4th one has 5000 points of "power"
- the 5th one has 4000 points of "power"
- the 6th one has 3500 points of "power"
- the 7th one has 3000 points of "power"
- the 8th one has 2500 points of "power"
- the 9th one has 1000 points of "power"
- the 10th one has 500 points of "power"
The overall pool is 43500, but we consider only 5 first CIVs - so the effective pool is 33000. Now we need to share the defined AI HATE value (say, 30 points) between these civs:
- the 1st one gest (-9) AI LOVE,
- the 2nd one gets (-7) AI LOVE,
- the 3rd one gets (-6) AI LOVE,
- the 4th one gets (-5) AI LOVE,
- the 5th one gets (-3) AI LOVE.
Of course, we can consider only three first civs. This way, when he have very powerful civ and the bunch of weak ones, the powerful one gets most of the pool. Let's say the first civ has 50000 points of "power", while the second and third has about 10000 each. When we consider three more powerful civs with a pool of 30 "hate points", we have to divide 30 points between the 70000 pool. This way:
- the 1st one, with 50000 points of "power", gets (-22) AI LOVE,
- the 2nd one, with 10000 points of "power", gets (-4) AI LOVE,
- the 3rd one, with 10000 points of "power", gets (-4) AI LOVE.
We can increase the "hate pool" to, say, 50 points. This way we get:
- the 1st one, with 50000 points of "power", gets (-36) AI LOVE,
- the 2nd one, with 10000 points of "power", gets (-7) AI LOVE,
- the 3rd one, with 10000 points of "power", gets (-7) AI LOVE.
Of course, as in the first example, this could be reversed: instead of "hating" the strongest players, the weaker ones could get some love (reversed pool)... It's all up to the designer.
3) (UN)HOLY ALLIANCE/MORTAL COMBAT: when a civilization starts building a spaceship, it automatically declares war to all other civs, which establish an (un)holy alliance against the possible winner: for example, when there are 10 players left on a map, the civ, which started building a spaceship, has a pact (military alliance) of 9 other civilizations against himself. They stop fighting each other and starts fighting the threat. It seems reasonable - it's their last chance to survive; if they won't do that, they will all fail. It's a mortal combat - the only thing they can do is to immediately attack/nuke the possible winner. When the threat is prevented (the civ being nuked/flooded so hard that he stopped building a spaceship), the pact is cancelled and the game goes on normally, until the next civ will start building a spaceship.
There are two possibilities to be consider:
=> the civilizations, that formed a pact against a threat ("unholy alliance"), CANNOT start building a spaceship until a threat is cancelled (after the threatening civilization eventually stops building spaceship - possibly because it was hitten so hard by others it simply can't build it, or it was "persuaded" to stop doing that). After the threat is gone, it all starts over: first civ, which would start building a spaceship, has a new pact against himself.
=> the civilizations, that formed a pact against the threat ("unholy alliance"), CAN start building their own spaceship - but that would mean they are automatically excluded from an alliance. The civ, which will do this, is treated just as another threat (the AIs thinks: "there are already two threats: now we need to nuke not only Russians, but also Zulus").
Yes, I know there is already a "hate" against a civ, that started building a spaceship, but it's uneffective. All the others have to immediately stop the threat; to do that, there need to be "all against one", immediate "mortal combat" aggression. All in all, when someone started building the spaceship, it's an ultimate fight for life for all the others!
*English is not my native language, I was writing this post with dictionaries, so sorry for possible mistakes or incoherences*
I would like to add an option that improves the AI love/hate system (except for all other AI love factors), when a human plays with a lot of AIs. The main purpose is to balance the gameplay (equal the chances) when there are a lot of players. In other words, the strongest/most powerful guys would be more likely attacked by the other players than the weaker ones - in some way, that would flatter the chances to win a game, because in most games, gaps between the strongest guy and weaker ones are too large.
This could be done in several ways.
1) THE STATIC HATE SYSTEM: every 10 (or 20... or 30...) turns, the program simply compares the overall power (strength) of civilizations (population, science, wonders, military factor and so on...) and arrange a queue (nr. 1 = best civ on a list, nr. 2 = second civ on a list, nr. 3 = third civ on a list, etc). The first player on a list (most powerful/developed one) always gets specific, predefined additional AI hate factor (say, AI LOVE minus 20). The second one on a list always gets respectively lower value (AI LOVE minus 10). And so on.
From the program's perspective, it would look like this:
- the 1st player (with the greatest overall strength factor) gets (-20) LOVE,
- the 2nd player (with the second overall strength factor) gets (-10) LOVE,
- the rest one (from 3rd to 10th) gets zero (0) LOVE (= remains untouched by this factor).
Of course, it could be arranged in a different way:
- the 1st one gets (-15) LOVE,
- the 2nd one gets (-10) LOVE,
- the 3rd one gets (-5) LOVE,
- the 4th one gets (0) LOVE,
- the 5th one gets (0) LOVE,
- ...
As you can see, the following players on a list (4th, 5th, and so on...) are untouched by this factor.
Of course, this could be reversed: instead of "hating" the strongest players, the weaker ones could get some love bonus... It's all up to the designer:
- the 1st one gets (-15) LOVE,
- the 2nd one gets (-10) LOVE,
- the 3rd one gets (-5) LOVE,
- the 4th one gets (0) LOVE,
- the 5th one gets (0) LOVE,
- ...
- the 9th ine one gets (+5) LOVE,
- the weakest one gets (+10) LOVE.
This is the simplest solution to code, but has some disadvantages - all factors have to be already predefined, which doesn't always have to fit well: when the first player has 35000 overall strength points, he gets most of the hate (-20 LOVE), because he's in the first place on a queue, while the second player, which is almost the same powerful (34000 overall strength), gets way less hate (-10 LOVE). We can set it to (-20) and (-15) instead, but then the player with 50000 overall strength will get almost the same hate as the second one in a queue, which has only 12000, which wouldn't be fair for the second guy in a queue.
2) THE DYNAMIC HATE SYSTEM: every 10 (or 20... or 30...) turns, the program compares the overall strength of civilization, list them in a queue, checks the quantity (value) of differences between players, and spreads the AI hate from a predefined, but dynamic pool between a players. The spread of this pool is respectively bigger when the inequalities of overall strength are higher, so most of it it can be all - theoretically - taken by the first one, and it's fair, because he's powerful.
Let's suppose there are 10 players, from which two of them are clearly outstanding from the others. The program computes the AI overall pool, which can be lower or higher, depending on the inequalities between players, and spreads it between them according to their overall civilization power: the first one, as the most powerful one, may get AI LOVE (-40), while the second may get (-20). When the inequalities are lower, the first one on a list may get (-10) additional AI LOVE, while the second may get (-5).
Suppose we take five best civs and spreads the hate from 30 points of so-called "hate pool".
From the program's perspective, it would look like this:
- the 1st one has 10000 points of "power"
- the 2nd one has 8000 points of "power"
- the 3rd one has 6000 points of "power"
- the 4th one has 5000 points of "power"
- the 5th one has 4000 points of "power"
- the 6th one has 3500 points of "power"
- the 7th one has 3000 points of "power"
- the 8th one has 2500 points of "power"
- the 9th one has 1000 points of "power"
- the 10th one has 500 points of "power"
The overall pool is 43500, but we consider only 5 first CIVs - so the effective pool is 33000. Now we need to share the defined AI HATE value (say, 30 points) between these civs:
- the 1st one gest (-9) AI LOVE,
- the 2nd one gets (-7) AI LOVE,
- the 3rd one gets (-6) AI LOVE,
- the 4th one gets (-5) AI LOVE,
- the 5th one gets (-3) AI LOVE.
Of course, we can consider only three first civs. This way, when he have very powerful civ and the bunch of weak ones, the powerful one gets most of the pool. Let's say the first civ has 50000 points of "power", while the second and third has about 10000 each. When we consider three more powerful civs with a pool of 30 "hate points", we have to divide 30 points between the 70000 pool. This way:
- the 1st one, with 50000 points of "power", gets (-22) AI LOVE,
- the 2nd one, with 10000 points of "power", gets (-4) AI LOVE,
- the 3rd one, with 10000 points of "power", gets (-4) AI LOVE.
We can increase the "hate pool" to, say, 50 points. This way we get:
- the 1st one, with 50000 points of "power", gets (-36) AI LOVE,
- the 2nd one, with 10000 points of "power", gets (-7) AI LOVE,
- the 3rd one, with 10000 points of "power", gets (-7) AI LOVE.
Of course, as in the first example, this could be reversed: instead of "hating" the strongest players, the weaker ones could get some love (reversed pool)... It's all up to the designer.
3) (UN)HOLY ALLIANCE/MORTAL COMBAT: when a civilization starts building a spaceship, it automatically declares war to all other civs, which establish an (un)holy alliance against the possible winner: for example, when there are 10 players left on a map, the civ, which started building a spaceship, has a pact (military alliance) of 9 other civilizations against himself. They stop fighting each other and starts fighting the threat. It seems reasonable - it's their last chance to survive; if they won't do that, they will all fail. It's a mortal combat - the only thing they can do is to immediately attack/nuke the possible winner. When the threat is prevented (the civ being nuked/flooded so hard that he stopped building a spaceship), the pact is cancelled and the game goes on normally, until the next civ will start building a spaceship.
There are two possibilities to be consider:
=> the civilizations, that formed a pact against a threat ("unholy alliance"), CANNOT start building a spaceship until a threat is cancelled (after the threatening civilization eventually stops building spaceship - possibly because it was hitten so hard by others it simply can't build it, or it was "persuaded" to stop doing that). After the threat is gone, it all starts over: first civ, which would start building a spaceship, has a new pact against himself.
=> the civilizations, that formed a pact against the threat ("unholy alliance"), CAN start building their own spaceship - but that would mean they are automatically excluded from an alliance. The civ, which will do this, is treated just as another threat (the AIs thinks: "there are already two threats: now we need to nuke not only Russians, but also Zulus").
Yes, I know there is already a "hate" against a civ, that started building a spaceship, but it's uneffective. All the others have to immediately stop the threat; to do that, there need to be "all against one", immediate "mortal combat" aggression. All in all, when someone started building the spaceship, it's an ultimate fight for life for all the others!
*English is not my native language, I was writing this post with dictionaries, so sorry for possible mistakes or incoherences*