Balancing citystates: ignore/capture/alliance

Getting the best unit every time might be too strong, particularly getting free artillery (which are much more expensive than other units). When some unit classes are more expensive than others (cannon and artillery in particular) then you should not be able to get them every time. It would also reward beelines too much, if you are able to guarantee getting whatever high tech unit you've researched up to, even if you are far behind in other spheres.

I think randomness is the easiest way to keep things balanced.

Randomness is the easiest way to keep things balanced, and requires no effort from Thal!

That said, I think the fun factor of the Merc approach is undeniable, and getting a great unit every time - while strong - shouldn't knock Militaries into the OP stratosphere, given how relatively weak most people considers them to be.

One variation could be to adapt the Merc mod so that Military Friends and Allies offer most units for free (as per the status quo), but charge you extra for the most powerful units.
 
Randomness is the easiest way to keep things balanced, and requires no effort from Thal!
And this is a balance mod, no?

Again, I worry that integrating some entirely new mechanism from another mod is feature creep.

Its fine to tweak the military city states so they never give rubbish units, but adding a new dialogue box to the game is a significant change.

and getting a great unit every time - while strong - shouldn't knock Militaries into the OP stratosphere,
Getting artillery every time would be a big increase in their value.

given how relatively weak most people considers them to be.
People considered them weak in vanilla. I think they are no longer weak when:
a) Gold is more available, but the cost of non-city state expenditure of gold is higher, so the opportunity cost of divertying gold to military CS is lower
b) Military CS units will come with free XP
c) Maritime CS has been significantly nerfed
d) Cultural CS is only valuable for small empires.

One variation could be to adapt the Merc mod so that Military Friends and Allies offer most units for free (as per the status quo), but charge you extra for the most powerful units.
This starts getting very complicated, because "the most powerful unit" is era-dependent.

When I beeline for longswords or artillery while behind in other tech, then that unit is most powerful. But once I have tanks, mech-inf etc., artillery is no longer the "most powerful unit" available. But it would be very confusing for the player if artillery cost gold at one point, but then didn't at another point. And the whole mechanic is supposed to give free units, not make you spend more gold.

It seems far simpler to just leave with a random selection mechanism.

And, as you say, its easiest to balance.
 
"Strongest" unit generally means "highest tech" unit, since unit power tends to scale with tech level.

It's easy to only give resource-using units if the CS is providing that resource. I already know how to code it because I did CS-resource checking when improving the resource tooltip display on the top bar.

It'd be very simple to just exclude scouts and randomize it among other available units.

Citystate tech is always equal to the most technologically-advanced civ, so if we tied it to the CS's tech level it'd benefit backwards civs more than advanced ones. If that's what you're thinking of Ahriman I could do that.

Feature creep isn't so much my concern as simply the effort involved. It takes a lot of work to add stuff to the UI... and I prefer avoiding it unless it's really absolutely necessary (such as the nerfs to the community-agreed overpowered scientist lightbulbing and maritime citystates).

One thing to keep in mind is I nerfed influence gain from gold payments to citystates... though not by much. It's unbelievably difficult to adjust that formula... most of it is hardcoded and the variables we have access to are... strange. I think it was Txurce who had first-hand experience that even a slight alteration can result in negative influence gain. :lol:
 
One thing to keep in mind is I nerfed influence gain from gold payments to citystates... though not by much. It's unbelievably difficult to adjust that formula... most of it is hardcoded and the variables we have access to are... strange. I think it was Txurce who had first-hand experience that even a slight alteration can result in negative influence gain. :lol:

Yes, it was!
 
Feature creep isn't so much my concern as simply the effort involved. It takes a lot of work to add stuff to the UI... and I prefer avoiding it unless it's really absolutely necessary (such as the nerfs to the community-agreed overpowered scientist lightbulbing and maritime citystates).

Outsourcing! Given the recent surge in excellent code addins, UIs have been far less daunting a task (save when trying to make a combined modpack which integrates 15 different approaches to do the same thing).
 
itystate tech is always equal to the most technologically-advanced civ, so if we tied it to the CS's tech level it'd benefit backwards civs more than advanced ones. If that's what you're thinking of Ahriman I could do that.

This seems like a good solution to me: get a random unit buildable at the current tech level of citystates. That way, you don't get backwards tech, you can sometimes get a unit you can't even build yet (which is cool) but you aren't always getting the "best" available unit, and you don't have unit availability distorted by your own personal beelines. And you don't have any MM issues, extra UI issues, or any potential exploits, and the AI can get the same advantage from it as can the human player.

One thing to keep in mind is I nerfed influence gain from gold payments to citystates... though not by much
Agreed, but I think this is outweighed by the other factors. Military CS is pretty clearly relatively stronger than in vanilla.
 
I've played a few games with v14 now (and afaik nothing's changed wrt CS mechanics since then) and I'm finding that Maritime's are nerfed a little too much, especially in relation to the conquest bonus. I think something like:
  • 50% increase to 1.5/3:c5food: (friend/ally) per era
  • capital modifier upped to 250-300%
  • conquest bonus lowered to +4:c5citizen:s
would feel more balanced. Don't forget that the conquest bonus was determined before the recent changes and alliance is much less likely to result in an additional five citizens over the course of 30 turns now.
 
2/3 friend/ally is something I played around with a bit, could try that. We get some significant benefits from alliance status.

I agree the conquest bonus should be lowered now.
 
Thal, I just started a game with v6.2. On my third turn I met Singapore. On the AI turn TEN Singapore military units appeared. Seems like a bug to me!
 
The CS starting defenders are created at the end of turn 2, so I don't know what might cause stuff to appear on turn 10. Nothing else I do would create units in that manner.
 
The CS starting defenders are created at the end of turn 2, so I don't know what might cause stuff to appear on turn 10. Nothing else I do would create units in that manner.

No, I meant that after my turn 2, ten Singaporean units appeared. I've seen as many with some other CS in subsequent games.
 
That's probably a cache issue and shouldn't happen in a normal game. At the end of turn 2, it loops through all players, and if they're a minor civ it adds 1 archer and 2 warriors. There's nothing which would cause more to appear, but sometimes event registration (first line) can occur multiple times when there's old data in the cache.

Code:
LuaEvents.ActivePlayerTurnEnd_Player.Add(MinorCivStartingDefenders)

function MinorCivStartingDefenders(minorCiv)
    if Game.GetGameTurn() == 2 and minorCiv:IsMinorCiv() then
        local capitalCity = minorCiv:GetCapitalCity()
        if capitalCity then
            minorCiv:InitUnit( GameInfo.Units.UNIT_ARCHER.ID,  capitalCity:GetX(), capitalCity:GetY() );
            minorCiv:InitUnit( GameInfo.Units.UNIT_WARRIOR.ID, capitalCity:GetX(), capitalCity:GetY() );
            minorCiv:InitUnit( GameInfo.Units.UNIT_WARRIOR.ID, capitalCity:GetX(), capitalCity:GetY() );
        end
    end
end
 
Oh, that's probably a cache issue and won't happen in a normal game. At the end of turn 2, it loops through all players, and if they're a minor civ it adds 1 archer and 2 warriors. There's nothing which would cause more to appear, but sometimes event registration (first line) can occur multiple times when there's old data in the cache.

Code:
LuaEvents.ActivePlayerTurnEnd_Player.Add(MinorCivStartingDefenders)

function MinorCivStartingDefenders(minorCiv)
    if Game.GetGameTurn() == 2 and minorCiv:IsMinorCiv() then
        local capitalCity = minorCiv:GetCapitalCity()
        if capitalCity then
            minorCiv:InitUnit( GameInfo.Units.UNIT_ARCHER.ID,  capitalCity:GetX(), capitalCity:GetY() );
            minorCiv:InitUnit( GameInfo.Units.UNIT_WARRIOR.ID, capitalCity:GetX(), capitalCity:GetY() );
            minorCiv:InitUnit( GameInfo.Units.UNIT_WARRIOR.ID, capitalCity:GetX(), capitalCity:GetY() );
        end
    end
end

Serves me right then.
 
Playing 6.2 with a cleared cache, Info Addict and Custom Notifications, the CS are starting with 7-10 units. One CS started on an island, and had so many units that they spilled onto nearby one-tile islands as well as the mainland.
 
No idea, but TBC has already a version of Custom Notifications included. Isn't that conflicting maybe?
 
I'm not so much into the lua-stuff yet, but maybe you can copy&paste some lines from one file to the other one to make everything work together.
 
I am getting the same results - CS come out with 7 units, and capital pop expansions occasionally multiply - without using the separate Custom Notifications - just Info Addict and 6.2.
 
You could try this... add a logger line in CiVUP_General.lua:

Code:
function MinorCivStartingDefenders(minorCiv)
    if Game.GetGameTurn() == 2 and minorCiv:IsMinorCiv() then
        logger:Error("MinorCivStartingDefenders "..minorCiv:GetName())
        local capitalCity = minorCiv:GetCapitalCity()
        if capitalCity then
            minorCiv:InitUnit( GameInfo.Units.UNIT_ARCHER.ID,  capitalCity:GetX(), capitalCity:GetY() );
            minorCiv:InitUnit( GameInfo.Units.UNIT_WARRIOR.ID, capitalCity:GetX(), capitalCity:GetY() );
            minorCiv:InitUnit( GameInfo.Units.UNIT_WARRIOR.ID, capitalCity:GetX(), capitalCity:GetY() );
        end
    end
end
Then...

  1. save the file
  2. start a game
  3. open the tuner
  4. end your turn until the text shows up
  5. copy-paste it here
 
Back
Top Bottom